# coding: utf-8

"""
    Pdf4me

    No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)  # noqa: E501

    OpenAPI spec version: v1
    
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


import pprint
import re  # noqa: F401

import six


class AddBarcodeAction(object):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """

    """
    Attributes:
      swagger_types (dict): The key is attribute name
                            and the value is attribute type.
      attribute_map (dict): The key is attribute name
                            and the value is json key in definition.
    """
    swagger_types = {
        'barcode_type': 'str',
        'value': 'str',
        'height': 'int',
        'width': 'int',
        'align_x': 'str',
        'align_y': 'str',
        'margin_x': 'int',
        'margin_y': 'int',
        'page_sequence': 'str',
        'rotate': 'int',
        'barcode_color': 'BarcodeColor',
        'background_color': 'BarcodeColor',
        'action_id': 'str'
    }

    attribute_map = {
        'barcode_type': 'barcodeType',
        'value': 'value',
        'height': 'height',
        'width': 'width',
        'align_x': 'alignX',
        'align_y': 'alignY',
        'margin_x': 'marginX',
        'margin_y': 'marginY',
        'page_sequence': 'pageSequence',
        'rotate': 'rotate',
        'barcode_color': 'barcodeColor',
        'background_color': 'backgroundColor',
        'action_id': 'actionId'
    }

    def __init__(self, barcode_type=None, value=None, height=None, width=None, align_x=None, align_y=None, margin_x=None, margin_y=None, page_sequence=None, rotate=None, barcode_color=None, background_color=None, action_id=None):  # noqa: E501
        """AddBarcodeAction - a model defined in Swagger"""  # noqa: E501

        self._barcode_type = None
        self._value = None
        self._height = None
        self._width = None
        self._align_x = None
        self._align_y = None
        self._margin_x = None
        self._margin_y = None
        self._page_sequence = None
        self._rotate = None
        self._barcode_color = None
        self._background_color = None
        self._action_id = None
        self.discriminator = None

        if barcode_type is not None:
            self.barcode_type = barcode_type
        if value is not None:
            self.value = value
        if height is not None:
            self.height = height
        if width is not None:
            self.width = width
        if align_x is not None:
            self.align_x = align_x
        if align_y is not None:
            self.align_y = align_y
        if margin_x is not None:
            self.margin_x = margin_x
        if margin_y is not None:
            self.margin_y = margin_y
        if page_sequence is not None:
            self.page_sequence = page_sequence
        if rotate is not None:
            self.rotate = rotate
        if barcode_color is not None:
            self.barcode_color = barcode_color
        if background_color is not None:
            self.background_color = background_color
        if action_id is not None:
            self.action_id = action_id

    @property
    def barcode_type(self):
        """Gets the barcode_type of this AddBarcodeAction.  # noqa: E501


        :return: The barcode_type of this AddBarcodeAction.  # noqa: E501
        :rtype: str
        """
        return self._barcode_type

    @barcode_type.setter
    def barcode_type(self, barcode_type):
        """Sets the barcode_type of this AddBarcodeAction.


        :param barcode_type: The barcode_type of this AddBarcodeAction.  # noqa: E501
        :type: str
        """
        allowed_values = ["none", "code11", "code2Of5Standard", "code2Of5Interleaved", "code2Of5Iata", "code2Of5Matrix", "code2Of5DataLogic", "code2Of5Industry", "code39", "code39Extended", "ean8", "ean8With2Addon", "ean8With5Addon", "ean13", "ean13With2Addon", "ean13With5Addon", "eanUcc128", "upc12", "codabar2", "codabar18", "code128", "deutschePostLeitcode", "deutschePostIdentcode", "isbn13With5Addon", "ismn", "code93", "issn", "issnWith2Addon", "flattermarken", "gs1DataBar", "gs1DataBarLimited", "gs1DataBarExpanded", "telepenAlpha", "ucc128", "upcA", "upcAWith2Addon", "upcAWith5Addon", "upcE", "upcEWith2Addon", "upcEWith5Addon", "uspsPostnet5", "uspsPostnet6", "uspsPostnet9", "uspsPostnet10", "uspsPostnet11", "uspsPostnet12", "plessey", "msi", "sscc18", "fim", "logmars", "pharmacodeOneTrack", "pzn7", "pharmacodeTwoTrack", "cepNet", "pdf417", "pdf417Truncated", "maxicode", "qrCode", "code128SubsetA", "code128SubsetB", "code128SubsetC", "code93Extended", "australianPostCustom", "australianPostCustom2", "australianPostCustom3", "australianPostReplyPaid", "australianPostRouting", "australianPostRedirection", "isbn13", "rm4Scc", "dataMatrix", "ean14", "vin", "codablockF", "nve18", "japanesePostal", "koreanPostalAuthority", "gs1DataBarTruncated", "gs1DataBarStacked", "gs1DataBarStackedOmnidirectional", "gs1DataBarExpandedStacked", "planet12", "planet14", "microPdf417", "uspsIntelligentMail", "plesseyBidirectional", "telepen", "gs1_128", "itf14", "kix", "code32", "aztec", "italianPostal2Of5", "italianPostal3Of9", "dpd", "microQRCode", "hibcLic128", "hibcLic3OF9", "hibcPas128", "hibcPas3OF9", "hibcLicDataMatrix", "hibcPasDataMatrix", "hibcLicQRCode", "hibcPasQRCode", "hibcLicPDF417", "hibcPasPDF417", "hibcLicMPDF417", "hibcPasMPDF417", "hibcLicCODABLOCK_F", "hibcPasCODABLOCK_F", "qrcode2005", "pzn8", "dotCode", "hanXin", "uSPSIMPackage", "swedishPostalShipmentId", "mailmark_2D", "upuS10", "mailmark_4state", "hibcLicAztec", "hibcPasAztec", "ppn", "ntin", "swissQrCode"]  # noqa: E501
        if barcode_type not in allowed_values:
            raise ValueError(
                "Invalid value for `barcode_type` ({0}), must be one of {1}"  # noqa: E501
                .format(barcode_type, allowed_values)
            )

        self._barcode_type = barcode_type

    @property
    def value(self):
        """Gets the value of this AddBarcodeAction.  # noqa: E501


        :return: The value of this AddBarcodeAction.  # noqa: E501
        :rtype: str
        """
        return self._value

    @value.setter
    def value(self, value):
        """Sets the value of this AddBarcodeAction.


        :param value: The value of this AddBarcodeAction.  # noqa: E501
        :type: str
        """

        self._value = value

    @property
    def height(self):
        """Gets the height of this AddBarcodeAction.  # noqa: E501


        :return: The height of this AddBarcodeAction.  # noqa: E501
        :rtype: int
        """
        return self._height

    @height.setter
    def height(self, height):
        """Sets the height of this AddBarcodeAction.


        :param height: The height of this AddBarcodeAction.  # noqa: E501
        :type: int
        """

        self._height = height

    @property
    def width(self):
        """Gets the width of this AddBarcodeAction.  # noqa: E501


        :return: The width of this AddBarcodeAction.  # noqa: E501
        :rtype: int
        """
        return self._width

    @width.setter
    def width(self, width):
        """Sets the width of this AddBarcodeAction.


        :param width: The width of this AddBarcodeAction.  # noqa: E501
        :type: int
        """

        self._width = width

    @property
    def align_x(self):
        """Gets the align_x of this AddBarcodeAction.  # noqa: E501


        :return: The align_x of this AddBarcodeAction.  # noqa: E501
        :rtype: str
        """
        return self._align_x

    @align_x.setter
    def align_x(self, align_x):
        """Sets the align_x of this AddBarcodeAction.


        :param align_x: The align_x of this AddBarcodeAction.  # noqa: E501
        :type: str
        """
        allowed_values = ["left", "center", "right"]  # noqa: E501
        if align_x not in allowed_values:
            raise ValueError(
                "Invalid value for `align_x` ({0}), must be one of {1}"  # noqa: E501
                .format(align_x, allowed_values)
            )

        self._align_x = align_x

    @property
    def align_y(self):
        """Gets the align_y of this AddBarcodeAction.  # noqa: E501


        :return: The align_y of this AddBarcodeAction.  # noqa: E501
        :rtype: str
        """
        return self._align_y

    @align_y.setter
    def align_y(self, align_y):
        """Sets the align_y of this AddBarcodeAction.


        :param align_y: The align_y of this AddBarcodeAction.  # noqa: E501
        :type: str
        """
        allowed_values = ["top", "middle", "bottom"]  # noqa: E501
        if align_y not in allowed_values:
            raise ValueError(
                "Invalid value for `align_y` ({0}), must be one of {1}"  # noqa: E501
                .format(align_y, allowed_values)
            )

        self._align_y = align_y

    @property
    def margin_x(self):
        """Gets the margin_x of this AddBarcodeAction.  # noqa: E501


        :return: The margin_x of this AddBarcodeAction.  # noqa: E501
        :rtype: int
        """
        return self._margin_x

    @margin_x.setter
    def margin_x(self, margin_x):
        """Sets the margin_x of this AddBarcodeAction.


        :param margin_x: The margin_x of this AddBarcodeAction.  # noqa: E501
        :type: int
        """

        self._margin_x = margin_x

    @property
    def margin_y(self):
        """Gets the margin_y of this AddBarcodeAction.  # noqa: E501


        :return: The margin_y of this AddBarcodeAction.  # noqa: E501
        :rtype: int
        """
        return self._margin_y

    @margin_y.setter
    def margin_y(self, margin_y):
        """Sets the margin_y of this AddBarcodeAction.


        :param margin_y: The margin_y of this AddBarcodeAction.  # noqa: E501
        :type: int
        """

        self._margin_y = margin_y

    @property
    def page_sequence(self):
        """Gets the page_sequence of this AddBarcodeAction.  # noqa: E501


        :return: The page_sequence of this AddBarcodeAction.  # noqa: E501
        :rtype: str
        """
        return self._page_sequence

    @page_sequence.setter
    def page_sequence(self, page_sequence):
        """Sets the page_sequence of this AddBarcodeAction.


        :param page_sequence: The page_sequence of this AddBarcodeAction.  # noqa: E501
        :type: str
        """

        self._page_sequence = page_sequence

    @property
    def rotate(self):
        """Gets the rotate of this AddBarcodeAction.  # noqa: E501


        :return: The rotate of this AddBarcodeAction.  # noqa: E501
        :rtype: int
        """
        return self._rotate

    @rotate.setter
    def rotate(self, rotate):
        """Sets the rotate of this AddBarcodeAction.


        :param rotate: The rotate of this AddBarcodeAction.  # noqa: E501
        :type: int
        """

        self._rotate = rotate

    @property
    def barcode_color(self):
        """Gets the barcode_color of this AddBarcodeAction.  # noqa: E501


        :return: The barcode_color of this AddBarcodeAction.  # noqa: E501
        :rtype: BarcodeColor
        """
        return self._barcode_color

    @barcode_color.setter
    def barcode_color(self, barcode_color):
        """Sets the barcode_color of this AddBarcodeAction.


        :param barcode_color: The barcode_color of this AddBarcodeAction.  # noqa: E501
        :type: BarcodeColor
        """

        self._barcode_color = barcode_color

    @property
    def background_color(self):
        """Gets the background_color of this AddBarcodeAction.  # noqa: E501


        :return: The background_color of this AddBarcodeAction.  # noqa: E501
        :rtype: BarcodeColor
        """
        return self._background_color

    @background_color.setter
    def background_color(self, background_color):
        """Sets the background_color of this AddBarcodeAction.


        :param background_color: The background_color of this AddBarcodeAction.  # noqa: E501
        :type: BarcodeColor
        """

        self._background_color = background_color

    @property
    def action_id(self):
        """Gets the action_id of this AddBarcodeAction.  # noqa: E501


        :return: The action_id of this AddBarcodeAction.  # noqa: E501
        :rtype: str
        """
        return self._action_id

    @action_id.setter
    def action_id(self, action_id):
        """Sets the action_id of this AddBarcodeAction.


        :param action_id: The action_id of this AddBarcodeAction.  # noqa: E501
        :type: str
        """

        self._action_id = action_id

    def to_dict(self):
        """Returns the model properties as a dict"""
        result = {}

        for attr, _ in six.iteritems(self.swagger_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value
        if issubclass(AddBarcodeAction, dict):
            for key, value in self.items():
                result[key] = value

        return result

    def to_str(self):
        """Returns the string representation of the model"""
        return pprint.pformat(self.to_dict())

    def __repr__(self):
        """For `print` and `pprint`"""
        return self.to_str()

    def __eq__(self, other):
        """Returns true if both objects are equal"""
        if not isinstance(other, AddBarcodeAction):
            return False

        return self.__dict__ == other.__dict__

    def __ne__(self, other):
        """Returns true if both objects are not equal"""
        return not self == other
