# coding: utf-8

"""
    AristaFlowREST/WorklistManager

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

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

import pprint
import re  # noqa: F401

import six

class AbsenceInformation(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 = {
        'from_date': 'datetime',
        'to_date': 'datetime',
        'absentee': 'QualifiedAgent',
        'substitution_rule': 'str'
    }

    attribute_map = {
        'from_date': 'fromDate',
        'to_date': 'toDate',
        'absentee': 'absentee',
        'substitution_rule': 'substitutionRule'
    }

    def __init__(self, from_date=None, to_date=None, absentee=None, substitution_rule=None):  # noqa: E501
        """AbsenceInformation - a model defined in Swagger"""  # noqa: E501
        self._from_date = None
        self._to_date = None
        self._absentee = None
        self._substitution_rule = None
        if not(hasattr(self, "discriminator")) or not(self.discriminator):
            self.discriminator = None
        if from_date is not None:
            self.from_date = from_date
        if to_date is not None:
            self.to_date = to_date
        self.absentee = absentee
        if substitution_rule is not None:
            self.substitution_rule = substitution_rule

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


        :return: The from_date of this AbsenceInformation.  # noqa: E501
        :rtype: datetime
        """
        return self._from_date

    @from_date.setter
    def from_date(self, from_date):
        """Sets the from_date of this AbsenceInformation.


        :param from_date: The from_date of this AbsenceInformation.  # noqa: E501
        :type: datetime
        """

        self._from_date = from_date

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


        :return: The to_date of this AbsenceInformation.  # noqa: E501
        :rtype: datetime
        """
        return self._to_date

    @to_date.setter
    def to_date(self, to_date):
        """Sets the to_date of this AbsenceInformation.


        :param to_date: The to_date of this AbsenceInformation.  # noqa: E501
        :type: datetime
        """

        self._to_date = to_date

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


        :return: The absentee of this AbsenceInformation.  # noqa: E501
        :rtype: QualifiedAgent
        """
        return self._absentee

    @absentee.setter
    def absentee(self, absentee):
        """Sets the absentee of this AbsenceInformation.


        :param absentee: The absentee of this AbsenceInformation.  # noqa: E501
        :type: QualifiedAgent
        """
        if absentee is None:
            raise ValueError("Invalid value for `absentee`, must not be `None`")  # noqa: E501

        self._absentee = absentee

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


        :return: The substitution_rule of this AbsenceInformation.  # noqa: E501
        :rtype: str
        """
        return self._substitution_rule

    @substitution_rule.setter
    def substitution_rule(self, substitution_rule):
        """Sets the substitution_rule of this AbsenceInformation.


        :param substitution_rule: The substitution_rule of this AbsenceInformation.  # noqa: E501
        :type: str
        """

        self._substitution_rule = substitution_rule

    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(AbsenceInformation, 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, AbsenceInformation):
            return False

        return self.__dict__ == other.__dict__

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