|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.semanticweb.kaon2.extensionapi.datatype.DatatypeManager
public class DatatypeManager
This is the registry of all datatypes. Applications with custom datatypes should register appropriate datatype handlers with this class.
| Field Summary | |
|---|---|
protected static java.lang.String[] |
NO_URIS
|
protected static java.util.Map<java.lang.String,DatatypeHandler> |
s_handlersByDatatypeURI
The list of all registered handlers. |
| Constructor Summary | |
|---|---|
DatatypeManager()
|
|
| Method Summary | |
|---|---|
static java.lang.String |
getDatatypeURI(java.lang.Object object)
Returns the URI of the datatype of the given object. |
static java.lang.Object |
parseObject(java.lang.String objectValue,
java.lang.String datatypeURI)
Parses the object with the given datatype URI. |
static void |
registerDatatypeHandler(DatatypeHandler datatypeHandler)
Registers a datatype handler with this manager. |
static java.lang.String |
toString(java.lang.Object object)
Converts the given object into a string representation. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final java.lang.String[] NO_URIS
protected static final java.util.Map<java.lang.String,DatatypeHandler> s_handlersByDatatypeURI
| Constructor Detail |
|---|
public DatatypeManager()
| Method Detail |
|---|
public static void registerDatatypeHandler(DatatypeHandler datatypeHandler)
datatypeHandler - the datatype handlerpublic static java.lang.String getDatatypeURI(java.lang.Object object)
object - the object
null if the datatype URI cannot be determinedpublic static java.lang.String toString(java.lang.Object object)
object - the object
null if the handler for the datatype cannot be found
public static java.lang.Object parseObject(java.lang.String objectValue,
java.lang.String datatypeURI)
throws KAON2Exception
objectValue - the value of the objectdatatypeURI - the URI of the datatype
KAON2Exception - thrown if there is an error
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||