[ http://issues.apache.org/jira/browse/XMLRPC-87?page=all ]
Jochen Wiedmann closed XMLRPC-87:
---------------------------------
Resolution: Fixed
The site is out of date. (Hopefully up2date after the coming beta release,
though.) The nightly builds or SVN builds contain up2date docs.
> Documentation Error with Supported Datatypes
> --------------------------------------------
>
> Key: XMLRPC-87
> URL: http://issues.apache.org/jira/browse/XMLRPC-87
> Project: XML-RPC
> Type: Bug
> Reporter: Michael Rimov
> Priority: Trivial
>
> http://ws.apache.org/xmlrpc/types.html states that Calendar data types may be
> used as valid XML-RPC types, but if an attempt to use a calendar is made,
> XML-RPC throws:
> javax.servlet.ServletException: Failed to write XML-RPC response: Calendar
> values aren't supported, if isEnabledForExtensions() == false
> at
> org.apache.xmlrpc.webserver.XmlRpcServletServer.execute(XmlRpcServletServer.java:105)
> Since the code in SerializerTest shows extensions having to be enabled for
> the Calendar Type, I'm assuming it is a trivial doc error.
> public void testCalendarParam() throws Exception {
> TimeZone tz = TimeZone.getTimeZone("GMT");
> Calendar cal1 = Calendar.getInstance(tz);
> cal1.set(1933, 5, 12, 11, 7, 21);
> cal1.set(Calendar.MILLISECOND, 311);
> Calendar cal2 = Calendar.getInstance(TimeZone.getDefault());
> cal2.set(1933, 5, 12, 11, 7, 21);
> cal2.set(Calendar.MILLISECOND, 311);
> XmlRpcStreamRequestConfig config = getExConfig();
> XmlRpcRequest request = new XmlRpcClientRequestImpl(config,
> "dateParam", new Object[]{cal1, cal2.getTime()});
> String got = writeRequest(config, request);
> String expect =
> "<?xml version=\"1.0\" encoding=\"US-ASCII\"?>"
> + "<methodCall
> xmlns:ex=\"http://ws.apache.org/xmlrpc/namespaces/extensions\">"
> + "<methodName>dateParam</methodName><params>"
> +
> "<param><value><ex:dateTime>1933-06-12T11:07:21.311Z</ex:dateTime></value></param>"
> +
> "<param><value><dateTime.iso8601>19330612T11:07:21</dateTime.iso8601></value></param>"
> + "</params></methodCall>";
> assertEquals(expect, got);
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]