Created March 27, 2025
The C# client-side library defines the classes that can be (de)serialized to/from XML. This is useful for accessing the HTTP resources that are published by this application.
//read a resource from a REST url Uri uri = new Uri(...); XmlSerializer s = new XmlSerializer( typeof( byte[] ) ); //Create the request object WebRequest req = WebRequest.Create(uri); WebResponse resp = req.GetResponse(); Stream stream = resp.GetResponseStream(); TextReader r = new StreamReader( stream ); byte[] result = (byte[]) s.Deserialize( r ); //handle the result as needed...
name | size | description |
---|---|---|
uprightapi-csharp-xml-client.zip | 22.53K | The C# source code for the C# client library. |
Created March 27, 2025
The Java client-side library is used to access the Web service API for this application using Java.
The Java client-side library is used to provide the set of Java objects that can be serialized to/from XML using JAXB. This is useful for accessing the resources that are published by this application.
java.net.URL url = new java.net.URL(baseURL + "/territories"); JAXBContext context = JAXBContext.newInstance( byte[].class ); java.net.URLConnection connection = url.openConnection(); connection.connect(); Unmarshaller unmarshaller = context.createUnmarshaller(); MTTerritory result = (MTTerritory) unmarshaller.unmarshal( connection.getInputStream() ); //handle the result as needed...
javax.ws.rs.client.Client client = javax.ws.rs.client.ClientBuilder.newClient(); MTTerritory result = client.target(baseUrl + "/territories") .get(MTTerritory.class); //handle the result as needed...
name | size | description |
---|---|---|
uprightapi-xml-client.jar | 124.38K | The binaries for the Java XML client library. |
uprightapi-xml-client-xml-sources.jar | 97.77K | The sources for the Java XML client library. |
Created March 27, 2025
name | size | description |
---|---|---|
ns0.xsd | 124.57K |
Created March 27, 2025
The PHP client-side library defines the PHP classes that can be (de)serialized to/from XML. This is useful for accessing the resources that are published by this application, but only those that produce a XML representation of their resources.
This library leverages the XMLReader and XMLWriter tools that were included in PHP versions 5.1.0+.
//read the resource in XML form: $xml = ...; $reader = new \XMLReader(); if (!$reader->open($xml)) { throw new \Exception('Unable to open ' . $xml); } $result = new Object($reader); //open a writer for the xml $out = ...; $writer = new \XMLWriter(); $writer->openUri($out); $writer->startDocument(); $writer->setIndent(4); $result->toXml($writer); $writer->flush();
name | size | description |
---|---|---|
uprightapi-php-xml-client-php.zip | 191.29K | The PHP client-side library defines the PHP classes that can be (de)serialized to/from XML. This is useful for accessing the resources that are published by this application, but only those that produce a XML representation of their resources. This library leverages the XMLReader and XMLWriter tools that were included in PHP versions 5.1.0+. PHP XML Example
//read the resource in XML form: $xml = ...; $reader = new \XMLReader(); if (!$reader->open($xml)) { throw new \Exception('Unable to open ' . $xml); } $result = new Object($reader); //open a writer for the xml $out = ...; $writer = new \XMLWriter(); $writer->openUri($out); $writer->startDocument(); $writer->setIndent(4); $result->toXml($writer); $writer->flush(); |