com.groupdocs.editor.htmlcss.resources.images.vector

Class MetaImageBase

    • Constructor Detail

      • MetaImageBase

        public MetaImageBase(String name,
                             InputStream binaryContent,
                             boolean isWmf)

        Common constructor, which prepares a creating a WMF or EMF instance from byte stream

        Parameters:
        name - Mandatory name
        binaryContent - Content as byte stream. Should be valid.
        isWmf - true for WMF, false for EMF
      • MetaImageBase

        public MetaImageBase(String name,
                             String contentInBase64,
                             boolean isWmf)

        Common constructor, which prepares a creating a WMF or EMF instance from base64-encoded string

        Parameters:
        name - Mandatory name
        contentInBase64 - Content as base64 string. Should be not NULL or empty.
        isWmf - true for WMF, false for EMF
    • Method Detail

      • isValidEmf

        public static boolean isValidEmf(InputStream binaryContent)

        Determines whether specified byte stream contains a valid EMF image

        Parameters:
        binaryContent - Input byte stream. Should be valid.
        Returns:
        Returns 'true' if valid and 'false' if invalid
      • isValidEmf

        public static boolean isValidEmf(String contentInBase64)

        Determines whether specified string contains a valid EMF image, which is encoded with base64

        Parameters:
        contentInBase64 - String, which is assumed to contain a base64-encoded EMF image
        Returns:
        Returns 'true' if valid and 'false' if invalid
      • isValidWmf

        public static boolean isValidWmf(InputStream binaryContent)

        Determines whether specified byte stream contains a valid WMF image

        Parameters:
        binaryContent - Input byte stream. Should be valid.
        Returns:
        Returns 'true' if valid and 'false' if invalid
      • isValidWmf

        public static boolean isValidWmf(String contentInBase64)

        Determines whether specified string contains a valid WMF image, which is encoded with base64

        Parameters:
        contentInBase64 - String, which is assumed to contain a base64-encoded WMF image
        Returns:
        Returns 'true' if valid and 'false' if invalid
      • saveToSvg

        public abstract void saveToSvg(OutputStream outputSvgContent)
                                throws Exception

        In implementing type should save a current vector meta-image to the vector SVG format into specified byte stream

        Parameters:
        outputSvgContent - Byte stream, into which the SVG version of this vector meta-image will be stored. Should not be NULL and should support writing.
        Throws:
        Exception