com.groupdocs.merger.domain.options

Class TextSplitOptions

    • Constructor Detail

      • TextSplitOptions

        public TextSplitOptions(CreateSplitStream createSplitStream,
                        int[] lineNumbers)

        Initializes a new instance of the TextSplitOptions class.

        Parameters:
        createSplitStream - The method that instantiates stream used to write output split data.
        lineNumbers - Line numbers for text splitting.
      • TextSplitOptions

        public TextSplitOptions(CreateSplitStream createSplitStream,
                        int mode,
                        int[] lineNumbers)

        Initializes a new instance of the TextSplitOptions class.

        Parameters:
        createSplitStream - The method that instantiates stream used to write output split data.
        mode - Mode for text splitting.
        lineNumbers - Line numbers for text splitting.
      • TextSplitOptions

        public TextSplitOptions(CreateSplitStream createSplitStream,
                        ReleaseSplitStream releaseSplitStream,
                        int[] lineNumbers)

        Initializes a new instance of the TextSplitOptions class.

        Parameters:
        createSplitStream - The method that instantiates stream used to write output split data.
        releaseSplitStream - The method that releases stream created by createPageStream method.
        lineNumbers - Line numbers for text splitting.
      • TextSplitOptions

        public TextSplitOptions(CreateSplitStream createSplitStream,
                        ReleaseSplitStream releaseSplitStream,
                        int mode,
                        int[] lineNumbers)

        Initializes a new instance of the TextSplitOptions class.

        Parameters:
        createSplitStream - The method that instantiates stream used to write output split data.
        releaseSplitStream - The method that releases stream created by createPageStream method.
        mode - Mode for text splitting.
        lineNumbers - Line numbers for text splitting.
      • TextSplitOptions

        public TextSplitOptions(int[] lineNumbers)

        Initializes a new instance of the TextSplitOptions class.

        Parameters:
        lineNumbers - Line numbers for text splitting.
      • TextSplitOptions

        public TextSplitOptions(int mode,
                        int[] lineNumbers)

        Initializes a new instance of the TextSplitOptions class.

        Parameters:
        mode - Mode for text splitting.
        lineNumbers - Line numbers for text splitting.
      • TextSplitOptions

        public TextSplitOptions(String filePathFormat,
                        int[] lineNumbers)

        Initializes a new instance of the TextSplitOptions class.

        Parameters:
        filePathFormat - The file path format e.g. 'c:/split{0}.doc' or 'c:/split{0}.{1}' with already defined extension.
        lineNumbers - Line numbers for text splitting.
      • TextSplitOptions

        public TextSplitOptions(String filePathFormat,
                        int mode,
                        int[] lineNumbers)

        Initializes a new instance of the TextSplitOptions class.

        Parameters:
        filePathFormat - The file path format e.g. 'c:/split{0}.doc' or 'c:/split{0}.{1}' with already defined extension.
        mode - Mode for text splitting.
        lineNumbers - Line numbers for text splitting.
    • Method Detail

      • getPathByIndex

        public final String getPathByIndex(int index,
                            String extension)

        Gets the full file path of splitted document by index with defined extension.

        Specified by:
        getPathByIndex in interface ISplitOptions
        Parameters:
        index - Index of splitted document.
        extension - Extension of file.
        Returns:
        The full file path.
      • validate

        public final void validate(FileType fileType)

        Validates the split options.

        Specified by:
        validate in interface ISplitOptions
        Parameters:
        fileType - The file type of FileType class.