Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.tm4j.topicmap
Interface DataObject  view DataObject download DataObject.java

All Known Subinterfaces:
Occurrence, VariantName

public interface DataObject

Base interface for interfaces which represent topic map elements containing character data or remote resource references. In XTM, occurrences and variant names may contain resource data, which can be one of the following:

This interface defines the basic methods for retrieving and manipulating resource data of both these kinds.

Since:
0.6.0

Method Summary
 java.lang.String getData()
          Gets the resource data string associated with this occurrence.
 org.tm4j.net.Locator getDataLocator()
          Returns the Locator of the resource referenced by this data object.
 boolean isDataInline()
          Determines the type of resource data provided by this data object.
 void setData(java.lang.String data)
          Sets the resource data string associated with this data object.
 void setDataLocator(org.tm4j.net.Locator loc)
          Sets the Locator of the resource referenced by this data object.
 

Method Detail

getDataLocator

public org.tm4j.net.Locator getDataLocator()
Returns the Locator of the resource referenced by this data object. If the data object provides inline data, this method will return null.


setDataLocator

public void setDataLocator(org.tm4j.net.Locator loc)
                    throws java.beans.PropertyVetoException
Sets the Locator of the resource referenced by this data object. The new value overwrites any previous resource locator or data string.


setData

public void setData(java.lang.String data)
             throws java.beans.PropertyVetoException
Sets the resource data string associated with this data object. The new value overwrites any previous data strings or resource locators.


getData

public java.lang.String getData()
Gets the resource data string associated with this occurrence. This function returns null if there is no resource data string associated with this occurrence.


isDataInline

public boolean isDataInline()
Determines the type of resource data provided by this data object.