com.vividsolutions.jump.feature
Class AttributeType

java.lang.Object
  extended by com.vividsolutions.jump.feature.AttributeType
All Implemented Interfaces:
java.io.Serializable

public class AttributeType
extends java.lang.Object
implements java.io.Serializable

Whether an attribute on a feature is a string, geometry, integer, etc.

See Also:
FeatureSchema, Serialized Form

Field Summary
static AttributeType DATE
          For dates
static AttributeType DOUBLE
          For double-precision values (64-bit)
static AttributeType GEOMETRY
          For spatial data
static AttributeType INTEGER
          For long values (64-bit)
static AttributeType OBJECT
          Experimental
static AttributeType STRING
          For strings
 
Method Summary
static java.util.Collection allTypes()
          Returns all instances of AttributeType.
static AttributeType toAttributeType(java.lang.Class javaClass)
          Returns the AttributeType of attributes that are instances of the given class, or null if it is not associated with any AttributeType.
static AttributeType toAttributeType(java.lang.String name)
          Converts a type name to an AttributeType.
 java.lang.Class toJavaClass()
          Returns the Java class of attributes that are said to be of this AttributeType.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

STRING

public static final AttributeType STRING
For strings


GEOMETRY

public static final AttributeType GEOMETRY
For spatial data


INTEGER

public static final AttributeType INTEGER
For long values (64-bit)


DATE

public static final AttributeType DATE
For dates

See Also:
Date

DOUBLE

public static final AttributeType DOUBLE
For double-precision values (64-bit)


OBJECT

public static final AttributeType OBJECT
Experimental

Method Detail

allTypes

public static java.util.Collection allTypes()
Returns all instances of AttributeType.


toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

toAttributeType

public static final AttributeType toAttributeType(java.lang.String name)
Converts a type name to an AttributeType.

Parameters:
typename - the name of the AttributeType to retrieve
Returns:
the corresponding AttributeType
Throws:
InvalidAttributeTypeException - if the type name is unrecognized

toJavaClass

public java.lang.Class toJavaClass()
Returns the Java class of attributes that are said to be of this AttributeType.


toAttributeType

public static AttributeType toAttributeType(java.lang.Class javaClass)
Returns the AttributeType of attributes that are instances of the given class, or null if it is not associated with any AttributeType.