@@ -445,8 +445,13 @@ This is the Schema which defines the form of the dispatch map</Description>
445445</XData >
446446
447447<Method name =" OutputToStr" >
448+ <Description >
449+ Executes actions and returns device output
450+ pObj - OREF or class
451+ pMethod - instance or class method to execute respectively
452+ pArgs - additional arguments</Description >
448453<ClassMethod >1</ClassMethod >
449- <FormalSpec >pObj:%ZEN.proxyObject ,pMethod:%String="%ToJSON" ,pArgs...</FormalSpec >
454+ <FormalSpec >pObj,pMethod,pArgs...</FormalSpec >
450455<ProcedureBlock >0</ProcedureBlock >
451456<ReturnType >%String</ReturnType >
452457<Implementation ><![CDATA[
@@ -458,10 +463,18 @@ This is the Schema which defines the form of the dispatch map</Description>
458463 //Enable redirection
459464 do ##class(%Device).ReDirectIO(1)
460465
461- if $d(pArgs)= 0 {
462- do $Method(pobj,pMethod)
463- } else {
464- do $Method(pobj,pMethod,pArgs)
466+ if $isobject(pObj) {
467+ if $d(pArgs)= 0 {
468+ do $Method(pobj,pMethod)
469+ } else {
470+ do $Method(pobj,pMethod,pArgs)
471+ }
472+ } elseif $$$comClassDefined("%Library.Array") {
473+ if $d(pArgs)= 0 {
474+ do $ClassMethod(pobj,pMethod)
475+ } else {
476+ do $ClassMethod(pobj,pMethod,pArgs)
477+ }
465478 }
466479
467480 //Disable redirection
0 commit comments