# coding: utf-8

"""
    Posts

    Use these endpoints for interacting with Blog Posts, Blog Authors, and Blog Tags  # noqa: E501

    The version of the OpenAPI document: v3
    Generated by: https://openapi-generator.tech
"""


try:
    from inspect import getfullargspec
except ImportError:
    from inspect import getargspec as getfullargspec
import pprint
import re  # noqa: F401
import six

from hubspot.cms.blogs.blog_posts.configuration import Configuration


class Styles(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_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.
    """
    openapi_types = {
        "background_color": "RGBAColor",
        "flexbox_positioning": "str",
        "background_image": "BackgroundImage",
        "force_full_width_section": "bool",
        "breakpoint_styles": "dict[str, BreakpointStyles]",
        "vertical_alignment": "str",
        "max_width_section_centering": "int",
        "background_gradient": "Gradient",
    }

    attribute_map = {
        "background_color": "backgroundColor",
        "flexbox_positioning": "flexboxPositioning",
        "background_image": "backgroundImage",
        "force_full_width_section": "forceFullWidthSection",
        "breakpoint_styles": "breakpointStyles",
        "vertical_alignment": "verticalAlignment",
        "max_width_section_centering": "maxWidthSectionCentering",
        "background_gradient": "backgroundGradient",
    }

    def __init__(
        self,
        background_color=None,
        flexbox_positioning=None,
        background_image=None,
        force_full_width_section=None,
        breakpoint_styles=None,
        vertical_alignment=None,
        max_width_section_centering=None,
        background_gradient=None,
        local_vars_configuration=None,
    ):  # noqa: E501
        """Styles - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration.get_default_copy()
        self.local_vars_configuration = local_vars_configuration

        self._background_color = None
        self._flexbox_positioning = None
        self._background_image = None
        self._force_full_width_section = None
        self._breakpoint_styles = None
        self._vertical_alignment = None
        self._max_width_section_centering = None
        self._background_gradient = None
        self.discriminator = None

        self.background_color = background_color
        self.flexbox_positioning = flexbox_positioning
        self.background_image = background_image
        self.force_full_width_section = force_full_width_section
        if breakpoint_styles is not None:
            self.breakpoint_styles = breakpoint_styles
        self.vertical_alignment = vertical_alignment
        self.max_width_section_centering = max_width_section_centering
        self.background_gradient = background_gradient

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


        :return: The background_color of this Styles.  # noqa: E501
        :rtype: RGBAColor
        """
        return self._background_color

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


        :param background_color: The background_color of this Styles.  # noqa: E501
        :type background_color: RGBAColor
        """
        if self.local_vars_configuration.client_side_validation and background_color is None:  # noqa: E501
            raise ValueError("Invalid value for `background_color`, must not be `None`")  # noqa: E501

        self._background_color = background_color

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


        :return: The flexbox_positioning of this Styles.  # noqa: E501
        :rtype: str
        """
        return self._flexbox_positioning

    @flexbox_positioning.setter
    def flexbox_positioning(self, flexbox_positioning):
        """Sets the flexbox_positioning of this Styles.


        :param flexbox_positioning: The flexbox_positioning of this Styles.  # noqa: E501
        :type flexbox_positioning: str
        """
        if self.local_vars_configuration.client_side_validation and flexbox_positioning is None:  # noqa: E501
            raise ValueError("Invalid value for `flexbox_positioning`, must not be `None`")  # noqa: E501

        self._flexbox_positioning = flexbox_positioning

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


        :return: The background_image of this Styles.  # noqa: E501
        :rtype: BackgroundImage
        """
        return self._background_image

    @background_image.setter
    def background_image(self, background_image):
        """Sets the background_image of this Styles.


        :param background_image: The background_image of this Styles.  # noqa: E501
        :type background_image: BackgroundImage
        """
        if self.local_vars_configuration.client_side_validation and background_image is None:  # noqa: E501
            raise ValueError("Invalid value for `background_image`, must not be `None`")  # noqa: E501

        self._background_image = background_image

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


        :return: The force_full_width_section of this Styles.  # noqa: E501
        :rtype: bool
        """
        return self._force_full_width_section

    @force_full_width_section.setter
    def force_full_width_section(self, force_full_width_section):
        """Sets the force_full_width_section of this Styles.


        :param force_full_width_section: The force_full_width_section of this Styles.  # noqa: E501
        :type force_full_width_section: bool
        """
        if self.local_vars_configuration.client_side_validation and force_full_width_section is None:  # noqa: E501
            raise ValueError("Invalid value for `force_full_width_section`, must not be `None`")  # noqa: E501

        self._force_full_width_section = force_full_width_section

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


        :return: The breakpoint_styles of this Styles.  # noqa: E501
        :rtype: dict[str, BreakpointStyles]
        """
        return self._breakpoint_styles

    @breakpoint_styles.setter
    def breakpoint_styles(self, breakpoint_styles):
        """Sets the breakpoint_styles of this Styles.


        :param breakpoint_styles: The breakpoint_styles of this Styles.  # noqa: E501
        :type breakpoint_styles: dict[str, BreakpointStyles]
        """

        self._breakpoint_styles = breakpoint_styles

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


        :return: The vertical_alignment of this Styles.  # noqa: E501
        :rtype: str
        """
        return self._vertical_alignment

    @vertical_alignment.setter
    def vertical_alignment(self, vertical_alignment):
        """Sets the vertical_alignment of this Styles.


        :param vertical_alignment: The vertical_alignment of this Styles.  # noqa: E501
        :type vertical_alignment: str
        """
        if self.local_vars_configuration.client_side_validation and vertical_alignment is None:  # noqa: E501
            raise ValueError("Invalid value for `vertical_alignment`, must not be `None`")  # noqa: E501

        self._vertical_alignment = vertical_alignment

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


        :return: The max_width_section_centering of this Styles.  # noqa: E501
        :rtype: int
        """
        return self._max_width_section_centering

    @max_width_section_centering.setter
    def max_width_section_centering(self, max_width_section_centering):
        """Sets the max_width_section_centering of this Styles.


        :param max_width_section_centering: The max_width_section_centering of this Styles.  # noqa: E501
        :type max_width_section_centering: int
        """
        if self.local_vars_configuration.client_side_validation and max_width_section_centering is None:  # noqa: E501
            raise ValueError("Invalid value for `max_width_section_centering`, must not be `None`")  # noqa: E501

        self._max_width_section_centering = max_width_section_centering

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


        :return: The background_gradient of this Styles.  # noqa: E501
        :rtype: Gradient
        """
        return self._background_gradient

    @background_gradient.setter
    def background_gradient(self, background_gradient):
        """Sets the background_gradient of this Styles.


        :param background_gradient: The background_gradient of this Styles.  # noqa: E501
        :type background_gradient: Gradient
        """
        if self.local_vars_configuration.client_side_validation and background_gradient is None:  # noqa: E501
            raise ValueError("Invalid value for `background_gradient`, must not be `None`")  # noqa: E501

        self._background_gradient = background_gradient

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

        def convert(x):
            if hasattr(x, "to_dict"):
                args = getfullargspec(x.to_dict).args
                if len(args) == 1:
                    return x.to_dict()
                else:
                    return x.to_dict(serialize)
            else:
                return x

        for attr, _ in six.iteritems(self.openapi_types):
            value = getattr(self, attr)
            attr = self.attribute_map.get(attr, attr) if serialize else attr
            if isinstance(value, list):
                result[attr] = list(map(lambda x: convert(x), value))
            elif isinstance(value, dict):
                result[attr] = dict(map(lambda item: (item[0], convert(item[1])), value.items()))
            else:
                result[attr] = convert(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, Styles):
            return False

        return self.to_dict() == other.to_dict()

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

        return self.to_dict() != other.to_dict()
