svn commit: samba r8070 - in branches/SAMBA_4_0/testprogs/ejs: .
tridge at samba.org
tridge at samba.org
Sat Jul 2 05:22:12 GMT 2005
Author: tridge
Date: 2005-07-02 05:22:12 +0000 (Sat, 02 Jul 2005)
New Revision: 8070
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=8070
Log:
a (as yet not working) example of how rpc calls might be made from js scripts
Added:
branches/SAMBA_4_0/testprogs/ejs/echo.js
Changeset:
Added: branches/SAMBA_4_0/testprogs/ejs/echo.js
===================================================================
--- branches/SAMBA_4_0/testprogs/ejs/echo.js 2005-07-02 05:21:17 UTC (rev 8069)
+++ branches/SAMBA_4_0/testprogs/ejs/echo.js 2005-07-02 05:22:12 UTC (rev 8070)
@@ -0,0 +1,34 @@
+/*
+ demonstrate access to rpc calls from ejs
+*/
+
+function irpcObj()
+{
+ var o = new Object();
+ o.in = new Object();
+ return o;
+}
+
+function test_AddOne()
+{
+ var status;
+ var conn = new Object();
+ var io = irpcObj();
+
+ status = rpc_connect(conn, "ncacn_ip_tcp:localhost", "rpcecho");
+ printVars(status);
+ printVars(conn);
+
+ io.in.in_data = 3;
+ status = rpc_call(conn, "echo_AddOne", io);
+ printVars(status);
+ printVars(io);
+}
+
+
+print("Starting\n");
+
+test_AddOne();
+
+
+
More information about the samba-cvs
mailing list