generation/coupon-parameters.js

const _MwWrapper = require("../_mwbridge/_mw-wrapper.js");
const  Unit = require("./unit");

/**
 * Coupon parameters. Used for UpcaGs1DatabarCoupon, UpcaGs1Code128Coupon.
 */
class CouponParameters extends _MwWrapper
{

    _space;

    constructor(mwObject)
    {
        super(mwObject);
        this._initializeWrapperMembers();
    }

    _initializeWrapperMembers()
    {
        this._space = new Unit(this.getJavaClass().getSupplementSpaceSync());
    }


    /**
     * Space between main the BarCode and supplement BarCode in Unit value.<br>
     * @exception IllegalArgumentException<br>
     * The Space parameter value is less than 0.
     */
    getSupplementSpace()
    {
        return this._space;
    }

    /**
     * Space between main the BarCode and supplement BarCode in Unit value.<br>
     * @exception IllegalArgumentException<br>
     * The Space parameter value is less than 0.
     */
    setSupplementSpace(value)
    {
        this.getJavaClass().setSupplementSpaceSync(value.getJavaClass());
        this._space = value;
    }

    /**
     * Returns a human-readable string representation of this CouponParameters.<br>
     * @return A string that represents this CouponParameters.
     */
    toString()
    {
        return this.getJavaClass().toStringSync();
    }
}

module.exports = CouponParameters;