Skip to content

Commit 3e6d084

Browse files
committed
Proxyless Gateway: removed serialization from arguments
1 parent 122c537 commit 3e6d084

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

isc/py/gw/DynamicObject.cls

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Property %Variable As %String(MAXLEN = 1000);
99
Property %Type As %String(MAXLEN = 1000);
1010

1111
/// Default serialization for methods
12-
Property %Serialization As %Integer;
12+
Property %Serialization As %Integer [ InitialExpression = {##class(isc.py.Callout).#SerializationStr} ];
1313

1414
/// Automatically escape values on property set
1515
Property %EscapeOnSet As %Boolean [ InitialExpression = {$$$YES} ];
@@ -25,10 +25,9 @@ Property %EscapeOnCall As %Boolean [ InitialExpression = {$$$NO} ];
2525
/// w obj.age
2626
/// w obj.getAge()
2727
/// w obj.getAgePlus(10)
28-
Method %OnNew(type As %String = "", variable As %String, serialization As %Integer = {##class(isc.py.Callout).#SerializationStr}, args...) As %Status [ Private, ServerOnly = 1 ]
28+
Method %OnNew(type As %String = "", variable As %String, args...) As %Status [ Private, ServerOnly = 1 ]
2929
{
3030
set ..%Variable = variable
31-
set ..%Serialization = serialization
3231

3332
if type'="" {
3433
// Create variable of type
@@ -134,9 +133,9 @@ Method %ToPickle(ByRef stream As %Stream.Object, useString As %Boolean = {$$$NO}
134133
}
135134

136135
/// Convert Python object to string
137-
Method %ToStream(serialization As %Integer = {..%Serialization}, ByRef stream As %Stream.Object, useString As %Boolean = {$$$NO}) As %Status [ CodeMode = expression ]
136+
Method %ToStream(ByRef stream As %Stream.Object, useString As %Boolean = {$$$NO}) As %Status [ CodeMode = expression ]
138137
{
139-
##class(isc.py.Main).GetVariable(..%Variable, serialization, .stream, useString)
138+
##class(isc.py.Main).GetVariable(..%Variable, ..%Serialization, .stream, useString)
140139
}
141140

142141
Method %Destroy() [ CodeMode = expression ]
@@ -145,9 +144,9 @@ Method %Destroy() [ CodeMode = expression ]
145144
}
146145

147146
/// Get object as serialized string
148-
Method %GetString(serialization As %Integer = {..%Serialization}) As %String
147+
Method %GetString() As %String
149148
{
150-
set sc = ..%ToStream(serialization, .stream, $$$YES)
149+
set sc = ..%ToStream(.stream, $$$YES)
151150
quit:$$$ISERR(sc) ""
152151
if $isObject(stream) {
153152
set stream = stream.Read($$$MaxStringLength)

0 commit comments

Comments
 (0)