![JAR search and dependency download from the Maven repository](/logo.png)
com.gs.collections.api.bag.ParallelUnsortedBag Maven / Gradle / Ivy
/*
* Copyright 2014 Goldman Sachs.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.gs.collections.api.bag;
import com.gs.collections.api.annotation.Beta;
import com.gs.collections.api.block.function.Function;
import com.gs.collections.api.block.function.Function2;
import com.gs.collections.api.block.predicate.Predicate;
import com.gs.collections.api.block.predicate.Predicate2;
import com.gs.collections.api.multimap.bag.UnsortedBagMultimap;
import com.gs.collections.api.set.ParallelUnsortedSetIterable;
/**
* @since 5.0
*/
@Beta
public interface ParallelUnsortedBag extends ParallelBag
{
ParallelUnsortedSetIterable asUnique();
/**
* Creates a parallel iterable for selecting elements from the current iterable.
*/
ParallelUnsortedBag select(Predicate super T> predicate);
ParallelUnsortedBag selectWith(Predicate2 super T, ? super P> predicate, P parameter);
/**
* Creates a parallel iterable for rejecting elements from the current iterable.
*/
ParallelUnsortedBag reject(Predicate super T> predicate);
ParallelUnsortedBag rejectWith(Predicate2 super T, ? super P> predicate, P parameter);
ParallelUnsortedBag selectInstancesOf(Class clazz);
/**
* Creates a parallel iterable for collecting elements from the current iterable.
*/
ParallelUnsortedBag collect(Function super T, ? extends V> function);
ParallelUnsortedBag collectWith(Function2 super T, ? super P, ? extends V> function, P parameter);
/**
* Creates a parallel iterable for selecting and collecting elements from the current iterable.
*/
ParallelUnsortedBag collectIf(Predicate super T> predicate, Function super T, ? extends V> function);
/**
* Creates a parallel flattening iterable for the current iterable.
*/
ParallelUnsortedBag flatCollect(Function super T, ? extends Iterable> function);
UnsortedBagMultimap groupBy(Function super T, ? extends V> function);
UnsortedBagMultimap groupByEach(Function super T, ? extends Iterable> function);
// /**
// * Returns a parallel BooleanIterable which will transform the underlying iterable data to boolean values based on the booleanFunction.
// */
// ParallelBooleanIterable collectBoolean(BooleanFunction super T> booleanFunction);
//
// /**
// * Returns a parallel ByteIterable which will transform the underlying iterable data to byte values based on the byteFunction.
// */
// ParallelByteIterable collectByte(ByteFunction super T> byteFunction);
//
// /**
// * Returns a parallel CharIterable which will transform the underlying iterable data to char values based on the charFunction.
// */
// ParallelCharIterable collectChar(CharFunction super T> charFunction);
//
// /**
// * Returns a parallel DoubleIterable which will transform the underlying iterable data to double values based on the doubleFunction.
// */
// ParallelDoubleIterable collectDouble(DoubleFunction super T> doubleFunction);
//
// /**
// * Returns a parallel FloatIterable which will transform the underlying iterable data to float values based on the floatFunction.
// */
// ParallelFloatIterable collectFloat(FloatFunction super T> floatFunction);
//
// /**
// * Returns a parallel IntIterable which will transform the underlying iterable data to int values based on the intFunction.
// */
// ParallelIntIterable collectInt(IntFunction super T> intFunction);
//
// /**
// * Returns a parallel LongIterable which will transform the underlying iterable data to long values based on the longFunction.
// */
// ParallelLongIterable collectLong(LongFunction super T> longFunction);
//
// /**
// * Returns a parallel ShortIterable which will transform the underlying iterable data to short values based on the shortFunction.
// */
// ParallelShortIterable collectShort(ShortFunction super T> shortFunction);
}