a580e12000-09-27Fredrik Hübinette (Hubbe) #pike __REAL_VERSION__
a20af62000-09-26Fredrik Hübinette (Hubbe) 
aa94471997-09-16David Kågedal  #include "remote.h"
64f6bd2000-05-16Martin Stjernholm constant is_remote_call = 1;
aa94471997-09-16David Kågedal string objectid; string name; object con; object ctx;
fd11df1997-10-04David Kågedal int _async;
aa94471997-09-16David Kågedal  mixed `() (mixed ... args) {
fd11df1997-10-04David Kågedal  mixed data = ctx->encode_call(objectid, name, args, _async); if (_async)
a53efa1997-09-23David Kågedal  con->call_async(data); else return con->call_sync(data); return 0;
aa94471997-09-16David Kågedal }
a53efa1997-09-23David Kågedal mixed sync(mixed ... args) {
fd11df1997-10-04David Kågedal  mixed data = ctx->encode_call(objectid, name, args, _async);
a53efa1997-09-23David Kågedal  return con->call_sync(data); } void async(mixed ... args) {
c5ac631997-11-01Per Hedbor  mixed data = ctx->encode_call(objectid, name, args, 1);
a53efa1997-09-23David Kågedal  con->call_async(data); }
fd11df1997-10-04David Kågedal int is_async() { return _async; } void set_async(int a) { _async = a; }
a53efa1997-09-23David Kågedal void create(string oid, string n, object cn, object ct, int a)
aa94471997-09-16David Kågedal { objectid = oid; name = n; con = cn; ctx = ct;
fd11df1997-10-04David Kågedal  _async = a;
aa94471997-09-16David Kågedal }