com.hp.hpl.jena.ontology.daml
Interface DAMLDataInstance

All Superinterfaces:
DAMLCommon, DAMLInstance, FrontsNode, OntResource, RDFNode, Resource

public interface DAMLDataInstance
extends DAMLInstance

A data instance is a specific type of DAML object that represents the instantiation of a DAML datatype. The instance is a resource whose rdf:value is a typed literal.

Version:
CVS info: $Id: DAMLDataInstance.java,v 1.6 2004/12/06 13:50:18 andy_seaborne Exp $
Author:
Ian Dickinson, HP Labs (email)

Method Summary
 RDFDatatype getDatatype()
          Answer the typed value translator for values encoded by the datatype of this instance.
 Object getValue()
          Answer the value of this instance as a Java object, translated from the serialised RDF representation by the Dataype's type mapper.
 void setValue(Object value)
          Set the value of this instance to the given Java value, which will be serialised into the RDF graph by the datatype's translator.
 
Methods inherited from interface com.hp.hpl.jena.ontology.daml.DAMLInstance
accessProperty, getEquivalentValues, getSameInstances, prop_sameIndividualAs
 
Methods inherited from interface com.hp.hpl.jena.ontology.daml.DAMLCommon
getDAMLModel, getEquivalenceSet, getRDFTypes, getVocabulary, prop_comment, prop_equivalentTo, prop_label, prop_type, setRDFType
 
Methods inherited from interface com.hp.hpl.jena.ontology.OntResource
accessor, accessor, addComment, addComment, addDifferentFrom, addIsDefinedBy, addLabel, addLabel, addRDFType, addSameAs, addSeeAlso, addVersionInfo, asAllDifferent, asAnnotationProperty, asClass, asDataRange, asDatatypeProperty, asIndividual, asObjectProperty, asOntology, asProperty, getCardinality, getComment, getDifferentFrom, getIsDefinedBy, getLabel, getProfile, getPropertyValue, getRDFType, getRDFType, getSameAs, getSeeAlso, getVersionInfo, hasComment, hasComment, hasLabel, hasLabel, hasRDFType, hasRDFType, hasRDFType, hasSeeAlso, hasVersionInfo, isAllDifferent, isAnnotationProperty, isClass, isDataRange, isDatatypeProperty, isDefinedBy, isDifferentFrom, isIndividual, isObjectProperty, isOntology, isProperty, isSameAs, listComments, listDifferentFrom, listIsDefinedBy, listLabels, listPropertyValues, listRDFTypes, listSameAs, listSeeAlso, listVersionInfo, remove, removeComment, removeComment, removeDefinedBy, removeDifferentFrom, removeLabel, removeLabel, removeProperty, removeRDFType, removeSameAs, removeSeeAlso, removeVersionInfo, setComment, setDifferentFrom, setIsDefinedBy, setLabel, setPropertyValue, setRDFType, setSameAs, setSeeAlso, setVersionInfo
 
Methods inherited from interface com.hp.hpl.jena.rdf.model.Resource
abort, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, begin, commit, equals, getId, getLocalName, getModel, getNameSpace, getNode, getProperty, getRequiredProperty, getURI, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasURI, isAnon, listProperties, listProperties, removeAll, removeProperties, toString
 
Methods inherited from interface com.hp.hpl.jena.rdf.model.RDFNode
as, canAs, inModel, visitWith
 
Methods inherited from interface com.hp.hpl.jena.graph.FrontsNode
asNode
 

Method Detail

getDatatype

RDFDatatype getDatatype()

Answer the typed value translator for values encoded by the datatype of this instance.

Returns:
The datatype translator defined for the rdf:type of this instance

getValue

Object getValue()

Answer the value of this instance as a Java object, translated from the serialised RDF representation by the Dataype's type mapper.

Returns:
The value of this instance, or null if either the translator or the serialised value is defined

setValue

void setValue(Object value)

Set the value of this instance to the given Java value, which will be serialised into the RDF graph by the datatype's translator.



Copyright © 2000, 2001, 2002, 2003, 2004 Hewlett-Packard Development Company, LP