XmlRPC入门_形参定义

发布时间 2023-11-30 10:46:29作者: 左边的翼

形参类型的定义略

The string looks something like this example: i:iii,s: . It is a list of signature strings, separated by commas. In the example, there are two signatures:
i:iii
s:
Each signature string describes one form of calling the method. A signature string has the form:
     <resultType>:<1stParmType><2ndParmType>...
resultType and xxxParmType are one character, corresponding to the type given here by the XML element name:
i int
b boolean
d double
s string
8 dateTime.iso8601
6 base64
S struct
A array
n nil
Note that there is no way to describe the specific contents of a struct or array.
Note that XML-RPC method always has exactly one return value, so there is always one character followed by a colon (:). An XML-RPC method can have any number of parameters, including zero, so there can be any number of characters, including zero, after the colon.
To decline to state the signatures, use a null pointer for signature. If you do that, system.MethodSignature will return a special response that says, "I frankly have no idea."
A signature list of "?" is equivalent to a null pointer and before Xmlrpc-c 1.05 (March 2006), that was the only way. But it is deprecated now.
help is the help text that system.methodHelp will return for the method. To decline to supply help text, use a null pointer for help. If you do that, system.methodHelp will return text that says something to the effect of, "wouldn't you like to know?"
serverInfo is a pointer to a data structure that gives information about the server that will call the method function. It is opaque to Xmlrpc-c; the data structure must be meaningful to the method function. This may be a null pointer to indicate no server context.

 详述可参见具体解释:https://xmlrpc-c.sourceforge.io/doc/libxmlrpc.html