Class BarcodeTool
- java.lang.Object
-
- com.logicaldoc.barcode.automation.BarcodeTool
-
public class BarcodeTool extends Object
Class to extract barcode contents from inside the Automation- Since:
- 8.1
- Author:
- Marco Meschieri - LogicalDOC
-
-
Constructor Summary
Constructors Constructor Description BarcodeTool()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<String>
extract(com.logicaldoc.core.document.Document doc, String possibleFormats)
Extracts all the barcodes scanning the whole documentList<String>
extract(String filePath, String tenant, String possibleFormats)
Extracts all the barcodes scanning a given fileString
extractBarcode(com.logicaldoc.core.document.Document doc, BarcodeSpec zone)
Extracts the barcode in a given zone of a documentString
extractBarcode(com.logicaldoc.core.document.Document doc, String possibleFormats)
Extracts the first barcodeString
extractBarcode(String filePath, BarcodeSpec zone, String tenant)
Extracts the barcode in a given zone of a fileString
extractBarcode(String filePath, String tenant, String possibleFormats)
Extracts the first barcode scanning a given filevoid
processDocument(com.logicaldoc.core.document.Document doc, String username)
Processes a document trying to fill the fields using the barcodes the barcodes
-
-
-
Method Detail
-
extract
public List<String> extract(com.logicaldoc.core.document.Document doc, String possibleFormats)
Extracts all the barcodes scanning the whole document- Parameters:
doc
- the document to processpossibleFormats
- optional list of barcode formats- Returns:
- the found barcode values ordered by position
-
extract
public List<String> extract(String filePath, String tenant, String possibleFormats)
Extracts all the barcodes scanning a given file- Parameters:
filePath
- path of the file to processtenant
- name of the current tenantpossibleFormats
- optional list of barcode formats- Returns:
- the found barcode values ordered by position
-
extractBarcode
public String extractBarcode(com.logicaldoc.core.document.Document doc, String possibleFormats)
Extracts the first barcode- Parameters:
doc
- the document to processpossibleFormats
- optional list of barcode formats- Returns:
- the found barcode
-
extractBarcode
public String extractBarcode(String filePath, String tenant, String possibleFormats)
Extracts the first barcode scanning a given file- Parameters:
filePath
- path of the file to processtenant
- name of the current tenantpossibleFormats
- optional list of barcode formats- Returns:
- the found barcode
-
extractBarcode
public String extractBarcode(com.logicaldoc.core.document.Document doc, BarcodeSpec zone)
Extracts the barcode in a given zone of a document- Parameters:
doc
- the document to processzone
- the zone to consider- Returns:
- the found barcode
-
extractBarcode
public String extractBarcode(String filePath, BarcodeSpec zone, String tenant)
Extracts the barcode in a given zone of a file- Parameters:
filePath
- the path of the file to processzone
- the zone to considertenant
- name of the current tenant- Returns:
- the found barcode
-
processDocument
public void processDocument(com.logicaldoc.core.document.Document doc, String username)
Processes a document trying to fill the fields using the barcodes the barcodes- Parameters:
doc
- the document to processusername
- the user in whose name the method is run
-
-