Skip to content

Commit edcd9ca

Browse files
committed
Interoperability - RestoreContext - Add option to clear context
1 parent 2453aee commit edcd9ca

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

isc/py/ens/Operation.cls

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ Method SaveContext(request As isc.py.msg.SaveRequest, Output response As Ens.Str
6767
Method RestoreContext(request As isc.py.msg.RestoreRequest, Output response As Ens.Response) As %Status
6868
{
6969
#dim sc As %Status = $$$OK
70-
set sc = ##class(isc.py.data.Context).RestoreContext(request.ContextId)
70+
set sc = ##class(isc.py.data.Context).RestoreContext(request.ContextId,, request.Clear)
7171
set response = ##class(Ens.Response).%New()
7272
quit sc
7373
}

isc/py/msg/RestoreRequest.cls

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,19 @@ Class isc.py.msg.RestoreRequest Extends Ens.Request
55
/// Context identifier to restore
66
Property ContextId As %Integer;
77

8+
/// Clear context before restore
9+
Property Clear As %Boolean [ InitialExpression = {$$$NO} ];
10+
811
Storage Default
912
{
1013
<Data name="RestoreRequestDefaultData">
1114
<Subscript>"RestoreRequest"</Subscript>
1215
<Value name="1">
1316
<Value>ContextId</Value>
1417
</Value>
18+
<Value name="2">
19+
<Value>Clear</Value>
20+
</Value>
1521
</Data>
1622
<DefaultData>RestoreRequestDefaultData</DefaultData>
1723
<Type>%Library.CacheStorage</Type>

0 commit comments

Comments
 (0)