|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.clarkparsia.pellet.datatypes.types.duration.RestrictedDurationDatatype
public class RestrictedDurationDatatype
Title: Restricted Duration Datatype
Description: A subset of the value space of xsd:duration
Copyright: Copyright (c) 2009
Company: Clark & Parsia, LLC.
| Constructor Summary | |
|---|---|
RestrictedDurationDatatype(Datatype<javax.xml.datatype.Duration> dt)
|
|
| Method Summary | |
|---|---|
RestrictedDatatype<javax.xml.datatype.Duration> |
applyConstrainingFacet(aterm.ATermAppl facet,
java.lang.Object value)
Apply a constraining facet to further restrict the value space |
boolean |
contains(java.lang.Object value)
Check if a data range contains a particular value |
boolean |
containsAtLeast(int n)
Check that a data range contains a minimum number of elements |
RestrictedDatatype<javax.xml.datatype.Duration> |
exclude(java.util.Collection<?> values)
Exclude specific elements from the data range. |
Datatype<? extends javax.xml.datatype.Duration> |
getDatatype()
Query for the base datatype of a restricted datatype. |
javax.xml.datatype.Duration |
getValue(int i)
Return a value from an enumerable data range. |
RestrictedDatatype<javax.xml.datatype.Duration> |
intersect(RestrictedDatatype<?> other,
boolean negated)
Intersect this range with another range. |
boolean |
isEmpty()
Convenience method equivalent to !containsAtLeast(0) |
boolean |
isEnumerable()
Query if values in the data range can be enumerated. |
boolean |
isFinite()
Query if there are a finite number of values in the data range. |
int |
size()
Return the size of the data range. |
RestrictedDatatype<javax.xml.datatype.Duration> |
union(RestrictedDatatype<?> other)
Union this range with another range. |
java.util.Iterator<javax.xml.datatype.Duration> |
valueIterator()
Get a (possibly infinite) iterator over values in the data range. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RestrictedDurationDatatype(Datatype<javax.xml.datatype.Duration> dt)
| Method Detail |
|---|
public RestrictedDatatype<javax.xml.datatype.Duration> applyConstrainingFacet(aterm.ATermAppl facet,
java.lang.Object value)
throws InvalidConstrainingFacetException
RestrictedDatatype
applyConstrainingFacet in interface RestrictedDatatype<javax.xml.datatype.Duration>facet - the constraining facet name (typically a URI)value - the value for the constraining facet. This is not necessarily
in the value space of the base datatype (e.g., length facet
values on string types are not)
InvalidConstrainingFacetExceptionpublic boolean contains(java.lang.Object value)
DataRange
contains in interface DataRange<javax.xml.datatype.Duration>value - the value to check
true if the data range contains value,
false elsepublic boolean containsAtLeast(int n)
DataRange
containsAtLeast in interface DataRange<javax.xml.datatype.Duration>n - the number of elements
true if the data range contains n or
more elements, false otherwisepublic RestrictedDatatype<javax.xml.datatype.Duration> exclude(java.util.Collection<?> values)
RestrictedDatatypevalues that are not contained in the restriction are
ignored.
exclude in interface RestrictedDatatype<javax.xml.datatype.Duration>values - The values to exclude
RestrictedDatatypepublic Datatype<? extends javax.xml.datatype.Duration> getDatatype()
RestrictedDatatype
getDatatype in interface RestrictedDatatype<javax.xml.datatype.Duration>public javax.xml.datatype.Duration getValue(int i)
DataRangeLiteralValueBranch shiftTryNext
getValue in interface DataRange<javax.xml.datatype.Duration>i - the index of the value in the data range
public RestrictedDatatype<javax.xml.datatype.Duration> intersect(RestrictedDatatype<?> other,
boolean negated)
RestrictedDatatypegetDatatype().getPrimitiveDatatype().equals( other.getDatatype.getPrimiveDatatype()
intersect in interface RestrictedDatatype<javax.xml.datatype.Duration>other - restricted datatype to merge into thisnegated - true if other is negated,
false else
RestrictedDatatype, representing the intersection
of this and otherpublic boolean isEmpty()
DataRange!containsAtLeast(0)
isEmpty in interface DataRange<javax.xml.datatype.Duration>true if the data range contains no elements,
false otherwisepublic boolean isEnumerable()
DataRange
isEnumerable in interface DataRange<javax.xml.datatype.Duration>true if the data range is enumerable,
false otherwisepublic boolean isFinite()
DataRange
isFinite in interface DataRange<javax.xml.datatype.Duration>true if the data range is finite, false
otherwisepublic int size()
DataRangeLiteralValueBranch constructor
size in interface DataRange<javax.xml.datatype.Duration>public RestrictedDatatype<javax.xml.datatype.Duration> union(RestrictedDatatype<?> other)
RestrictedDatatypegetDatatype().getPrimitiveDatatype().equals( other.getDatatype.getPrimiveDatatype()
union in interface RestrictedDatatype<javax.xml.datatype.Duration>other - restricted datatype to merge with this
RestrictedDatatype, representing the intersection
of this and otherpublic java.util.Iterator<javax.xml.datatype.Duration> valueIterator()
DataRange
valueIterator in interface DataRange<javax.xml.datatype.Duration>Iterator
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||