Packages

 

com.aspose.imaging.fileformats.psd.layers

Class LayerResourcesRegistry

  • java.lang.Object
    • com.aspose.imaging.fileformats.psd.layers.LayerResourcesRegistry


  • public final class LayerResourcesRegistry
    extends Object

    Represents the layer resources registry.

    • Method Detail

      • getRegisteredDescriptors

        public static ILayerResourceLoader[] getRegisteredDescriptors()

        Gets the registered descriptors.

        Value: The registered descriptors.
      • getFirstSupportedDescriptorByTypeName

        public static ILayerResourceLoader getFirstSupportedDescriptorByTypeName(String descriptorTypeName)

        Gets the first supported descriptor by its type name.

        Parameters:
        descriptorTypeName - The descriptor type name.

        The first opener descriptor will be actually the last registered.

        Returns:
        The first found opener descriptor or null if not such descriptor is found.
      • getFirstSupportedDescriptor

        public static ILayerResourceLoader getFirstSupportedDescriptor(InputStream stream,
                                                                       int psdVersion)

        Gets the first supported opener descriptor.

        Parameters:
        stream - The stream.
        psdVersion - The PSD version.

        The first loader will be actually the last registered.

        Returns:
        The layer resource loader descriptor or null if no loader descriptor supported for such stream.
      • loadResourceByFirstSupportedDescriptor

        public static LayerResource loadResourceByFirstSupportedDescriptor(InputStream stream,
                                                                           int psdVersion)

        Loads LayerResource using first found opener suitable for the specified stream.

        Parameters:
        stream - The stream.
        psdVersion - The PSD version.

        The first opener will be actually the last registered.

        Returns:
        The loaded LayerResource or null if no opener is found.
      • registerOpener

        public static void registerOpener(ILayerResourceLoader openerDescriptor)

        Registers the opener.

        Parameters:
        openerDescriptor - The opener descriptor to register.
      • unregisterOpener

        public static void unregisterOpener(ILayerResourceLoader openerDescriptor)

        Unregisters the opener.

        Parameters:
        openerDescriptor - The opener descriptor to unregister.