public class WeekDayCollection extends AbstractList<T>
Represents a collection of WeekDay
objects.
Modifier and Type | Method and Description |
---|---|
void |
add(int index,
WeekDay item)
Inserts
WeekDay at specified index. |
boolean |
add(WeekDay item)
Adds a
WeekDay instance to this object. |
void |
clear()
Clear the WeekDayCollection object.
|
boolean |
contains(WeekDay item)
Checks if collection contains
WeekDay .specified. |
void |
copyTo(WeekDay[] array,
int arrayIndex)
Copies collection content to an array at specified index.
|
WeekDay |
get(int index)
(@inheritDoc}
|
Calendar |
getParentCalendar()
Deprecated.
This property is obsolete and will be removed after the release 21.04.
|
int |
indexOf(WeekDay item)
Returns index of
WeekDay specified. |
boolean |
isReadOnly()
Is collection read-only.
|
Iterator<WeekDay> |
iterator()
Returns an enumerator for this collection.
|
WeekDay |
remove(int index) |
boolean |
remove(Object obj)
Removes
WeekDay specified, if any. |
int |
size()
Gets the number of objects contained in this
WeekDayCollection object. |
void |
sort(Comparator<? super T> c) |
List<WeekDay> |
toList()
Converts the WeekDayCollection object to a list of
WeekDay objects. |
addAll, equals, hashCode, indexOf, lastIndexOf, listIterator, listIterator, set, subList
addAll, contains, containsAll, isEmpty, removeAll, retainAll, toArray, toArray, toString
addAll, contains, containsAll, isEmpty, removeAll, replaceAll, retainAll, spliterator, toArray, toArray
parallelStream, removeIf, stream
public final boolean add(WeekDay item)
Adds a WeekDay
instance to this object.
add
in interface Collection<WeekDay>
add
in interface List<WeekDay>
add
in class AbstractList<WeekDay>
item
- The item to add.public final void clear()
Clear the WeekDayCollection object.
clear
in interface Collection<WeekDay>
clear
in interface List<WeekDay>
clear
in class AbstractList<WeekDay>
public final boolean contains(WeekDay item)
Checks if collection contains WeekDay
.specified.
item
- The item to check against to.public final void copyTo(WeekDay[] array, int arrayIndex)
Copies collection content to an array at specified index.
array
- Destination array of WeekDay
to copy toarrayIndex
- Starting index for copy operation.@Deprecated public final Calendar getParentCalendar()
Gets the parent calendar for this object.
public final WeekDay get(int index)
public final int indexOf(WeekDay item)
Returns index of WeekDay
specified.
item
- The item to check against to.WeekDay
specified, if present, or -1 otherwise.public final boolean isReadOnly()
public final boolean remove(Object obj)
Removes WeekDay
specified, if any.
remove
in interface Collection<WeekDay>
remove
in interface List<WeekDay>
remove
in class AbstractCollection<WeekDay>
item
- The item to remove.WeekDay
was removed, false if such item was not found.public final WeekDay remove(int index)
public final int size()
Gets the number of objects contained in this WeekDayCollection
object.
size
in interface Collection<WeekDay>
size
in interface List<WeekDay>
size
in class AbstractCollection<WeekDay>
WeekDayCollection
object.public final List<WeekDay> toList()
Converts the WeekDayCollection object to a list of WeekDay
objects.
WeekDay
objects.public void sort(Comparator<? super T> c)
c
-