public class ParseSax<T> extends Object implements com.google.common.base.Function<HttpResponse,T>, InvocationContext<ParseSax<T>>
Modifier and Type | Class and Description |
---|---|
static interface |
ParseSax.Factory |
static class |
ParseSax.HandlerForGeneratedRequestWithResult<T> |
static class |
ParseSax.HandlerWithResult<T>
Handler that produces a useable domain object accessible after parsing completes.
|
Constructor and Description |
---|
ParseSax(XMLReader parser,
ParseSax.HandlerWithResult<T> handler) |
Modifier and Type | Method and Description |
---|---|
T |
addDetailsAndPropagate(HttpResponse response,
Exception e) |
T |
addDetailsAndPropagate(HttpResponse response,
Exception e,
String text) |
T |
apply(HttpResponse from) |
protected T |
doParse(InputSource from) |
ParseSax.HandlerWithResult<T> |
getHandler() |
T |
parse(InputSource from) |
T |
parse(InputStream from) |
T |
parse(String from) |
ParseSax<T> |
setContext(HttpRequest request) |
public ParseSax(XMLReader parser, ParseSax.HandlerWithResult<T> handler)
public T apply(HttpResponse from)
apply
in interface com.google.common.base.Function<HttpResponse,T>
public T parse(InputStream from)
public T parse(InputSource from)
protected T doParse(InputSource from) throws IOException, SAXException
IOException
SAXException
public T addDetailsAndPropagate(HttpResponse response, Exception e)
public T addDetailsAndPropagate(HttpResponse response, Exception e, @Nullable String text)
public ParseSax.HandlerWithResult<T> getHandler()
public ParseSax<T> setContext(HttpRequest request)
setContext
in interface InvocationContext<ParseSax<T>>
Copyright © 2009-2012 jclouds. All Rights Reserved.