public abstract class ImgFactory<T> extends Object
| Constructor and Description |
|---|
ImgFactory()
Deprecated.
|
ImgFactory(T type) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
cache(T type)
Deprecated.
|
Img<T> |
create(Dimensions dimensions)
Create an
Img<T> with the specified dimensions. |
Img<T> |
create(Dimensions dim,
T type)
Deprecated.
|
Img<T> |
create(int[] dimensions)
Create an
Img<T> with the specified dimensions. |
Img<T> |
create(int[] dim,
T type)
Deprecated.
|
abstract Img<T> |
create(long... dimensions)
Create an
Img<T> with the specified dimensions. |
abstract Img<T> |
create(long[] dim,
T type)
Deprecated.
|
Img<T> |
create(Supplier<T> typeSupplier,
Dimensions dim)
Deprecated.
|
Img<T> |
create(Supplier<T> typeSupplier,
int[] dim)
Deprecated.
|
Img<T> |
create(Supplier<T> typeSupplier,
long... dim)
Deprecated.
|
abstract <S> ImgFactory<S> |
imgFactory(S type)
Creates the same
ImgFactory for a different generic parameter if
possible. |
<S> ImgFactory<S> |
imgFactory(Supplier<S> typeSupplier)
Creates the same
ImgFactory for a different generic parameter if
possible. |
T |
type() |
public ImgFactory(T type)
@Deprecated public ImgFactory()
public T type()
public abstract Img<T> create(long... dimensions)
Img<T> with the specified dimensions.dimensions.public Img<T> create(Dimensions dimensions)
Img<T> with the specified dimensions.dimensions.public Img<T> create(int[] dimensions)
Img<T> with the specified dimensions.
Note: This is not a vararg function because the underlying int[]
based methods already copies the int[] dimensions into a
disposable long[] anyways. This would be an unnecessary copy for
int... varargs.
dimensions.public abstract <S> ImgFactory<S> imgFactory(S type) throws IncompatibleTypeException
ImgFactory for a different generic parameter if
possible.
If the type "S" does not suit the needs of the ImgFactory (for
example implement NativeType in all NativeImgFactory,
this method will throw an IncompatibleTypeException.S - the new typetype - an instance of SImgFactory of type SIncompatibleTypeException - if type S is not compatiblepublic <S> ImgFactory<S> imgFactory(Supplier<S> typeSupplier) throws IncompatibleTypeException
ImgFactory for a different generic parameter if
possible.
If the supplied type "S" does not suit the needs of the
ImgFactory (for example implement NativeType in all
NativeImgFactory, this method will throw an
IncompatibleTypeException.S - the new typetypeSupplier - a supplier of SImgFactory of type SIncompatibleTypeException - if type S is not compatible@Deprecated public abstract Img<T> create(long[] dim, T type)
@Deprecated public Img<T> create(Dimensions dim, T type)
@Deprecated public Img<T> create(int[] dim, T type)
@Deprecated public Img<T> create(Supplier<T> typeSupplier, long... dim)
@Deprecated public Img<T> create(Supplier<T> typeSupplier, Dimensions dim)
@Deprecated public Img<T> create(Supplier<T> typeSupplier, int[] dim)
@Deprecated protected void cache(T type)
type becomes the cached instance. In this way, if the factory was
created using one of the deprecated typeless constructor signatures, but
then one of the deprecated create methods is called (i.e.: a
method which provides a type instance as an argument), the provided type
becomes the cached type instance so that subsequent invocations of the
typeless create methods will work as desired.type - The type to cache if needed.Copyright © 2015–2022 ImgLib2. All rights reserved.