Class OntologyProperty
Class for representing a property in an Ontology.
Inherited Members
Namespace: VDS.RDF.Ontology
Assembly: dotNetRdf.Ontology.dll
Syntax
public class OntologyProperty : OntologyResource
Remarks
See Using the Ontology API for some informal documentation on the use of the Ontology namespace.
Constructors
| Edit this page View SourceOntologyProperty(Uri, IGraph)
Creates a new RDFS Ontology Property for the given resource in the given Graph.
Declaration
public OntologyProperty(Uri resource, IGraph graph)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
IGraph | graph | Graph. |
OntologyProperty(INode, IGraph)
Creates a new Ontology Property for the given resource in the given Graph.
Declaration
public OntologyProperty(INode resource, IGraph graph)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
IGraph | graph | Graph. |
Properties
| Edit this page View SourceDirectSubProperties
Gets the direct sub-classes of this class.
Declaration
public IEnumerable<OntologyProperty> DirectSubProperties { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyProperty> |
DirectSuperProperties
Gets the direct super-properties of this property.
Declaration
public IEnumerable<OntologyProperty> DirectSuperProperties { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyProperty> |
Domains
Gets all the Classes which are in the properties Domain.
Declaration
public IEnumerable<OntologyClass> Domains { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyClass> |
EquivalentProperties
Gets all the equivalent properties of this property.
Declaration
public IEnumerable<OntologyProperty> EquivalentProperties { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyProperty> |
IndirectSubProperties
Gets the indirect sub-classes of this class.
Declaration
public IEnumerable<OntologyProperty> IndirectSubProperties { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyProperty> |
IndirectSuperProperty
Gets the indirect super-properties of this property.
Declaration
public IEnumerable<OntologyProperty> IndirectSuperProperty { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyProperty> |
InverseProperties
Gets all the inverse properties of this property.
Declaration
public IEnumerable<OntologyProperty> InverseProperties { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyProperty> |
IsBottomProperty
Gets whether this is a btoom property i.e. has no sub properties defined.
Declaration
public bool IsBottomProperty { get; }
Property Value
Type | Description |
---|---|
bool |
IsTopProperty
Gets whether this is a top property i.e. has no super properties defined.
Declaration
public bool IsTopProperty { get; }
Property Value
Type | Description |
---|---|
bool |
Ranges
Gets all the Classes which are in this properties Range.
Declaration
public IEnumerable<OntologyClass> Ranges { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyClass> |
Siblings
Gets the Sibling properties of this property, if this property is the root of the ontology nothing is returned even if there are multiple root properties.
Declaration
public IEnumerable<OntologyProperty> Siblings { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyProperty> |
SubProperties
Gets the sub-properties of this property (both direct and indirect).
Declaration
public IEnumerable<OntologyProperty> SubProperties { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyProperty> |
SuperProperties
Gets the super-properties of this property (both direct and indirect).
Declaration
public IEnumerable<OntologyProperty> SuperProperties { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyProperty> |
UsedBy
Gets all the resources that use this property.
Declaration
public IEnumerable<OntologyResource> UsedBy { get; }
Property Value
Type | Description |
---|---|
IEnumerable<OntologyResource> |
Methods
| Edit this page View SourceAddDomain(Uri)
Adds a new domain for the property.
Declaration
public bool AddDomain(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddDomain(INode)
Adds a new domain for the property.
Declaration
public bool AddDomain(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddDomain(OntologyResource)
Adds a new domain for the property.
Declaration
public bool AddDomain(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddEquivalentProperty(Uri)
Adds a new equivalent property for the property.
Declaration
public bool AddEquivalentProperty(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddEquivalentProperty(INode)
Adds a new equivalent property for the property.
Declaration
public bool AddEquivalentProperty(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddEquivalentProperty(OntologyProperty)
Adds a new equivalent property for the property.
Declaration
public bool AddEquivalentProperty(OntologyProperty property)
Parameters
Type | Name | Description |
---|---|---|
OntologyProperty | property | Property. |
Returns
Type | Description |
---|---|
bool |
Remarks
This overload also adds this property as an equivalent property of the given property.
AddEquivalentProperty(OntologyResource)
Adds a new equivalent property for the property.
Declaration
public bool AddEquivalentProperty(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddInverseProperty(Uri)
Adds an inverse property for the property.
Declaration
public bool AddInverseProperty(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddInverseProperty(INode)
Adds an inverse property for the property.
Declaration
public bool AddInverseProperty(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddInverseProperty(OntologyProperty)
Adds an inverse property for the property.
Declaration
public bool AddInverseProperty(OntologyProperty property)
Parameters
Type | Name | Description |
---|---|---|
OntologyProperty | property | Property. |
Returns
Type | Description |
---|---|
bool |
Remarks
This overload also adds this property as an inverse property of the given property.
AddInverseProperty(OntologyResource)
Adds an inverse property for the property.
Declaration
public bool AddInverseProperty(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddRange(Uri)
Adds a new range for the property.
Declaration
public bool AddRange(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddRange(INode)
Adds a new range for the property.
Declaration
public bool AddRange(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddRange(OntologyResource)
Adds a new range for the property.
Declaration
public bool AddRange(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddSubProperty(Uri)
Adds a sub-property for the property.
Declaration
public bool AddSubProperty(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddSubProperty(INode)
Adds a sub-property for the property.
Declaration
public bool AddSubProperty(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddSubProperty(OntologyProperty)
Adds a sub-property for the property.
Declaration
public bool AddSubProperty(OntologyProperty property)
Parameters
Type | Name | Description |
---|---|---|
OntologyProperty | property | Property. |
Returns
Type | Description |
---|---|
bool |
Remarks
This overload also adds this property as a super-property of the given property.
AddSubProperty(OntologyResource)
Adds a sub-property for the property.
Declaration
public bool AddSubProperty(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddSuperProperty(Uri)
Adds a super-property for the property.
Declaration
public bool AddSuperProperty(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddSuperProperty(INode)
Adds a super-property for the property.
Declaration
public bool AddSuperProperty(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
AddSuperProperty(OntologyProperty)
Adds a super-property for the property.
Declaration
public bool AddSuperProperty(OntologyProperty property)
Parameters
Type | Name | Description |
---|---|---|
OntologyProperty | property | Property. |
Returns
Type | Description |
---|---|
bool |
Remarks
This overload also adds this property as a sub-property of the given property.
AddSuperProperty(OntologyResource)
Adds a super-property for the property.
Declaration
public bool AddSuperProperty(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
ClearDomains()
Clears all domains for the property.
Declaration
public bool ClearDomains()
Returns
Type | Description |
---|---|
bool |
ClearEquivalentProperties()
Clears all equivalent properties for this property.
Declaration
public bool ClearEquivalentProperties()
Returns
Type | Description |
---|---|
bool |
ClearInverseProperties()
Removes all inverse properties for this property.
Declaration
public bool ClearInverseProperties()
Returns
Type | Description |
---|---|
bool |
ClearRanges()
Clears all ranges for the property.
Declaration
public bool ClearRanges()
Returns
Type | Description |
---|---|
bool |
ClearSubProperties()
Clears all sub-properties of this property.
Declaration
public bool ClearSubProperties()
Returns
Type | Description |
---|---|
bool |
ClearSuperProperties()
Removes all super-properties of this property.
Declaration
public bool ClearSuperProperties()
Returns
Type | Description |
---|---|
bool |
RemoveDomain(Uri)
Removes a domain for the property.
Declaration
public bool RemoveDomain(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveDomain(INode)
Removes a domain for the property.
Declaration
public bool RemoveDomain(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveDomain(OntologyResource)
Removes a domain for the property.
Declaration
public bool RemoveDomain(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveEquivalentProperty(Uri)
Removes an equivalent property for the property.
Declaration
public bool RemoveEquivalentProperty(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveEquivalentProperty(INode)
Removes an equivalent property for the property.
Declaration
public bool RemoveEquivalentProperty(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveEquivalentProperty(OntologyProperty)
Removes an equivalent property for the property.
Declaration
public bool RemoveEquivalentProperty(OntologyProperty property)
Parameters
Type | Name | Description |
---|---|---|
OntologyProperty | property | Property. |
Returns
Type | Description |
---|---|
bool |
Remarks
This overload also removes this property as an equivalent property of the given property.
RemoveEquivalentProperty(OntologyResource)
Removes an equivalent property for the property.
Declaration
public bool RemoveEquivalentProperty(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveInverseProperty(Uri)
Removes an inverse property for the property.
Declaration
public bool RemoveInverseProperty(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveInverseProperty(INode)
Removes an inverse property for the property.
Declaration
public bool RemoveInverseProperty(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveInverseProperty(OntologyProperty)
Removes an inverse property for the property.
Declaration
public bool RemoveInverseProperty(OntologyProperty property)
Parameters
Type | Name | Description |
---|---|---|
OntologyProperty | property | Property. |
Returns
Type | Description |
---|---|
bool |
Remarks
This overload also removes this property as an inverse property of the given property.
RemoveInverseProperty(OntologyResource)
Removes an inverse property for the property.
Declaration
public bool RemoveInverseProperty(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveRange(Uri)
Removes a range for the property.
Declaration
public bool RemoveRange(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveRange(INode)
Removes a range for the property.
Declaration
public bool RemoveRange(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveRange(OntologyResource)
Removes a range for the property.
Declaration
public bool RemoveRange(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveSubProperty(Uri)
Removes a sub-property for the property.
Declaration
public bool RemoveSubProperty(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveSubProperty(INode)
Removes a sub-property for the property.
Declaration
public bool RemoveSubProperty(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveSubProperty(OntologyProperty)
Removes a sub-property for the property.
Declaration
public bool RemoveSubProperty(OntologyProperty property)
Parameters
Type | Name | Description |
---|---|---|
OntologyProperty | property | Property. |
Returns
Type | Description |
---|---|
bool |
Remarks
This overload also removes this property as a super-property of the given property.
RemoveSubProperty(OntologyResource)
Removes a sub-property for the property.
Declaration
public bool RemoveSubProperty(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveSuperProperty(Uri)
Removes a super-property for the property.
Declaration
public bool RemoveSuperProperty(Uri resource)
Parameters
Type | Name | Description |
---|---|---|
Uri | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveSuperProperty(INode)
Removes a super-property for the property.
Declaration
public bool RemoveSuperProperty(INode resource)
Parameters
Type | Name | Description |
---|---|---|
INode | resource | Resource. |
Returns
Type | Description |
---|---|
bool |
RemoveSuperProperty(OntologyProperty)
Removes a super-property for the property.
Declaration
public bool RemoveSuperProperty(OntologyProperty property)
Parameters
Type | Name | Description |
---|---|---|
OntologyProperty | property | Property. |
Returns
Type | Description |
---|---|
bool |
Remarks
This overload also removes this property as a sub-property of the given property.
RemoveSuperProperty(OntologyResource)
Removes a super-property for the property.
Declaration
public bool RemoveSuperProperty(OntologyResource resource)
Parameters
Type | Name | Description |
---|---|---|
OntologyResource | resource | Resource. |
Returns
Type | Description |
---|---|
bool |