Usage of remoteMethodServer.invoke and RemoteMethodServer.ServerFlag
Hello community!
I am looking through the PTC | Windchill code right now and I am encountering a lot of if(RemoteMethodServer.ServerFlag) { run code } else { remoteMethodServer.invoke(...)} constructs.
I am figuring this means something like "If the code is executed server-side then continue, otherwise invoke the method on the particular method server". But where would this code be executed, if not on the method server?
Can anyone please give me a better / more technical explanation. Why is it important to use this construct and when should you use it?
Thanks in advance and best regards

