com.groupdocs.assembly

Class BarcodeSettings

  • java.lang.Object
    • com.groupdocs.assembly.BarcodeSettings


  • public class BarcodeSettings
    extends java.lang.Object
    Represents a set of settings controlling barcode generation while assembling a document.
    • Method Detail

      • getBaseXDimension

        public float getBaseXDimension()
        Gets a base x-dimension, that is, the smallest width of the unit of barcode bars and spaces. Measured in getGraphicsUnit() / setGraphicsUnit(int). When barcode scaling is applied through a template, an actual x-dimension is calculated upon the base x-dimension and a scaling factor.
        Returns:
        A base x-dimension, that is, the smallest width of the unit of barcode bars and spaces.
      • setBaseXDimension

        public void setBaseXDimension(float value)
        Sets a base x-dimension, that is, the smallest width of the unit of barcode bars and spaces. Measured in getGraphicsUnit() / setGraphicsUnit(int). When barcode scaling is applied through a template, an actual x-dimension is calculated upon the base x-dimension and a scaling factor.
        Parameters:
        value - A base x-dimension, that is, the smallest width of the unit of barcode bars and spaces.
      • getBaseYDimension

        public float getBaseYDimension()
        Gets a base y-dimension, that is, the smallest height of the unit of 2D barcode modules. Measured in getGraphicsUnit() / setGraphicsUnit(int).

        Barcodes of some types (such as data matrix) may ignore an y-dimension and use an x-dimension for both width and height units.

        When barcode scaling is applied through a template, an actual y-dimension is calculated upon the base y-dimension and a scaling factor.

        Returns:
        A base y-dimension, that is, the smallest height of the unit of 2D barcode modules.
      • setBaseYDimension

        public void setBaseYDimension(float value)
        Sets a base y-dimension, that is, the smallest height of the unit of 2D barcode modules. Measured in getGraphicsUnit() / setGraphicsUnit(int).

        Barcodes of some types (such as data matrix) may ignore an y-dimension and use an x-dimension for both width and height units.

        When barcode scaling is applied through a template, an actual y-dimension is calculated upon the base y-dimension and a scaling factor.

        Parameters:
        value - A base y-dimension, that is, the smallest height of the unit of 2D barcode modules.
      • getXResolution

        public float getXResolution()
        Gets the horizontal resolution of a barcode image being generated. Measured in dots per inch. The default value is 96.
        Returns:
        The horizontal resolution of a barcode image being generated.
      • getYResolution

        public float getYResolution()
        Gets the vertical resolution of a barcode image being generated. Measured in dots per inch. The default value is 96.
        Returns:
        The vertical resolution of a barcode image being generated.
      • getUseAutoCorrection

        public boolean getUseAutoCorrection()
        Gets a value indicating whether an invalid barcode value should be corrected automatically (if possible) to fit the barcode's specification or an exception should be thrown to indicate the error. The default value is true. The auto-correction is not possible for Databar barcodes.
        Returns:
        A value indicating whether an invalid barcode value should be corrected automatically (if possible) to fit the barcode's specification or an exception should be thrown to indicate the error.
      • setUseAutoCorrection

        public void setUseAutoCorrection(boolean value)
        Sets a value indicating whether an invalid barcode value should be corrected automatically (if possible) to fit the barcode's specification or an exception should be thrown to indicate the error. The default value is true. The auto-correction is not possible for Databar barcodes.
        Parameters:
        value - A value indicating whether an invalid barcode value should be corrected automatically (if possible) to fit the barcode's specification or an exception should be thrown to indicate the error.