ModeleBarCode
abstract class ModeleBarCode (View source)
Parent class for barcode document generators (image)
Properties
| string | $error | ||
| "development"|"experimental"|"dolibarr" | $version | Dolibarr version of loaded document |
Methods
bool
isEnabled()
Return if a model can be used or not
string
info($langs)
Return description
int
writeBarCode(string $code, string $encoding, string $readable = 'Y', int $scale = 1, $nooutputiferror = 0)
Save an image file on disk (with no output)
int
buildBarCode(string $code, string $encoding, string $readable = 'Y', int $scale = 1, $nooutputiferror = 0)
Return an image file on the fly (no need to write on disk) with the HTTP content-type of image.
int
encodingIsSupported($encoding)
Return true if encoding is supported
Details
bool
isEnabled()
Return if a model can be used or not
abstract string
info($langs)
Return description
@param Translate $langs Lang object to use for output
int
writeBarCode(string $code, string $encoding, string $readable = 'Y', int $scale = 1, $nooutputiferror = 0)
Save an image file on disk (with no output)
int
buildBarCode(string $code, string $encoding, string $readable = 'Y', int $scale = 1, $nooutputiferror = 0)
Return an image file on the fly (no need to write on disk) with the HTTP content-type of image.
abstract int
encodingIsSupported($encoding)
Return true if encoding is supported
@param string $encoding Encoding norm