Class SequencePlanner.Sequence<T>
- java.lang.Object
-
- io.engineblock.activityapi.planning.SequencePlanner.Sequence<T>
-
- All Implemented Interfaces:
OpSequence<T>
- Enclosing class:
- SequencePlanner<T>
public static class SequencePlanner.Sequence<T> extends java.lang.Object implements OpSequence<T>
-
-
Method Summary
Modifier and Type Method Description Tget(long selector)Get the next operation for the given long value.java.util.List<T>getOps()Get the list of individual operations which could be returned byOpSequence.get(long).int[]getSequence()Get the integer sequence that is used to index into the operations.SequencerTypegetSequencerType()<U> SequencePlanner.Sequence<U>transform(java.util.function.Function<T,U> func)Map this OpSequence to another type of OpSequence.
-
-
-
Method Detail
-
get
public T get(long selector)
Description copied from interface:OpSequenceGet the next operation for the given long value. This is simply the offset indicated by the offset sequence array at a modulo position.- Specified by:
getin interfaceOpSequence<T>- Parameters:
selector- the long value that determines the next op- Returns:
- An op of type T
-
getOps
public java.util.List<T> getOps()
Description copied from interface:OpSequenceGet the list of individual operations which could be returned byOpSequence.get(long).- Specified by:
getOpsin interfaceOpSequence<T>- Returns:
- A
Listof T
-
getSequence
public int[] getSequence()
Description copied from interface:OpSequenceGet the integer sequence that is used to index into the operations.- Specified by:
getSequencein interfaceOpSequence<T>- Returns:
- an offset pointer array in int[] form
-
getSequencerType
public SequencerType getSequencerType()
-
transform
public <U> SequencePlanner.Sequence<U> transform(java.util.function.Function<T,U> func)
Description copied from interface:OpSequenceMap this OpSequence to another type of OpSequence.- Specified by:
transformin interfaceOpSequence<T>- Type Parameters:
U- The target type of the transformation.- Parameters:
func- The transformation function from this to another type- Returns:
- A new OpSequence of type U
-
-