| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| Parent folder | |||
| README.txt | 2011-06-26 | 2.2 kB | |
| Colligate-0.1.jar | 2011-06-26 | 13.5 kB | |
| Totals: 2 Items | 15.7 kB | 0 | |
========README TO GO WITH COLLIGATE RELEASE 0.1================
Colligate is a client library written in Java with the purpose of acting as a tool for
client side interface developers, with which the developers can quickly create clients
for Webservices (RESTFUL or otherwise), XML over HTTP and JMS. The developer has to follow
the following steps in release 0.1 to create a GET connection to a URL
1. Get Invoker object from ColligateFactory
2. Create GetConfig object and set parameters like url and query string
3. Invoke the interface in Invoker using Invoke method while passing the configuration
4. Get the response from Invoker in String or byte or Object format
5. Use the response in your code
A sample test case is as following:
------------------------------------------------------------------
GetConfig get = new GetConfig();
get.setMethodType("get");
get.setUrl("http://xyz.com/abc.html");
get.setQueryString("?is-external=true");
Invoker invoker = ColligateFactory.getInvoker();
try {
invoker.Invoke(get);
} catch (ColligateException e) {
e.printStackTrace();
}
ColligateResponse res = invoker.getResponse();
try {
System.out.println(res.getStringBody());
} catch (IOException e) {
e.printStackTrace();
}
}
-------------------------------------------------------------------
res.getStringBody() here gives the response string
This is very initial release of Colligate only supporting GET on Http, however
in the future releases the target will be a complete set of method support on
Http for GET, POST, PUT and maybe DELETE as well.
Colligate is a tool - framework built upon the Apache HttpComponents 4.1.
To use or test colligate include the following jars in your Workspace
commons-codec-1.4.jar
commons-logging-1.1.1.jar
httpclient-4.1.1.jar
httpclient-cache-4.1.1.jar
httpcore-4.1.jar
httpmime-4.1.1.jar
Available at http://hc.apache.org/downloads.cgi
=======================================================================
Issues or Bugs report at: Colligate >> Tracker >> Bugs
=======================================================================