Top Fields Constructors Methods
org.eclipse.collections.impl.list.mutable

public Class MutableListFactoryImpl

extends Object
implements MutableListFactory
Class Inheritance
All Implemented Interfaces
org.eclipse.collections.api.factory.list.MutableListFactory
Annotations
@ServiceProvider:MutableListFactory
Imports
java.util.stream.Collectors, .Stream, org.eclipse.collections.api.block.function.Function0, org.eclipse.collections.api.factory.list.MutableListFactory, org.eclipse.collections.api.list.MutableList

Field Summary

Modifier and TypeField and Description
public static final MutableListFactory

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public <T> MutableList<T>
public <T> MutableList<T>
public <T> MutableList<T>
with(T... items)

Implements org.eclipse.collections.api.factory.list.MutableListFactory.with.

Creates a new list using the passed items argument as the backing store.

public <T> MutableList<T>
public <T> MutableList<T>
public <T> MutableList<T>
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

INSTANCEback to summary
public static final MutableListFactory INSTANCE

Constructor Detail

MutableListFactoryImplback to summary
public MutableListFactoryImpl()

Method Detail

emptyback to summary
public <T> MutableList<T> empty()

Implements org.eclipse.collections.api.factory.list.MutableListFactory.empty.

Annotations
@Override
fromStreamback to summary
public <T> MutableList<T> fromStream(Stream<? extends T> stream)

Implements org.eclipse.collections.api.factory.list.MutableListFactory.fromStream.

Annotations
@Override
withback to summary
public <T> MutableList<T> with(T... items)

Implements org.eclipse.collections.api.factory.list.MutableListFactory.with.

Creates a new list using the passed items argument as the backing store.

!!! WARNING: This method uses the passed in array, so can be very unsafe if the original array is held onto anywhere else.

Annotations
@Override
withAllback to summary
public <T> MutableList<T> withAll(Iterable<? extends T> iterable)

Implements org.eclipse.collections.api.factory.list.MutableListFactory.withAll.

Annotations
@Override
withInitialCapacityback to summary
public <T> MutableList<T> withInitialCapacity(int capacity)

Implements org.eclipse.collections.api.factory.list.MutableListFactory.withInitialCapacity.

Doc from org.eclipse.collections.api.factory.list.MutableListFactory.withInitialCapacity.

Same as empty(). but takes in initial capacity.

Annotations
@Override
withNValuesback to summary
public <T> MutableList<T> withNValues(int size, Function0<? extends T> factory)

Implements org.eclipse.collections.api.factory.list.MutableListFactory.withNValues.

Annotations
@Override