com.xerox.bantam.util
Class FieldMapping

java.lang.Object
  |
  +--com.xerox.bantam.util.FieldMapping

public class FieldMapping
extends Object

Maintains a mapping from a named class field to the corresponding FieldDescriptor.

Version:
$Revision: 1.3 $, $Date: 2000/03/07 18:20:38 $
Author:
Tom Rodriguez

Constructor Summary
FieldMapping(String name, Class c, FieldDescriptor fd)
           
 
Method Summary
 boolean equals(Object o)
           
 Field getField()
           
 FieldDescriptor getFieldDescriptor()
           
static FieldMapping[] getFieldMappings(Class clazz)
          Get all the FieldMappings from clazz which are used to describe the schema they represent.
 String getName()
           
 int hashCode()
           
 void loadValue(Object o, Document doc)
           
 void saveValue(Object o, Document doc)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FieldMapping

public FieldMapping(String name,
                    Class c,
                    FieldDescriptor fd)
Method Detail

getName

public String getName()

getField

public Field getField()

getFieldDescriptor

public FieldDescriptor getFieldDescriptor()

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object

loadValue

public void loadValue(Object o,
                      Document doc)
               throws StorageException

saveValue

public void saveValue(Object o,
                      Document doc)
               throws StorageException

getFieldMappings

public static FieldMapping[] getFieldMappings(Class clazz)
Get all the FieldMappings from clazz which are used to describe the schema they represent.

Project Harland