com.hp.hpl.jena.daml.common
Class DAMLObjectPropertyImpl

java.lang.Object
  |
  +--com.hp.hpl.mesa.rdf.jena.common.ResourceImpl
        |
        +--com.hp.hpl.jena.daml.common.DAMLCommonImpl
              |
              +--com.hp.hpl.jena.daml.common.DAMLPropertyImpl
                    |
                    +--com.hp.hpl.jena.daml.common.DAMLObjectPropertyImpl
All Implemented Interfaces:
DAMLCommon, DAMLObjectProperty, DAMLProperty, Property, RDFNode, Resource, ResourceI

public class DAMLObjectPropertyImpl
extends DAMLPropertyImpl
implements DAMLObjectProperty

Implementation for Java encapsulation of an object property in a DAML ontology. An object property is a partition of the class of properties, in which the range of the property is a DAML instance (rather than a datatype). Object properties may be transitive and unambiguous, which are modelled in the specification by sub-classes of ObjectProperty named TransitiveProperty and UnambiguousProperty. In this API, transitivity and uniqueness are modelled as attributes of the DAMLObjectProperty object.

Version:
CVS info: $Id: DAMLObjectPropertyImpl.java,v 1.2 2002/02/22 17:05:06 ian_dickinson Exp $
Author:
Ian Dickinson, HP Labs (email)

Constructor Summary
DAMLObjectPropertyImpl(java.lang.String uri, DAMLModel store, DAMLVocabulary vocabulary)
          Constructor, takes the URI for this property, and the underlying model it will be attached to.
DAMLObjectPropertyImpl(java.lang.String namespace, java.lang.String name, DAMLModel store, DAMLVocabulary vocabulary)
          Constructor, takes the name and namespace for this property, and the underlying model it will be attached to.
 
Method Summary
 boolean isTransitive()
          Answer true if this property is to be considered transitive, that is it is characterised by the DAML class TransitiveProperty
 boolean isUnambiguous()
          Answer true if this property is to be considered unabiguous, that is it is characterised by the DAML class UnambiguousProperty
 PropertyAccessor prop_inverseOf()
          Property accessor for the 'inverseOf' property of a DAML Property.
 void setIsTransitive(boolean transitive)
          Set the flag to indicate that this property is to be considered transitive - that is, it is defined by the DAML class TransitiveProperty.
 void setIsUnambiguous(boolean unambiguous)
          Set the flag to indicate that this property is to be considered unambiguous - that is, it is defined by the DAML class UnambiguousProperty.
 java.lang.String toString()
          Return a readable representation of the DAML value
 
Methods inherited from class com.hp.hpl.jena.daml.common.DAMLPropertyImpl
getDomainClasses, getEquivalentValues, getOrdinal, getRangeClasses, getSameProperties, getSubProperties, getSubProperties, getSuperProperties, getSuperProperties, isUnique, port, prop_domain, prop_range, prop_samePropertyAs, prop_subPropertyOf, setIsUnique
 
Methods inherited from class com.hp.hpl.jena.daml.common.DAMLCommonImpl
getAll, getDAMLModel, getEquivalenceSet, getNumPropertyValues, getPropertyValue, getPropertyValues, getRDFTypes, getSelfIterator, getVocabulary, hasRDFType, hasRDFType, prop_comment, prop_equivalentTo, prop_label, prop_type, remove, removeAll, removeProperty, replaceProperty, setPropertyValue, setRDFType, setRDFType
 
Methods inherited from class com.hp.hpl.mesa.rdf.jena.common.ResourceImpl
abort, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, begin, commit, equals, getEmbeddedResource, getId, getLocalName, getModel, getNameSpace, getProperty, getURI, hashCode, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, isAnon, listProperties, listProperties, removeProperties
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.hp.hpl.jena.daml.DAMLProperty
getDomainClasses, getEquivalentValues, getRangeClasses, getSameProperties, getSubProperties, getSubProperties, getSuperProperties, getSuperProperties, isUnique, prop_domain, prop_range, prop_samePropertyAs, prop_subPropertyOf, setIsUnique
 
Methods inherited from interface com.hp.hpl.jena.daml.DAMLCommon
getAll, getDAMLModel, getEquivalenceSet, getNumPropertyValues, getPropertyValue, getPropertyValues, getRDFTypes, getVocabulary, hasRDFType, hasRDFType, prop_comment, prop_equivalentTo, prop_label, prop_type, remove, removeAll, removeProperty, replaceProperty, setPropertyValue, setRDFType, setRDFType
 
Methods inherited from interface com.hp.hpl.mesa.rdf.jena.model.Resource
abort, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, addProperty, begin, commit, equals, getId, getLocalName, getModel, getNameSpace, getProperty, getURI, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, isAnon, listProperties, listProperties, removeProperties
 
Methods inherited from interface com.hp.hpl.mesa.rdf.jena.model.Property
getLocalName, getNameSpace, getOrdinal
 

Constructor Detail

DAMLObjectPropertyImpl

public DAMLObjectPropertyImpl(java.lang.String namespace,
                              java.lang.String name,
                              DAMLModel store,
                              DAMLVocabulary vocabulary)
Constructor, takes the name and namespace for this property, and the underlying model it will be attached to.
Parameters:
namespace - The namespace the property inhabits, or null
name - The name of the property
store - The RDF store that contains the RDF statements defining the properties of the property
vocabulary - Reference to the DAML vocabulary used by this property.

DAMLObjectPropertyImpl

public DAMLObjectPropertyImpl(java.lang.String uri,
                              DAMLModel store,
                              DAMLVocabulary vocabulary)
Constructor, takes the URI for this property, and the underlying model it will be attached to.
Parameters:
uri - The URI of the property
store - The RDF store that contains the RDF statements defining the properties of the property
vocabulary - Reference to the DAML vocabulary used by this property.
Method Detail

toString

public java.lang.String toString()
Return a readable representation of the DAML value
Specified by:
toString in interface Resource
Overrides:
toString in class DAMLPropertyImpl
Returns:
a string denoting this value

setIsTransitive

public void setIsTransitive(boolean transitive)
Set the flag to indicate that this property is to be considered transitive - that is, it is defined by the DAML class TransitiveProperty.
Specified by:
setIsTransitive in interface DAMLObjectProperty
Parameters:
transitive - True for a transitive property

isTransitive

public boolean isTransitive()
Answer true if this property is to be considered transitive, that is it is characterised by the DAML class TransitiveProperty
Specified by:
isTransitive in interface DAMLObjectProperty
Returns:
True if this property is transitive

setIsUnambiguous

public void setIsUnambiguous(boolean unambiguous)
Set the flag to indicate that this property is to be considered unambiguous - that is, it is defined by the DAML class UnambiguousProperty.
Specified by:
setIsUnambiguous in interface DAMLObjectProperty
Parameters:
unambiguous - True for a unambiguous property

isUnambiguous

public boolean isUnambiguous()
Answer true if this property is to be considered unabiguous, that is it is characterised by the DAML class UnambiguousProperty
Specified by:
isUnambiguous in interface DAMLObjectProperty
Returns:
True if this property is unambiguous

prop_inverseOf

public PropertyAccessor prop_inverseOf()
Property accessor for the 'inverseOf' property of a DAML Property. This denotes that the named property (say, P) is an inverse of this property (say, Q). Formally, if (x, y) is an instance of P, then (y, x) is an instance of Q.
Specified by:
prop_inverseOf in interface DAMLObjectProperty
Returns:
Property accessor for 'inverseOf'


Copyright © 2001 Hewlett-Packard. All Rights Reserved.