org.newsml.toolkit
Interface Topic

All Superinterfaces:
BaseNode, CatalogNode, CommentNode, IdNode, PropertyNode

public interface Topic
extends BaseNode, CatalogNode, CommentNode, IdNode, PropertyNode

A single item of metadata.

This interface currently omits the following information:

Version:
2.0
Author:
Reuters PLC

Method Summary
 Description[] getDescription()
          Get all Description children in an array.
 Description getDescription(int index)
          Get one of the topic's descriptions.
 int getDescriptionCount()
          Count the descriptions.
 Text getDetails()
          Get a URI pointing to additional details about the topic.
 FormalNameDecl[] getFormalNameDecl()
          Get all FormalName children in an array.
 FormalNameDecl getFormalNameDecl(int index)
          Get one of the topic's formal names.
 int getFormalNameDeclCount()
          Count the formal names.
 FormalName[] getTopicType()
          Get all TopicType children in an array.
 FormalName getTopicType(int index)
          Get the type of the topic.
 int getTopicTypeCount()
          Count the types.
 
Methods inherited from interface org.newsml.toolkit.BaseNode
getAttr, getChild, getChild, getChild, getChild, getChildCount, getChildCount, getParent, getPath, getSession, getXMLName, getXPath, insertAfter, insertAfter, insertAfter, insertAfter, insertAfterDuid, insertAfterDuid, insertBefore, insertBefore, insertBefore, insertBefore, insertBeforeDuid, insertBeforeDuid, insertChild, insertChild, insertFirst, insertFirst, insertLast, insertLast, removeChild, removeChild, removeSelf, replaceChild, replaceChild, replaceChild, replaceChild, replaceChild, replaceChild, setAttr, setAttr, toXML, toXML, unsetAttr, unsetAttr, writeXML, writeXML
 
Methods inherited from interface org.newsml.toolkit.CatalogNode
getCatalog
 
Methods inherited from interface org.newsml.toolkit.CommentNode
getComment, getComment, getCommentCount
 
Methods inherited from interface org.newsml.toolkit.IdNode
getDuid, getEuid
 
Methods inherited from interface org.newsml.toolkit.PropertyNode
getProperty, getProperty, getPropertyCount
 

Method Detail

getDetails

public Text getDetails()
Get a URI pointing to additional details about the topic.
Returns:
Text containing a URI, or null if none was provided.

getTopicTypeCount

public int getTopicTypeCount()
Count the types.
Returns:
The number of topic types present.

getTopicType

public FormalName getTopicType(int index)
Get the type of the topic.

The type is roughly equivalent to a class.

Parameters:
index - The index of the topic type, zero-based, numbered sequentially in document order.
Returns:
A formal name representing the topic's type, or null if none was present at the specified index (the first type must not be null).

getTopicType

public FormalName[] getTopicType()
Get all TopicType children in an array.
Returns:
A (possibly-empty) array of TopicType children.

getFormalNameDeclCount

public int getFormalNameDeclCount()
Count the formal names.
Returns:
The number of formal names present.

getFormalNameDecl

public FormalNameDecl getFormalNameDecl(int index)
Get one of the topic's formal names.
Parameters:
index - The index of the formal name, zero-based, numbered sequentially in document order.
Returns:
A formal name declaration, or null if none was provided at the specified index.

getFormalNameDecl

public FormalNameDecl[] getFormalNameDecl()
Get all FormalName children in an array.
Returns:
A (possibly-empty) array of FormalName children.

getDescriptionCount

public int getDescriptionCount()
Count the descriptions.
Returns:
The number of descriptions present.

getDescription

public Description getDescription(int index)
Get one of the topic's descriptions.

If there are multiple descriptions, the variant property may help to distinguish them; see Description.getVariant().

Parameters:
index - The index of the description, zero-based, numbered sequentially in document order.
Returns:
A description object, or null if none was provided at the specified index.

getDescription

public Description[] getDescription()
Get all Description children in an array.
Returns:
A (possibly-empty) array of Description children.