Search in sources :

Example 1 with DefaultUrlConverter

use of br.com.caelum.restfulie.opensearch.conveter.DefaultUrlConverter in project restfulie-java by caelum.

the class OpenSearchTest method setUp.

@Before
public void setUp() {
    xstream = new XStream();
    xstream.registerConverter(new DefaultUrlConverter(Restfulie.custom()));
    xstream.registerConverter(new DefaultTagsConveter());
    xstream.processAnnotations(SearchDescription.class);
}
Also used : XStream(com.thoughtworks.xstream.XStream) DefaultUrlConverter(br.com.caelum.restfulie.opensearch.conveter.DefaultUrlConverter) DefaultTagsConveter(br.com.caelum.restfulie.opensearch.conveter.DefaultTagsConveter) Before(org.junit.Before)

Example 2 with DefaultUrlConverter

use of br.com.caelum.restfulie.opensearch.conveter.DefaultUrlConverter in project restfulie-java by caelum.

the class XmlMediaType method unmarshal.

public <T> T unmarshal(String content, RestClient client) {
    XStream xstreamLocal = getXstream(client);
    xstreamLocal.registerConverter(new DefaultLinkConverter(client));
    xstreamLocal.registerConverter(new DefaultUrlConverter(client));
    return (T) xstreamLocal.fromXML(content);
}
Also used : DefaultLinkConverter(br.com.caelum.restfulie.client.DefaultLinkConverter) XStream(com.thoughtworks.xstream.XStream) DefaultUrlConverter(br.com.caelum.restfulie.opensearch.conveter.DefaultUrlConverter)

Aggregations

DefaultUrlConverter (br.com.caelum.restfulie.opensearch.conveter.DefaultUrlConverter)2 XStream (com.thoughtworks.xstream.XStream)2 DefaultLinkConverter (br.com.caelum.restfulie.client.DefaultLinkConverter)1 DefaultTagsConveter (br.com.caelum.restfulie.opensearch.conveter.DefaultTagsConveter)1 Before (org.junit.Before)1