Package org.synchronoss.cpo.core.meta
Class MethodMapper<T extends MethodMapEntry<?,?>>
java.lang.Object
org.synchronoss.cpo.core.meta.MethodMapper<T>
- Type Parameters:
T- the concreteMethodMapEntrytype registered by the datastore implementation
- All Implemented Interfaces:
Serializable,Cloneable
public class MethodMapper<T extends MethodMapEntry<?,?>>
extends Object
implements Serializable, Cloneable
MethodMapper maps java classes to the datastore-specific getter and setter methods used to bind
them. Each datastore implementation registers its own entries.
- Author:
- david berry
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddMethodMapEntry(T dataMethodMapEntry) Registers a method map entry, keyed by itsMethodMapEntry.getJavaClass().getDataMethodMapEntry(Class<?> c) Gets the method map entry registered for the given Java class.
-
Constructor Details
-
MethodMapper
public MethodMapper()Creates an empty mapper with no registered entries.
-
-
Method Details
-
getDataMethodMapEntry
Gets the method map entry registered for the given Java class.- Parameters:
c- the Java class to look up- Returns:
- the entry registered for
c, ornullif none is registered - Throws:
CpoException- if the entry cannot be retrieved
-
addMethodMapEntry
Registers a method map entry, keyed by itsMethodMapEntry.getJavaClass().- Parameters:
dataMethodMapEntry- the entry to register
-