Class ImgFactory<T>
java.lang.Object
net.imglib2.img.ImgFactory<T>
- Direct Known Subclasses:
ListImgFactory, NativeImgFactory
TODO
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidDeprecated.create(int[] dimensions) Create anImg<T>with the specifieddimensions.Deprecated.create(long... dimensions) Create anImg<T>with the specifieddimensions.Deprecated.Deprecated.Deprecated.create(Supplier<T> typeSupplier, Dimensions dim) Deprecated.create(Dimensions dimensions) Create anImg<T>with the specifieddimensions.create(Dimensions dim, T type) Deprecated.<S> ImgFactory<S> imgFactory(Supplier<S> typeSupplier) Creates the sameImgFactoryfor a different generic parameter if possible.abstract <S> ImgFactory<S> imgFactory(S type) Creates the sameImgFactoryfor a different generic parameter if possible.type()
-
Field Details
-
type
-
-
Constructor Details
-
ImgFactory
-
ImgFactory
Deprecated.
-
-
Method Details
-
type
-
create
-
create
Create anImg<T>with the specifieddimensions.- Returns:
- new image with the specified
dimensions.
-
create
Create anImg<T>with the specifieddimensions.Note: This is not a vararg function because the underlying
int[]based methods already copies theint[]dimensions into a disposablelong[]anyways. This would be an unnecessary copy forint...varargs.- Returns:
- new image with the specified
dimensions.
-
imgFactory
Creates the sameImgFactoryfor a different generic parameter if possible. If the type "S" does not suit the needs of theImgFactory(for example implementNativeTypein allNativeImgFactory, this method will throw anIncompatibleTypeException.- Type Parameters:
S- the new type- Parameters:
type- an instance of S- Returns:
ImgFactoryof type S- Throws:
IncompatibleTypeException- if type S is not compatible
-
imgFactory
Creates the sameImgFactoryfor a different generic parameter if possible. If the supplied type "S" does not suit the needs of theImgFactory(for example implementNativeTypein allNativeImgFactory, this method will throw anIncompatibleTypeException.- Type Parameters:
S- the new type- Parameters:
typeSupplier- a supplier of S- Returns:
ImgFactoryof type S- Throws:
IncompatibleTypeException- if type S is not compatible
-
create
Deprecated. -
create
Deprecated. -
create
Deprecated. -
create
Deprecated. -
create
Deprecated. -
create
Deprecated. -
cache
Deprecated.If the cached type instance was previously null, the giventypebecomes the cached instance. In this way, if the factory was created using one of the deprecated typeless constructor signatures, but then one of the deprecatedcreatemethods 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 typelesscreatemethods will work as desired.- Parameters:
type- The type to cache if needed.
-