Package coneforest.psylla.core
Interface PsyFormalSet<T extends PsyObject>
- Type Parameters:
T
- a type of the elements.
- All Superinterfaces:
Iterable<T>
,PsyAppendable<T>
,PsyClearable
,PsyContainer<T>
,PsyConvertableToName
,PsyConvertableToString
,PsyIterable<T>
,PsyLengthy
,PsyObject
,PsySequential<T>
,PsyStreamable<T>
A representation of a
formalset
, an abstraction of a finite set of
object
s. This interface declares methods for appending, removal and
set operations.-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiondefault void
psyAppendAll
(PsyIterable<? extends T> oEnumeration) Appends all theobject
s from a giveniterable
enumeration to this set.default void
psyClear()
Removes all the elements from this set.psyContains
(T o) Returns aboolean
object indicating whether a givenobject
belongs to this set.default PsyBoolean
psyIntersects
(PsyFormalSet<? extends T> oSet) Returns aboolean
object indicating whether a givenformalset
set intersects with this set.void
Removes anobject
from this set.default void
psyRemoveAll
(PsyIterable<? extends T> oEnumeration) Removes all theobject
s in a giveniterable
enumeration from this set.default PsyFormalSet<T>
psyReplicate
(PsyInteger oCount) default void
psyRetainAll
(PsyIterable<? extends T> oEnumeration) default String
default String
toSyntaxStringHelper
(PsyLengthy oLengthy) Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
Methods inherited from interface coneforest.psylla.core.PsyAppendable
psyAppend
Methods inherited from interface coneforest.psylla.core.PsyContainer
psyNewEmpty, toSyntaxStringHelper
Methods inherited from interface coneforest.psylla.core.PsyIterable
psyStream, psyToArray, psyUnite
Methods inherited from interface coneforest.psylla.core.PsyLengthy
isEmpty, length, psyIsEmpty, psyLength
Methods inherited from interface coneforest.psylla.core.PsyObject
convert, execute, invoke, psyClone, psyEq, psyHashCode, psyInstanceOf, psyNe, psySyntax, psyToName, psyToString, psyType, typeName
Methods inherited from interface coneforest.psylla.core.PsyStreamable
psyForAll
-
Field Details
-
OPERATORS
-
-
Method Details
-
psyRemove
Removes anobject
from this set. If a given object is not present in this set, error does not occur.- Parameters:
o
- anobject
.
-
psyRemoveAll
Removes all theobject
s in a giveniterable
enumeration from this set. If some object is not present in this set, error does not occur.- Parameters:
oEnumeration
- aniterable
enumeration.
-
psyRetainAll
- Throws:
PsyErrorException
-
psyContains
Returns aboolean
object indicating whether a givenobject
belongs to this set.- Parameters:
o
- anobject
.- Returns:
PsyBoolean.TRUE
, if an object belongs to this set, andPsyBoolean.FALSE
otherwise.
-
psyClear
default void psyClear()Removes all the elements from this set.- Specified by:
psyClear
in interfacePsyClearable
-
psyAppendAll
Appends all theobject
s from a giveniterable
enumeration to this set. When a given enumeration is the same as this set, first clone the enumeration, and then appends all the elements from the clone.- Specified by:
psyAppendAll
in interfacePsyAppendable<T extends PsyObject>
- Parameters:
oEnumeration
- aniterable
enumeration.- Throws:
PsyErrorException
- when an error occurs.
-
psyIntersects
Returns aboolean
object indicating whether a givenformalset
set intersects with this set.- Parameters:
oSet
- aformalset
set.- Returns:
PsyBoolean.TRUE
, if a givenformalset
set intersects with this set, andPsyBoolean.FALSE
otherwise.
-
psyReplicate
- Specified by:
psyReplicate
in interfacePsyAppendable<T extends PsyObject>
- Throws:
PsyErrorException
-
toSyntaxString
- Specified by:
toSyntaxString
in interfacePsyObject
-
toSyntaxStringHelper
-