|
org.codehaus.gpars | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object groovyx.gpars.extra166y.AbstractParallelAnyArray.OPap groovyx.gpars.extra166y.ParallelArrayWithMapping
public abstract class ParallelArrayWithMapping extends OPap
A prefix view of ParallelArray that causes operations to apply to mappings of elements, not to the elements themselves. Instances of this class may be constructed only via prefix methods of ParallelArray or its other prefix classes.
Constructor Summary | |
ParallelArrayWithMapping(ForkJoinPool ex, int origin, int fence, java.lang.Object[] array)
|
Method Summary | |
---|---|
ParallelArray
|
all()
Returns a new ParallelArray holding elements. |
ParallelArray
|
all(java.lang.Class elementType)
Returns a new ParallelArray with the given element type holding elements. |
java.lang.Object
|
any()
Returns some element matching bound and filter constraints, or null if none. |
void
|
apply(Procedure procedure)
Applies the given procedure to elements. |
java.lang.Object
|
max(java.util.Comparator comparator)
Returns the maximum element, or null if empty. |
java.lang.Object
|
max()
Returns the maximum element, or null if empty, assuming that all elements are Comparables. |
java.lang.Object
|
min(java.util.Comparator comparator)
Returns the minimum element, or null if empty. |
java.lang.Object
|
min()
Returns the minimum element, or null if empty, assuming that all elements are Comparables. |
java.lang.Object
|
reduce(Reducer reducer, java.lang.Object base)
Returns reduction of elements. |
java.lang.Iterable
|
sequentially()
Returns an Iterable view to sequentially step through mapped elements also obeying bound and filter constraints, without performing computations to evaluate them in parallel. |
SummaryStatistics
|
summary(java.util.Comparator comparator)
Returns summary statistics, using the given comparator to locate minimum and maximum elements. |
SummaryStatistics
|
summary()
Returns summary statistics, assuming that all elements are Comparables. |
ParallelArrayWithMapping
|
withIndexedMapping(IntAndObjectToObject mapper)
Returns an operation prefix that causes a method to operate on mappings of this array using the given mapper that accepts as arguments an element's current index and value (as mapped by preceding mappings, if any), and produces a new value. |
ParallelArrayWithDoubleMapping
|
withIndexedMapping(IntAndObjectToDouble mapper)
Returns an operation prefix that causes a method to operate on mappings of this array using the given mapper that accepts as arguments an element's current index and value (as mapped by preceding mappings, if any), and produces a new value. |
ParallelArrayWithLongMapping
|
withIndexedMapping(IntAndObjectToLong mapper)
Returns an operation prefix that causes a method to operate on mappings of this array using the given mapper that accepts as arguments an element's current index and value (as mapped by preceding mappings, if any), and produces a new value. |
ParallelArrayWithMapping
|
withMapping(Op op)
Returns an operation prefix that causes a method to operate on mapped elements of the array using the given op applied to current op's results. |
ParallelArrayWithDoubleMapping
|
withMapping(ObjectToDouble op)
Returns an operation prefix that causes a method to operate on mapped elements of the array using the given op applied to current op's results. |
ParallelArrayWithLongMapping
|
withMapping(ObjectToLong op)
Returns an operation prefix that causes a method to operate on mapped elements of the array using the given op applied to current op's results. |
ParallelArrayWithMapping
|
withMapping(BinaryOp combiner, ParallelArrayWithMapping other)
Returns an operation prefix that causes a method to operate on binary mappings of this array and the other array. |
ParallelArrayWithMapping
|
withMapping(ObjectAndDoubleToObject combiner, ParallelDoubleArrayWithDoubleMapping other)
Returns an operation prefix that causes a method to operate on binary mappings of this array and the other array. |
ParallelArrayWithMapping
|
withMapping(ObjectAndLongToObject combiner, ParallelLongArrayWithLongMapping other)
Returns an operation prefix that causes a method to operate on binary mappings of this array and the other array. |
ParallelArrayWithDoubleMapping
|
withMapping(ObjectAndObjectToDouble combiner, ParallelArrayWithMapping other)
Returns an operation prefix that causes a method to operate on binary mappings of this array and the other array. |
ParallelArrayWithDoubleMapping
|
withMapping(ObjectAndDoubleToDouble combiner, ParallelDoubleArrayWithDoubleMapping other)
Returns an operation prefix that causes a method to operate on binary mappings of this array and the other array. |
ParallelArrayWithDoubleMapping
|
withMapping(ObjectAndLongToDouble combiner, ParallelLongArrayWithLongMapping other)
Returns an operation prefix that causes a method to operate on binary mappings of this array and the other array. |
ParallelArrayWithLongMapping
|
withMapping(ObjectAndObjectToLong combiner, ParallelArrayWithMapping other)
Returns an operation prefix that causes a method to operate on binary mappings of this array and the other array. |
ParallelArrayWithLongMapping
|
withMapping(ObjectAndDoubleToLong combiner, ParallelDoubleArrayWithDoubleMapping other)
Returns an operation prefix that causes a method to operate on binary mappings of this array and the other array. |
ParallelArrayWithLongMapping
|
withMapping(ObjectAndLongToLong combiner, ParallelLongArrayWithLongMapping other)
Returns an operation prefix that causes a method to operate on binary mappings of this array and the other array. |
Constructor Detail |
---|
ParallelArrayWithMapping(ForkJoinPool ex, int origin, int fence, java.lang.Object[] array)
Method Detail |
---|
public ParallelArray all()
public ParallelArray all(java.lang.Class elementType)
elementType
- the type of the elements
public java.lang.Object any()
public void apply(Procedure procedure)
procedure
- the procedure
public java.lang.Object max(java.util.Comparator comparator)
comparator
- the comparator
public java.lang.Object max()
public java.lang.Object min(java.util.Comparator comparator)
comparator
- the comparator
public java.lang.Object min()
public java.lang.Object reduce(Reducer reducer, java.lang.Object base)
reducer
- the reducerbase
- the result for an empty array
public java.lang.Iterable sequentially()
public SummaryStatistics summary(java.util.Comparator comparator)
comparator
- the comparator to use for
locating minimum and maximum elements
public SummaryStatistics summary()
public ParallelArrayWithMapping withIndexedMapping(IntAndObjectToObject mapper)
mapper
- the mapper
public ParallelArrayWithDoubleMapping withIndexedMapping(IntAndObjectToDouble mapper)
mapper
- the mapper
public ParallelArrayWithLongMapping withIndexedMapping(IntAndObjectToLong mapper)
mapper
- the mapper
public ParallelArrayWithMapping withMapping(Op op)
op
- the op
public ParallelArrayWithDoubleMapping withMapping(ObjectToDouble op)
op
- the op
public ParallelArrayWithLongMapping withMapping(ObjectToLong op)
op
- the op
public ParallelArrayWithMapping withMapping(BinaryOp combiner, ParallelArrayWithMapping other)
combiner
- the combinerother
- the other array
public ParallelArrayWithMapping withMapping(ObjectAndDoubleToObject combiner, ParallelDoubleArrayWithDoubleMapping other)
combiner
- the combinerother
- the other array
public ParallelArrayWithMapping withMapping(ObjectAndLongToObject combiner, ParallelLongArrayWithLongMapping other)
combiner
- the combinerother
- the other array
public ParallelArrayWithDoubleMapping withMapping(ObjectAndObjectToDouble combiner, ParallelArrayWithMapping other)
combiner
- the combinerother
- the other array
public ParallelArrayWithDoubleMapping withMapping(ObjectAndDoubleToDouble combiner, ParallelDoubleArrayWithDoubleMapping other)
combiner
- the combinerother
- the other array
public ParallelArrayWithDoubleMapping withMapping(ObjectAndLongToDouble combiner, ParallelLongArrayWithLongMapping other)
combiner
- the combinerother
- the other array
public ParallelArrayWithLongMapping withMapping(ObjectAndObjectToLong combiner, ParallelArrayWithMapping other)
combiner
- the combinerother
- the other array
public ParallelArrayWithLongMapping withMapping(ObjectAndDoubleToLong combiner, ParallelDoubleArrayWithDoubleMapping other)
combiner
- the combinerother
- the other array
public ParallelArrayWithLongMapping withMapping(ObjectAndLongToLong combiner, ParallelLongArrayWithLongMapping other)
combiner
- the combinerother
- the other array
Copyright © 2008–2013 Václav Pech. All Rights Reserved.