org.eclipse.ocl.examples.domain.values.impl
Class SequenceRangeImpl
java.lang.Object
org.eclipse.ocl.examples.domain.values.impl.AbstractValue
org.eclipse.ocl.examples.domain.values.impl.AbstractedCollectionValue
org.eclipse.ocl.examples.domain.values.impl.AbstractCollectionValue<L>
org.eclipse.ocl.examples.domain.values.impl.AbstractSequenceValue<IntegerRange>
org.eclipse.ocl.examples.domain.values.impl.SequenceRangeImpl
- All Implemented Interfaces:
- java.lang.Iterable<Value>, CollectionValue, SequenceValue, Value
public class SequenceRangeImpl
- extends AbstractSequenceValue<IntegerRange>
| Fields inherited from interface org.eclipse.ocl.examples.domain.values.Value |
INVALID_NAME |
| Methods inherited from class org.eclipse.ocl.examples.domain.values.impl.AbstractSequenceValue |
asList, asSequenceValue, at, excluding, getKind, indexOf, insertAt, reverse, sort, subSequence, toSequenceValue |
| Methods inherited from class org.eclipse.ocl.examples.domain.values.impl.AbstractCollectionValue |
asBagValue, asEcoreObject, asOrderedSetValue, asSetValue, excludes, excludesAll, flatten, getBagType, getCollectionType, getElementType, getOrderedSetType, getSequenceType, getSetType, hashCode, includes, includesAll, intersection, intSize, iterator, maxMin, product, selectByKind, selectByType, sum, union |
| Methods inherited from class org.eclipse.ocl.examples.domain.values.impl.AbstractedCollectionValue |
asCollection, asCollectionValue, asObject, asValidValue, getActualType, getType, isCollectionValue, isEmpty, notEmpty, size, toString |
| Methods inherited from class org.eclipse.ocl.examples.domain.values.impl.AbstractValue |
asBoolean, asBooleanValue, asDouble, asElement, asElementValue, asInteger, asIntegerValue, asNavigableObject, asObjectValue, asRealValue, asString, asStringValue, asTypeValue, asUniqueCollectionValue, getValueFactory, isFalse, isIntegerValue, isInvalid, isNull, isRealValue, isTrue, isUndefined, isUnlimited, isUnlimitedNatural, oclToString, toIntegerValue, toRealValue |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.eclipse.ocl.examples.domain.values.CollectionValue |
asCollection, excludes, excludesAll, flatten, getCollectionType, includes, includesAll, intersection, intSize, isEmpty, iterator, maxMin, notEmpty, product, selectByKind, selectByType, size, sum, union |
| Methods inherited from interface org.eclipse.ocl.examples.domain.values.Value |
asBagValue, asBoolean, asBooleanValue, asCollectionValue, asDouble, asEcoreObject, asElement, asElementValue, asInteger, asIntegerValue, asNavigableObject, asObject, asObjectValue, asOrderedSetValue, asRealValue, asSetValue, asString, asStringValue, asTypeValue, asUniqueCollectionValue, asValidValue, getActualType, getType, getValueFactory, isCollectionValue, isFalse, isIntegerValue, isInvalid, isNull, isRealValue, isTrue, isUndefined, isUnlimited, isUnlimitedNatural, oclToString, toIntegerValue, toRealValue |
SequenceRangeImpl
public SequenceRangeImpl(ValueFactory valueFactory,
DomainCollectionType type,
IntegerRange range)
append
public SequenceValue append(Value value)
throws InvalidValueException
- Specified by:
append in interface SequenceValue- Overrides:
append in class AbstractSequenceValue<IntegerRange>
- Throws:
InvalidValueException
count
public IntegerValue count(Value value)
throws InvalidValueException
- Description copied from class:
AbstractCollectionValue
- Implementation of the OCL
Collection::count(object : T) : Integer
operation.
- Specified by:
count in interface CollectionValue- Overrides:
count in class AbstractCollectionValue<IntegerRange>
- Returns:
- the number of occurrences of the object in the collection
- Throws:
InvalidValueException
createElements
protected java.util.List<Value> createElements()
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals in class AbstractSequenceValue<IntegerRange>
first
public Value first()
- Specified by:
first in interface SequenceValue- Overrides:
first in class AbstractSequenceValue<IntegerRange>
flatten
public SequenceValue flatten()
- Specified by:
flatten in interface CollectionValue- Overrides:
flatten in class AbstractSequenceValue<IntegerRange>
getElements
public java.util.List<Value> getElements()
- Overrides:
getElements in class AbstractCollectionValue<IntegerRange>
including
public SequenceValue including(Value value)
throws InvalidValueException
- Specified by:
including in interface CollectionValue- Overrides:
including in class AbstractSequenceValue<IntegerRange>
- Throws:
InvalidValueException
last
public Value last()
- Specified by:
last in interface SequenceValue- Overrides:
last in class AbstractSequenceValue<IntegerRange>
prepend
public SequenceValue prepend(Value value)
throws InvalidValueException
- Specified by:
prepend in interface SequenceValue- Overrides:
prepend in class AbstractSequenceValue<IntegerRange>
- Throws:
InvalidValueException
toIteratorValue
public java.util.Iterator<Value> toIteratorValue()
throws InvalidValueException
- Specified by:
toIteratorValue in interface Value- Overrides:
toIteratorValue in class AbstractValue
- Throws:
InvalidValueException
toString
public void toString(java.lang.StringBuilder s,
int lengthLimit)
- Specified by:
toString in interface Value- Overrides:
toString in class AbstractSequenceValue<IntegerRange>