Package com.gs.collections.api.list.primitive

Examples of com.gs.collections.api.list.primitive.MutableFloatList


        return this.toList().toArray();
    }

    public MutableFloatList toList()
    {
        final MutableFloatList list = new FloatArrayList();
        this.forEach(new FloatProcedure()
        {
            public void value(float each)
            {
                list.add(each);
            }
        });
        return list;
    }
View Full Code Here


        this.checkSizeLessThanCount(count);
        if (count == 0)
        {
            return new FloatArrayList();
        }
        MutableFloatList subList = new FloatArrayList(count);
        int index = this.delegate.size() - 1;
        for (int i = 0; i < count; i++)
        {
            subList.add(this.delegate.get(index - i));
        }
        return subList;
    }
View Full Code Here

            FloatFunction<? super T> floatFunction)
    {
        int size = list.size();
        if (ArrayListIterate.isOptimizableArrayList(list, size))
        {
            MutableFloatList result = new FloatArrayList(size);
            return ArrayListIterate.collectFloatFromInternalArray(list, floatFunction, size, result);
        }
        return RandomAccessListIterate.collectFloat(list, floatFunction);
    }
View Full Code Here

        return new ImmutableFloatArrayList(newItems);
    }

    public ImmutableFloatList newWithoutAll(FloatIterable elements)
    {
        MutableFloatList mutableFloatList = this.toList();
        mutableFloatList.removeAll(elements);
        return mutableFloatList.toImmutable();
    }
View Full Code Here

    {
        if (objectArray == null)
        {
            throw new IllegalArgumentException("Cannot perform a collectFloat on null");
        }
        MutableFloatList result = new FloatArrayList(objectArray.length);
        for (T each : objectArray)
        {
            result.add(floatFunction.floatValueOf(each));
        }
        return result;
    }
View Full Code Here

        this.checkSizeLessThanCount(count);
        if (count == 0)
        {
            return new FloatArrayList(0);
        }
        MutableFloatList subList = new FloatArrayList(count);
        while (count > 0)
        {
            subList.add(this.pop());
            count--;
        }
        return subList;
    }
View Full Code Here

        this.checkSizeLessThanCount(count);
        if (count == 0)
        {
            return new FloatArrayList(0);
        }
        MutableFloatList subList = new FloatArrayList(count);
        int index = this.delegate.size() - 1;
        for (int i = 0; i < count; i++)
        {
            subList.add(this.delegate.get(index - i));
        }
        return subList;
    }
View Full Code Here

        return (double) sortedArray[middleIndex];
    }

    public MutableFloatList toList()
    {
        MutableFloatList result = new FloatArrayList(this.size());

        for (int i = 0; i < this.keys.length; i++)
        {
            if (isNonSentinel(this.keys[i]))
            {
                result.add(this.values[i]);
            }
        }
        return result;
    }
View Full Code Here

TOP

Related Classes of com.gs.collections.api.list.primitive.MutableFloatList

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.