Package com.logicaldoc.split.automation
Class SplitTool
- java.lang.Object
 - 
- com.logicaldoc.split.automation.SplitTool
 
 
- 
public class SplitTool extends Object
Allows the splitting of a PDF in segments using different policies from inside the Automation- Since:
 - 8.4
 - Author:
 - Marco Meschieri - LogicalDOC
 
 
- 
- 
Constructor Summary
Constructors Constructor Description SplitTool() 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<com.logicaldoc.core.document.Document>splitAllPages(long docId, String user)Splits a PDF, every page in a separated fileList<com.logicaldoc.core.document.Document>splitSelection(long docId, String expression, String user)Splits a PDF, into a selection of pagesList<com.logicaldoc.core.document.Document>splitUsingBarcode(long docId, String expression, int separator, String user)Splits a PDF using a barcode as separatorList<com.logicaldoc.core.document.Document>splitUsingBlankPage(long docId, int separator, String user)Splits a PDF using a blank page as separatorList<com.logicaldoc.core.document.Document>splitUsingText(long docId, String expression, int separator, String user)Splits a PDF using a text as separator 
 - 
 
- 
- 
Method Detail
- 
splitAllPages
public List<com.logicaldoc.core.document.Document> splitAllPages(long docId, String user) throws Exception
Splits a PDF, every page in a separated file- Parameters:
 docId- identifier of the documentuser- the current user- Returns:
 - list of segments
 - Throws:
 Exception- error during the splitting
 
- 
splitSelection
public List<com.logicaldoc.core.document.Document> splitSelection(long docId, String expression, String user) throws Exception
Splits a PDF, into a selection of pages- Parameters:
 docId- identifier of the documentexpression- the selection of pages (e.g.: 1,2,4-6,9)user- the current user- Returns:
 - list of segments
 - Throws:
 Exception- error during the splitting
 
- 
splitUsingBarcode
public List<com.logicaldoc.core.document.Document> splitUsingBarcode(long docId, String expression, int separator, String user) throws Exception
Splits a PDF using a barcode as separator- Parameters:
 docId- identifier of the documentexpression- regular expression that must be matched by the barcode's value, seePatternseparator- how to handle the separator: 0 = skip, 1 = append to current segment, 2 = prepend to next segmentuser- the current user- Returns:
 - list of segments
 - Throws:
 Exception- error during the splitting
 
- 
splitUsingText
public List<com.logicaldoc.core.document.Document> splitUsingText(long docId, String expression, int separator, String user) throws Exception
Splits a PDF using a text as separator- Parameters:
 docId- identifier of the documentexpression- regular expression that must be matched by the text, seePatternseparator- how to handle the separator: 0 = skip, 1 = append to current segment, 2 = prepend to next segmentuser- the current user- Returns:
 - list of segments
 - Throws:
 Exception- error during the splitting
 
- 
splitUsingBlankPage
public List<com.logicaldoc.core.document.Document> splitUsingBlankPage(long docId, int separator, String user) throws Exception
Splits a PDF using a blank page as separator- Parameters:
 docId- identifier of the documentseparator- how to handle the separator: 0 = skip, 1 = append to current segment, 2 = prepend to next segmentuser- the current user- Returns:
 - list of segments
 - Throws:
 Exception- error during the splitting
 
 - 
 
 -