Class ClassConverter
- java.lang.Object
-
- science.aist.neo4j.reflective.converter.ClassConverter
-
- All Implemented Interfaces:
FieldConverter<String,Class>
public class ClassConverter extends Object implements FieldConverter<String,Class>
Converter for int values, as they are implicitly cast to Long by Neo4J- Since:
- 1.0
- Author:
- Oliver Krauss
-
-
Constructor Summary
Constructors Constructor Description ClassConverter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
mapForDb(String name, Class value, Map<String,Object> map)
Adds the value to the map for database processingClass
toJavaValue(Class currentValue, Object newValue)
Transforms from db value to value understood by the java class
-
-
-
Method Detail
-
mapForDb
public void mapForDb(String name, Class value, Map<String,Object> map)
Description copied from interface:FieldConverter
Adds the value to the map for database processing- Specified by:
mapForDb
in interfaceFieldConverter<String,Class>
- Parameters:
name
- of fieldvalue
- to be pushed to dbmap
- map the value will be entered in
-
toJavaValue
public Class toJavaValue(Class currentValue, Object newValue)
Description copied from interface:FieldConverter
Transforms from db value to value understood by the java class- Specified by:
toJavaValue
in interfaceFieldConverter<String,Class>
- Parameters:
currentValue
- value the java object has right nownewValue
- db to be transformed- Returns:
- Java value
-
-