|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A property restriction that requires the named property to have have at most the given number of values for a given instance to be a member of the class defined by the restriction.
Method Summary | |
int |
getMaxCardinality()
Answer the maximum cardinality of the restricted property. |
boolean |
hasMaxCardinality(int cardinality)
Answer true if this property restriction has the given maximum cardinality. |
void |
removeMaxCardinality(int cardinality)
Remove the statement that this restriction has the given maximum cardinality for the restricted property. |
void |
setMaxCardinality(int cardinality)
Assert that this restriction restricts the property to have the given maximum cardinality. |
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, getURI, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, hasProperty, isAnon, listProperties, listProperties, removeAll, removeProperties, toString |
Methods inherited from interface com.hp.hpl.jena.rdf.model.RDFNode |
as, asNode, canAs, inModel, visitWith |
Method Detail |
public void setMaxCardinality(int cardinality)
Assert that this restriction restricts the property to have the given
maximum cardinality. Any existing statements for maxCardinality
will be removed.
cardinality
- The maximum cardinality of the restricted property
OntProfileException
- If the Profile.MAX_CARDINALITY()
property is not supported in the current language profile.public int getMaxCardinality()
Answer the maximum cardinality of the restricted property.
OntProfileException
- If the Profile.MAX_CARDINALITY()
property is not supported in the current language profile.public boolean hasMaxCardinality(int cardinality)
Answer true if this property restriction has the given maximum cardinality.
cardinality
- The cardinality to test against
OntProfileException
- If the Profile.MAX_CARDINALITY()
property is not supported in the current language profile.public void removeMaxCardinality(int cardinality)
Remove the statement that this restriction has the given maximum cardinality for the restricted property. If this statement is not true of the current model, nothing happens.
cardinality
- A max cardinality value to be removed from this restriction
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |