artdaq_node_server
v1_00_09
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Variables
Pages
src
node_modules
xmlrpc
tmp
client.js
1
var Client = require(
'../lib/client'
)
2
var http = require('http')
3
4
var options = { host:
'localhost'
, port: 9994, path:
'/'
, method:
'POST'
}
5
var chunk1 =
'<?xml version="1.0" encoding="UTF-8"?>'
6
+
'<methodCall>'
7
+
'<methodName>testMethod</methodName>'
8
+
'<params>'
9
+
'<param>'
10
+
'<value><string>Param A</string></value>'
11
+
'</param>'
12
+
'<param>'
13
+
'<value><string>Param B</string></value>'
14
+
'</param>'
15
+
'</params>'
16
+
'</methodCall>'
;
17
18
var req = http.request(options,
function
(res) {
19
setTimeout(
function
() { console.log(
'too late'
); }, 5000)
20
})
21
22
req.on(
'error'
,
function
(e) {
23
//do nothing
24
})
25
req.write(chunk1);
26
req.end();
27
//setTimeout(function () { req.abort(); }, 10)
28
Generated on Tue Aug 8 2017 08:37:16 for artdaq_node_server by
1.8.5