org.apache.abdera.model
Interface Text

All Superinterfaces:
Base, Cloneable, Element, Iterable<Element>

public interface Text
extends Element

Represents an Atom Text Contruct.

Atom allows three kinds of Text constructs:

Per RFC4287:

  A Text construct contains human-readable text, usually in small
  quantities.  The content of Text constructs is Language-Sensitive.
 
  atomPlainTextConstruct =
     atomCommonAttributes,
     attribute type { "text" | "html" }?,
     text
 
  atomXHTMLTextConstruct =
     atomCommonAttributes,
     attribute type { "xhtml" },
     xhtmlDiv
 
  atomTextConstruct = atomPlainTextConstruct | atomXHTMLTextConstruct
 


Nested Class Summary
static class Text.Type
          Text Constructs can be either Text, HTML or XHTML
 
Method Summary
 Text.Type getTextType()
          Return the Text.Type
 String getValue()
          Return the text value
 Div getValueElement()
          Return the text value element
 String getWrappedValue()
          Return the wrapped value
 Text setTextType(Text.Type type)
          Set the Text.Type
 Text setValue(String value)
          Set the text value
 Text setValueElement(Div value)
          Set the text value element
 Text setWrappedValue(String wrappedValue)
          Set the wrapped value
 
Methods inherited from interface org.apache.abdera.model.Element
declareNS, discard, getAttributes, getAttributeValue, getAttributeValue, getBaseUri, getDocument, getElements, getExtensionAttributes, getFirstChild, getFirstChild, getLanguage, getLanguageTag, getLocale, getMustPreserveWhitespace, getNamespaces, getNextSibling, getNextSibling, getParentElement, getPreviousSibling, getPreviousSibling, getQName, getResolvedBaseUri, getText, removeAttribute, removeAttribute, setAttributeValue, setAttributeValue, setBaseUri, setBaseUri, setLanguage, setMustPreserveWhitespace, setParentElement, setText, setText
 
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
 
Methods inherited from interface java.lang.Iterable
iterator
 

Method Detail

getTextType

Text.Type getTextType()
Return the Text.Type

Returns:
The Text.Type

setTextType

Text setTextType(Text.Type type)
Set the Text.Type

Parameters:
type - The Text.Type

getValueElement

Div getValueElement()
Return the text value element

Returns:
A xhtml:div

setValueElement

Text setValueElement(Div value)
Set the text value element

Parameters:
value - The xhtml:div

getValue

String getValue()
Return the text value

Returns:
The text value

setValue

Text setValue(String value)
Set the text value

Parameters:
value - The text value

getWrappedValue

String getWrappedValue()
Return the wrapped value

Returns:
The text value wrapped in a xhtml:div

setWrappedValue

Text setWrappedValue(String wrappedValue)
Set the wrapped value

Parameters:
wrappedValue - The text value wrapped in a xhtml:div


Copyright © 2006-2010 Apache Software Foundation. All Rights Reserved.