public class TextResource extends AbstractResource
Resty.Option, Resty.Timeout| Modifier and Type | Field and Description |
|---|---|
protected java.lang.String |
text |
inputStream, urlConnectionDEFAULT_USER_AGENT, MOZILLA, userAgent| Constructor and Description |
|---|
TextResource(Resty.Option... options) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getAcceptedTypes()
Get charset for this content type.
|
protected java.lang.String |
readTextFromStream(java.io.InputStream aTextStream) |
java.lang.String |
toString()
Kinda obvious, but, yes, it parses the inputStream with the proper charset
and returns the content as String
|
getUrlConnection, http, location, printResponseHeaders, status, streamaddAdditionalHeaders, addStandardHeaders, alwaysSend, bytes, bytes, bytes, bytes, chunked, chunked, content, content, content, content, createBinaryResource, createJSONResource, createTextResource, data, data, delete, doGET, dontSend, doPOSTOrPUT, fillResourceFromURL, form, form, getAdditionalHeaders, identifyAsMozilla, identifyAsResty, json, json, json, json, openConnection, path, put, setOptions, text, text, text, text, withHeaderpublic TextResource(Resty.Option... options)
public java.lang.String toString()
toString in class java.lang.Objectprotected java.lang.String readTextFromStream(java.io.InputStream aTextStream)
public java.lang.String getAcceptedTypes()
getAcceptedTypes in class AbstractResource