- All Superinterfaces:
PsyObject
- All Known Subinterfaces:
PsyBounded
,PsyContainer<T>
,PsyFormalArray<T>
,PsyFormalDict<V>
,PsyFormalQueue<T>
,PsyFormalSet<T>
,PsyTextual
- All Known Implementing Classes:
PsyArray
,PsyBitArray
,PsyBitSet
,PsyBlockingQueue
,PsyConfigDict
,PsyDict
,PsyEnvironment
,PsyModule
,PsyName
,PsyNamespace
,PsyProc
,PsySet
,PsyString
,PsyStringBuffer
,PsySystemDict
The representation of
lengthy
, an object that has length in some sense. Usually the
length is the number of elements in the container.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ContextAction
Context action of theisempty
operator.static final ContextAction
Context action of thelength
operator.Fields inherited from interface coneforest.psylla.core.PsyObject
PSY_CLONE, PSY_EQ, PSY_HASHCODE, PSY_INSTANCEOF, PSY_NE, PSY_TOSTRING, PSY_TOSTRINGBUFFER, PSY_TYPE
-
Method Summary
Modifier and TypeMethodDescriptiondefault boolean
isEmpty()
int
length()
Returns a length of this object.default PsyBoolean
Returns aboolean
indicating if this container is empty (has zero length).default PsyInteger
Returns aninteger
representing the length of this object.Methods inherited from interface coneforest.psylla.core.PsyObject
convert, execute, invoke, psyClone, psyEq, psyHashCode, psyInstanceOf, psyNe, psySyntax, psyToString, psyToStringBuffer, psyType, toSyntaxString, typeName
-
Field Details
-
PSY_ISEMPTY
Context action of theisempty
operator. -
PSY_LENGTH
Context action of thelength
operator.
-
-
Method Details
-
length
int length()Returns a length of this object.- Returns:
- a length of this object
-
isEmpty
default boolean isEmpty() -
psyLength
Returns aninteger
representing the length of this object.- Returns:
- an
integer
representing the length of this object
-
psyIsEmpty
Returns aboolean
indicating if this container is empty (has zero length).- Returns:
- a
boolean
indicating if this container is empty (has zero length)
-