uk.ac.starlink.votable
Class FieldElement

java.lang.Object
  |
  +--uk.ac.starlink.votable.VOElement
        |
        +--uk.ac.starlink.votable.FieldElement
Direct Known Subclasses:
ParamElement

public class FieldElement
extends VOElement

Table column characteristics represented by a FIELD element in a VOTable.


Constructor Summary
FieldElement(Element el, String systemId)
           
 
Method Summary
 ValuesElement getActualValues()
          Returns a VALUES child of this element with the attribute type='actual', or null if none exists.
 long[] getArraysize()
          Returns the array size.
 String getDatatype()
          Returns the value of the datatype attribute.
 ValuesElement getLegalValues()
          Returns a VALUES child of this element with the attribute type='legal', or null if none exists.
 String getNull()
          Returns the 'null' value for this FieldElement.
 String getUcd()
          Returns the value of the ucd attribute, or null if there is none.
 String getUnit()
          Returns the value of the unit attribute, or null if there is none.
 String toString()
          Returns the same value as VOElement.getHandle().
 
Methods inherited from class uk.ac.starlink.votable.VOElement
equals, getAttribute, getAttribute, getChildByName, getChildren, getChildrenByName, getContext, getDescendantsByName, getDescription, getElement, getHandle, getID, getName, getParent, getSource, getSystemId, getTagName, getTextContent, hasAttribute, hashCode
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FieldElement

public FieldElement(Element el,
                    String systemId)
Method Detail

getArraysize

public long[] getArraysize()
Returns the array size. The returned value is an array of long, with one element for each dimension. The final dimension only may have the value -1, which indicates that this dimension is unknown. All other elements will be positive.

Returns:
array giving dimensions of data in this field.

getDatatype

public String getDatatype()
Returns the value of the datatype attribute.

Returns:
the datatype

getNull

public String getNull()
Returns the 'null' value for this FieldElement. This is the value of the 'null' attribute of the VALUES child with type='legal', or if that doesn't exist the 'null' attribute of the VALUES child with type='actual' (this is some kind of guesswork based on what is not written in the VOTable document). This has nothing to do with the java null value.

Returns:
the bad ("null") value or, confusingly, null if none is defined

getUnit

public String getUnit()
Returns the value of the unit attribute, or null if there is none.

Returns:
the unit string

getUcd

public String getUcd()
Returns the value of the ucd attribute, or null if there is none.

Returns:
the ucd string
See Also:
UCD

getLegalValues

public ValuesElement getLegalValues()
Returns a VALUES child of this element with the attribute type='legal', or null if none exists.

Returns:
the 'legal' Values object

getActualValues

public ValuesElement getActualValues()
Returns a VALUES child of this element with the attribute type='actual', or null if none exists.

Returns:
the 'actual' Values object

toString

public String toString()
Description copied from class: VOElement
Returns the same value as VOElement.getHandle().

Overrides:
toString in class VOElement
Returns:
a string representation of this object

Copyright © 2004 CLRC: Central Laboratory of the Research Councils. All rights reserved.