public class EphemeralMappedField extends MappedField
| Constructor and Description |
|---|
EphemeralMappedField(ParameterizedType t,
MappedField mf,
Mapper mapper) |
EphemeralMappedField(Type t,
MappedField mf,
Mapper mapper) |
| Modifier and Type | Method and Description |
|---|---|
void |
addAnnotation(Class<? extends Annotation> clazz)
Adds the annotation, if it exists on the field.
|
void |
addAnnotation(Class<? extends Annotation> clazz,
Annotation ann)
Adds the annotation, if it exists on the field.
|
Object |
getDbObjectValue(DBObject dbObj) |
Object |
getFieldValue(Object classInst)
Returns the value stored in the java field
|
Class |
getMapKeyClass()
If the underlying java type is a map then it returns T from Map
|
protected String |
getMappedFieldName()
Returns the name of the field's key-name for mongodb
|
String |
getNameToStore()
Returns the name of the field's (key)name for mongodb
|
MappedField |
getParent() |
Class |
getSubClass()
If the java field is a list/array/map then the sub-type T is returned (ex.
|
Type |
getSubType() |
Class |
getType()
returns the type of the underlying java field
|
Object |
getValue() |
boolean |
hasAnnotation(Class ann)
Indicates whether the annotation is present in the mapping (does not check the java field annotations, just the ones discovered)
|
boolean |
isSingleValue() |
void |
setFieldValue(Object classInst,
Object val)
Sets the value for the java field
|
String |
toString() |
addInterestingAnnotation, discover, discoverType, getAnnotation, getAnnotations, getConcreteType, getCTor, getDeclaringClass, getField, getFirstFieldName, getFullName, getJavaFieldName, getLoadNames, getMapper, getTypeParameters, isArray, isMap, isMultipleValues, isReference, isSet, isTypeMongoCompatible, putAnnotation, toClasspublic EphemeralMappedField(ParameterizedType t, MappedField mf, Mapper mapper)
public EphemeralMappedField(Type t, MappedField mf, Mapper mapper)
public MappedField getParent()
public void addAnnotation(Class<? extends Annotation> clazz)
MappedFieldaddAnnotation in class MappedFieldpublic void addAnnotation(Class<? extends Annotation> clazz, Annotation ann)
MappedFieldaddAnnotation in class MappedFieldpublic Object getValue()
public String getNameToStore()
MappedFieldgetNameToStore in class MappedFieldpublic Object getDbObjectValue(DBObject dbObj)
getDbObjectValue in class MappedFieldpublic boolean hasAnnotation(Class ann)
MappedFieldhasAnnotation in class MappedFieldpublic String toString()
toString in class MappedFieldpublic Class getType()
MappedFieldgetType in class MappedFieldpublic Class getMapKeyClass()
MappedFieldgetMapKeyClass in class MappedFieldpublic Type getSubType()
getSubType in class MappedFieldpublic Class getSubClass()
MappedFieldgetSubClass in class MappedFieldpublic boolean isSingleValue()
isSingleValue in class MappedFieldpublic Object getFieldValue(Object classInst)
MappedFieldgetFieldValue in class MappedFieldpublic void setFieldValue(Object classInst, Object val)
MappedFieldsetFieldValue in class MappedFieldprotected String getMappedFieldName()
MappedFieldgetMappedFieldName in class MappedField