public static enum ListActivityRepository.IteratorType extends Enum<ListActivityRepository.IteratorType>
Enum Constant and Description |
---|
BINARY_ITERATOR
Causes the repository to return an instance of type
BinarySearchActivityIterator . |
LINEAR_ITERATOR
Causes the repository to return an instance of type
LinearSearchActivityIterator . |
SIMPLE_ITERATOR
Causes the repository to return the normal list iterator (
List.iterator() ), which means that the repository will always
return all activities independent of whether they are located within
the given time interval. |
Modifier and Type | Method and Description |
---|---|
static ListActivityRepository.IteratorType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ListActivityRepository.IteratorType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ListActivityRepository.IteratorType SIMPLE_ITERATOR
List.iterator()
), which means that the repository will always
return all activities independent of whether they are located within
the given time interval.public static final ListActivityRepository.IteratorType BINARY_ITERATOR
BinarySearchActivityIterator
. This type of iterator performs
a log-n binary search to find only those activities that are located
within the given time interval.public static final ListActivityRepository.IteratorType LINEAR_ITERATOR
LinearSearchActivityIterator
. This type of iterator performs
a left to right (index = 0 to n) within the underlying list to find
the first visible activity inside the given time interval. The
iterator stops once it reaches an activity with a start time after
the given time interval.public static ListActivityRepository.IteratorType[] values()
for (ListActivityRepository.IteratorType c : ListActivityRepository.IteratorType.values()) System.out.println(c);
public static ListActivityRepository.IteratorType valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullCopyright © 2020 Dirk Lemmermann Software & Consulting. All rights reserved.