|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Document<T extends Element>
The top level artifact of the Feed Object Model. The Parser component processes data from an InputStream and returns a Document instance. The type of Document returned depends on the XML format being parsed. The Feed Object Model supports four basic types of documents: FeedDocument, EntryDocument, ServiceDocument (Atom Publishing Protocol Introspection Documents) and XmlDocument (any arbitrary XML).
Method Summary | |
---|---|
Document<T> |
addProcessingInstruction(String target,
String value)
Add a processing instruction to the document |
Document<T> |
addStylesheet(String href,
String media)
Add a xml-stylesheet processing instruction to the document |
IRI |
getBaseUri()
Returns the Base URI of the document. |
String |
getCharset()
Gets the charset used for this document |
javax.activation.MimeType |
getContentType()
Returns the content type of this document |
org.apache.abdera.util.EntityTag |
getEntityTag()
Return the entity tag for this document |
String |
getLanguage()
Get the language |
Lang |
getLanguageTag()
Returns the value of the xml:lang attribute as a Lang object |
Date |
getLastModified()
Returns the last modified date for this document |
boolean |
getMustPreserveWhitespace()
Return true if insignificant whitespace must be preserved |
String[] |
getProcessingInstruction(String target)
Get the values for the given processing instruction |
T |
getRoot()
Returns the root element of the document (equivalent to DOM's getDocumentElement) |
String |
getSlug()
Get the slug for this document |
org.apache.abdera.util.XmlUtil.XMLVersion |
getXmlVersion()
Get the XMLVersion used by this document |
Document<T> |
setBaseUri(String base)
Sets the Base URI of the document. |
Document<T> |
setCharset(String charset)
Sets the charset used for this document |
Document<T> |
setContentType(String contentType)
Sets the content type for this document |
Document<T> |
setEntityTag(org.apache.abdera.util.EntityTag tag)
Set the entity tag for this document |
Document<T> |
setEntityTag(String tag)
Set the entity tag for this document |
Document<T> |
setLanguage(String lang)
set the base language |
Document<T> |
setLastModified(Date lastModified)
Sets the last modified date for this document |
Document<T> |
setMustPreserveWhitespace(boolean preserve)
Set to true to preserve insignificant whitespace |
Document<T> |
setRoot(T root)
Sets the root element of the document |
Document<T> |
setSlug(String slug)
Set the slug for this document |
Methods inherited from interface org.apache.abdera.model.Base |
---|
addComment, clone, complete, getDefaultWriterOptions, getFactory, writeTo, writeTo, writeTo, writeTo, writeTo, writeTo, writeTo, writeTo, writeTo, writeTo, writeTo, writeTo |
Method Detail |
---|
T getRoot()
Document<T> setRoot(T root)
root
- Set the root element of the documentIRI getBaseUri()
Document<T> setBaseUri(String base)
base
- The Base URI
IRISyntaxException
- if the IRI is malformedjavax.activation.MimeType getContentType()
Document<T> setContentType(String contentType)
contentType
- The content type of document
MimeTypeParseException
- if the content type is malformedDate getLastModified()
Document<T> setLastModified(Date lastModified)
lastModified
- the last-modified dateString getCharset()
Document<T> setCharset(String charset)
charset
- The character encoding to useDocument<T> addProcessingInstruction(String target, String value)
target
- The processing instruction targetvalue
- The processing instruction valueString[] getProcessingInstruction(String target)
Document<T> addStylesheet(String href, String media)
href
- The href of the stylesheetmedia
- The media target for this stylesheet or null if noneorg.apache.abdera.util.EntityTag getEntityTag()
Document<T> setEntityTag(org.apache.abdera.util.EntityTag tag)
Document<T> setEntityTag(String tag)
String getLanguage()
Lang getLanguageTag()
Document<T> setLanguage(String lang)
String getSlug()
Document<T> setSlug(String slug)
boolean getMustPreserveWhitespace()
Document<T> setMustPreserveWhitespace(boolean preserve)
org.apache.abdera.util.XmlUtil.XMLVersion getXmlVersion()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |