com.google.gdata.model.atom
Class OtherContent

java.lang.Object
  extended by com.google.gdata.model.Element
      extended by com.google.gdata.model.atom.Content
          extended by com.google.gdata.model.atom.OtherContent
All Implemented Interfaces:
IContent

public class OtherContent
extends Content

Variant of Content for entries containing miscellaneous inlined content types.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.google.gdata.data.IContent
IContent.Type
 
Field Summary
static ElementKey<java.lang.String,OtherContent> KEY
          The key for this element.
static java.lang.String KIND
          The kind name for adaptation.
 
Fields inherited from class com.google.gdata.model.atom.Content
CONSTRUCT, SRC, TYPE, XML_LANG
 
Constructor Summary
OtherContent()
          Constructs a new instance using the default key.
OtherContent(Content content)
          Constructs a new instance from a more generic Content type.
 
Method Summary
 byte[] getBytes()
           
 java.lang.String getText()
           
 int getType()
          Returns this content's type.
 XmlBlob getXml()
           
 Element getXmlContent()
          Gets the nested xml content of this element.
static void registerMetadata(MetadataRegistry registry)
          Registers the metadata for this element.
 void setBytes(byte[] v)
          Specifies the binary contents.
 void setMimeType(ContentType v)
          Specifies the MIME type.
 void setText(java.lang.String v)
          Specifies the plain-text contents.
 void setXml(XmlBlob v)
          Specifies the XML contents.
 void setXmlContent(Element content)
          Sets the nested xml content of this element.
 
Methods inherited from class com.google.gdata.model.atom.Content
getLang, getMimeType, getSrc, setLang
 
Methods inherited from class com.google.gdata.model.Element
addElement, addElement, addElement, clear, createElement, createElement, equals, getAttributeCount, getAttributeIterator, getAttributeIterator, getAttributeValue, getAttributeValue, getDefaultKey, getElement, getElement, getElementCount, getElementId, getElementIterator, getElementIterator, getElementKey, getElements, getElements, getElementSet, getElementSet, getElementValue, getElementValue, getTextValue, getTextValue, hasAttribute, hasAttribute, hasElement, hasElement, hashCode, hasTextValue, isLocked, lock, removeAttribute, removeAttribute, removeAttributeValue, removeAttributeValue, removeElement, removeElement, removeElement, removeElement, replaceElement, resolve, resolve, setAttributeValue, setAttributeValue, setElement, setElement, setElement, setTextValue, toString, visit
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

KIND

public static final java.lang.String KIND
The kind name for adaptation.

See Also:
Constant Field Values

KEY

public static final ElementKey<java.lang.String,OtherContent> KEY
The key for this element.

Constructor Detail

OtherContent

public OtherContent()
Constructs a new instance using the default key.


OtherContent

public OtherContent(Content content)
Constructs a new instance from a more generic Content type.

Parameters:
content - generic content
Method Detail

registerMetadata

public static void registerMetadata(MetadataRegistry registry)
Registers the metadata for this element.


getType

public int getType()
Description copied from class: Content
Returns this content's type. The list of valid value is defined in IContent.Type.

Specified by:
getType in interface IContent
Overrides:
getType in class Content
Returns:
the type of this content
See Also:
IContent.Type

setMimeType

public void setMimeType(ContentType v)
Specifies the MIME type.


getXml

public XmlBlob getXml()
Returns:
the XML contents

setXml

public void setXml(XmlBlob v)
Specifies the XML contents.


getXmlContent

public Element getXmlContent()
Gets the nested xml content of this element. This will return the first xml element found inside this content.


setXmlContent

public void setXmlContent(Element content)
Sets the nested xml content of this element.


getText

public java.lang.String getText()
Returns:
the plain text contents

setText

public void setText(java.lang.String v)
Specifies the plain-text contents.


getBytes

public byte[] getBytes()
Returns:
the binary contents

setBytes

public void setBytes(byte[] v)
Specifies the binary contents.