public class ImageLoadersRegistry extends Object
Represents the image loaders registry.
Constructor and Description |
---|
ImageLoadersRegistry() |
Modifier and Type | Method and Description |
---|---|
static IImageLoader |
createFirstSupportedLoader(InputStream stream,
LoadOptions loadOptions)
Creates the first found loader suitable for the specified
stream and optionally the loadOptions . |
static IImageLoader |
createFirstSupportedLoader(InputStream stream,
LoadOptions loadOptions,
boolean releaseSyncStream)
Creates the first found loader suitable for the specified
stream and optionally the loadOptions . |
static IImageLoaderDescriptor |
getFirstSupportedDescriptor(InputStream stream,
LoadOptions loadOptions)
Gets the fist found supported descriptor suitable for the specified
stream and optionally the loadOptions . |
static IImageLoaderDescriptor |
getFirstSupportedDescriptor(InputStream stream,
LoadOptions loadOptions,
boolean releaseSyncStream)
Gets the fist found supported descriptor suitable for the specified
stream and optionally the loadOptions . |
static IImageLoaderDescriptor |
getFirstSupportedDescriptorByTypeName(String descriptorTypeName)
Gets the first supported descriptor by its type name.
|
static IImageLoaderDescriptor[] |
getRegisteredDescriptors()
Gets the registered descriptors.
|
static List<Long> |
getRegisteredFormats()
Gets the registered image loading formats.
|
static void |
registerLoader(IImageLoaderDescriptor loaderDescriptor)
Registers the loader.
|
static void |
unregisterLoader(IImageLoaderDescriptor loaderDescriptor)
Unregisters the loader.
|
public static List<Long> getRegisteredFormats()
Gets the registered image loading formats.
public static IImageLoaderDescriptor[] getRegisteredDescriptors()
Gets the registered descriptors.
public static IImageLoaderDescriptor getFirstSupportedDescriptorByTypeName(String descriptorTypeName)
Gets the first supported descriptor by its type name.
descriptorTypeName
- The descriptor type name.
public static IImageLoaderDescriptor getFirstSupportedDescriptor(InputStream stream, LoadOptions loadOptions)
Gets the fist found supported descriptor suitable for the specified stream
and optionally the loadOptions
.
stream
- The stream.loadOptions
- The load options.
stream
and loadOptions
or null if no such descriptor is found.public static IImageLoaderDescriptor getFirstSupportedDescriptor(InputStream stream, LoadOptions loadOptions, boolean releaseSyncStream)
Gets the fist found supported descriptor suitable for the specified stream
and optionally the loadOptions
.
stream
- The stream.loadOptions
- The load options.releaseSyncStream
- The release of sync stream options.
stream
and loadOptions
or null if no such descriptor is found.public static IImageLoader createFirstSupportedLoader(InputStream stream, LoadOptions loadOptions)
Creates the first found loader suitable for the specified stream
and optionally the loadOptions
.
stream
- The stream.loadOptions
- The load options.
stream
and loadOptions
or null if no such loader is found.public static IImageLoader createFirstSupportedLoader(InputStream stream, LoadOptions loadOptions, boolean releaseSyncStream)
Creates the first found loader suitable for the specified stream
and optionally the loadOptions
.
stream
- The stream.loadOptions
- The load options.releaseSyncStream
- The release of sync stream options.
stream
and loadOptions
or null if no such loader is found.public static void registerLoader(IImageLoaderDescriptor loaderDescriptor)
Registers the loader.
loaderDescriptor
- The loader descriptor to register.public static void unregisterLoader(IImageLoaderDescriptor loaderDescriptor)
Unregisters the loader.
loaderDescriptor
- The loader descriptor to unregister.