com.sleepycat.persist.impl
Class FieldInfo

java.lang.Object
  extended by com.sleepycat.persist.impl.FieldInfo
All Implemented Interfaces:
RawField, java.io.Serializable, java.lang.Comparable<FieldInfo>

 class FieldInfo
extends java.lang.Object
implements RawField, java.io.Serializable, java.lang.Comparable<FieldInfo>

A field definition used by ComplexFormat and CompositeKeyFormat.

Author:
Mark Hayes

Constructor Summary
FieldInfo(java.lang.reflect.Field field)
           
 
Method Summary
(package private)  void collectRelatedFormats(Catalog catalog, java.util.Map<java.lang.String,Format> newFormats)
           
 int compareTo(FieldInfo o)
           
 boolean equals(java.lang.Object other)
           
 RawType getExpandedType()
          Returns the type of the field, expanding parameterized types if they were declared for this field.
(package private) static FieldInfo getField(java.util.List<FieldInfo> fields, java.lang.String fieldName)
           
(package private)  java.lang.Class getFieldClass()
           
(package private) static java.util.List<FieldInfo> getInstanceFields(java.lang.Class cls)
          Returns a list of all non-transient non-static fields that are declared in the given class.
 java.lang.String getName()
          Returns the name of the field.
 Format getType()
          Returns the type of the field, without expanding parameterized types, or null if the type is an interface type or the Object class.
(package private)  void initialize(Catalog catalog)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FieldInfo

FieldInfo(java.lang.reflect.Field field)
Method Detail

getInstanceFields

static java.util.List<FieldInfo> getInstanceFields(java.lang.Class cls)
Returns a list of all non-transient non-static fields that are declared in the given class.


getField

static FieldInfo getField(java.util.List<FieldInfo> fields,
                          java.lang.String fieldName)

collectRelatedFormats

void collectRelatedFormats(Catalog catalog,
                           java.util.Map<java.lang.String,Format> newFormats)

initialize

void initialize(Catalog catalog)

getFieldClass

java.lang.Class getFieldClass()

getName

public java.lang.String getName()
Description copied from interface: RawField
Returns the name of the field.

Specified by:
getName in interface RawField

getType

public Format getType()
Description copied from interface: RawField
Returns the type of the field, without expanding parameterized types, or null if the type is an interface type or the Object class.

Specified by:
getType in interface RawField

getExpandedType

public RawType getExpandedType()
Description copied from interface: RawField
Returns the type of the field, expanding parameterized types if they were declared for this field. Generic type parameters are not expanded if running under Java 1.4, in which case this method is equivalent to RawField.getType().

Specified by:
getExpandedType in interface RawField

compareTo

public int compareTo(FieldInfo o)
Specified by:
compareTo in interface java.lang.Comparable<FieldInfo>

equals

public boolean equals(java.lang.Object other)
Overrides:
equals in class java.lang.Object


Copyright 2004-2006 Sleepycat, Inc. All Rights Reserved.