org.openrdf.elmo.impl
Class ElmoMapperClassFactory

java.lang.Object
  extended by org.openrdf.elmo.impl.ElmoMapperClassFactory
All Implemented Interfaces:
ImplementationResolver

public class ElmoMapperClassFactory
extends Object
implements ImplementationResolver

Properties that have the rdf or localname annotation are replaced with getters and setters that access the Sesame Repository directly.

Author:
James Leigh

Constructor Summary
ElmoMapperClassFactory()
           
 
Method Summary
 Collection<Class<?>> findImplementations(Collection<Class<?>> interfaces)
          Resolves mapper classes that will map any annotated property in the interfaces.
static Class<?> getClassType(Method method)
           
static Class<?> getContentClassType(Method method)
           
static Type[] getContentTypeArguments(Method method)
           
 Method getReadMethod(Field field)
           
static Type[] getTypeArguments(Method method)
           
 Method getWriteMethod(Field field)
           
 void setClassDefiner(ClassFactory definer)
           
 void setElmoPropertyFactoryClass(Class<? extends ElmoPropertyFactory> propertyFactoryClass)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ElmoMapperClassFactory

public ElmoMapperClassFactory()
Method Detail

setClassDefiner

public void setClassDefiner(ClassFactory definer)

setElmoPropertyFactoryClass

public void setElmoPropertyFactoryClass(Class<? extends ElmoPropertyFactory> propertyFactoryClass)

getReadMethod

public Method getReadMethod(Field field)
                     throws Exception
Specified by:
getReadMethod in interface ImplementationResolver
Throws:
Exception

getWriteMethod

public Method getWriteMethod(Field field)
                      throws Exception
Specified by:
getWriteMethod in interface ImplementationResolver
Throws:
Exception

findImplementations

public Collection<Class<?>> findImplementations(Collection<Class<?>> interfaces)
Description copied from interface: ImplementationResolver
Resolves mapper classes that will map any annotated property in the interfaces.

Specified by:
findImplementations in interface ImplementationResolver
Parameters:
interfaces - concepts with @rdf annotated properties
Returns:
A collection concrete mapping behaviours.

getClassType

public static Class<?> getClassType(Method method)

getContentClassType

public static Class<?> getContentClassType(Method method)

getTypeArguments

public static Type[] getTypeArguments(Method method)

getContentTypeArguments

public static Type[] getContentTypeArguments(Method method)


Copyright © 2004-2008 Aduna. All Rights Reserved.