just wondered if there was a way to pass functions for execution to another function so that events can occur before and after?
like :
d ..MethodA(
..Method1("var"),
..Method2(0),
...
)edit:
I managed to get it working with execute but is there a cleaner (easier way)?
ClassMethod WriteSegment(Functions. As %String) As %Status
{
w "Start",!
f Fn=1:1:Functions {
x Functions(Fn)
}
w "End",!
Q $$$OK
}
ClassMethod WriteSomething(Arg As %String) As %Status
{
w Arg,!