Package org.aksw.jenax.arq.util.type
Class TypeMapperUtils
java.lang.Object
org.aksw.jenax.arq.util.type.TypeMapperUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic List<org.apache.jena.datatypes.RDFDatatype>getTypesBySubClassOf(org.apache.jena.datatypes.TypeMapper tm, Class<?> cls) Find all RDFDatatypes in a TypeMapper whose backing Java type is a sub class (reflexive) of 'cls'.
-
Constructor Details
-
TypeMapperUtils
public TypeMapperUtils()
-
-
Method Details
-
getTypesBySubClassOf
public static List<org.apache.jena.datatypes.RDFDatatype> getTypesBySubClassOf(org.apache.jena.datatypes.TypeMapper tm, Class<?> cls) Find all RDFDatatypes in a TypeMapper whose backing Java type is a sub class (reflexive) of 'cls'. The motivation for implementing this method was to detect that xsd:string (backed by String) is a suitable type for wherever CharSequence is required. However, the TypeMapper (by default) already also contains a mapping from xsd:normalizedString to String. Hence, for this use case this method is not suitable because the result is not unique.
-