# coding: utf-8

"""
Copyright 2017 Square, Inc.

    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

        http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.
"""


from pprint import pformat
from six import iteritems
import re


class ShiftFilter(object):
    """
    NOTE: This class is auto generated by the swagger code generator program.
    Do not edit the class manually.
    """
    def __init__(self, location_id=None, employee_id=None, status=None, start=None, end=None, workday=None):
        """
        ShiftFilter - a model defined in Swagger

        :param dict swaggerTypes: The key is attribute name
                                  and the value is attribute type.
        :param dict attributeMap: The key is attribute name
                                  and the value is json key in definition.
        """
        self.swagger_types = {
            'location_id': 'list[str]',
            'employee_id': 'list[str]',
            'status': 'str',
            'start': 'TimeRange',
            'end': 'TimeRange',
            'workday': 'ShiftWorkday'
        }

        self.attribute_map = {
            'location_id': 'location_id',
            'employee_id': 'employee_id',
            'status': 'status',
            'start': 'start',
            'end': 'end',
            'workday': 'workday'
        }

        self._location_id = location_id
        self._employee_id = employee_id
        self._status = status
        self._start = start
        self._end = end
        self._workday = workday

    @property
    def location_id(self):
        """
        Gets the location_id of this ShiftFilter.
        Fetch shifts for the specified location.

        :return: The location_id of this ShiftFilter.
        :rtype: list[str]
        """
        return self._location_id

    @location_id.setter
    def location_id(self, location_id):
        """
        Sets the location_id of this ShiftFilter.
        Fetch shifts for the specified location.

        :param location_id: The location_id of this ShiftFilter.
        :type: list[str]
        """

        self._location_id = location_id

    @property
    def employee_id(self):
        """
        Gets the employee_id of this ShiftFilter.
        Fetch shifts for the specified employee.

        :return: The employee_id of this ShiftFilter.
        :rtype: list[str]
        """
        return self._employee_id

    @employee_id.setter
    def employee_id(self, employee_id):
        """
        Sets the employee_id of this ShiftFilter.
        Fetch shifts for the specified employee.

        :param employee_id: The employee_id of this ShiftFilter.
        :type: list[str]
        """

        self._employee_id = employee_id

    @property
    def status(self):
        """
        Gets the status of this ShiftFilter.
        Fetch a `Shift` instance by `Shift.status`. See [ShiftFilterStatus](#type-shiftfilterstatus) for possible values

        :return: The status of this ShiftFilter.
        :rtype: str
        """
        return self._status

    @status.setter
    def status(self, status):
        """
        Sets the status of this ShiftFilter.
        Fetch a `Shift` instance by `Shift.status`. See [ShiftFilterStatus](#type-shiftfilterstatus) for possible values

        :param status: The status of this ShiftFilter.
        :type: str
        """

        self._status = status

    @property
    def start(self):
        """
        Gets the start of this ShiftFilter.
        Fetch `Shift`s that start in the time range - Inclusive.

        :return: The start of this ShiftFilter.
        :rtype: TimeRange
        """
        return self._start

    @start.setter
    def start(self, start):
        """
        Sets the start of this ShiftFilter.
        Fetch `Shift`s that start in the time range - Inclusive.

        :param start: The start of this ShiftFilter.
        :type: TimeRange
        """

        self._start = start

    @property
    def end(self):
        """
        Gets the end of this ShiftFilter.
        Fetch the `Shift`s that end in the time range - Inclusive.

        :return: The end of this ShiftFilter.
        :rtype: TimeRange
        """
        return self._end

    @end.setter
    def end(self, end):
        """
        Sets the end of this ShiftFilter.
        Fetch the `Shift`s that end in the time range - Inclusive.

        :param end: The end of this ShiftFilter.
        :type: TimeRange
        """

        self._end = end

    @property
    def workday(self):
        """
        Gets the workday of this ShiftFilter.
        Fetch the `Shift`s based on workday date range.

        :return: The workday of this ShiftFilter.
        :rtype: ShiftWorkday
        """
        return self._workday

    @workday.setter
    def workday(self, workday):
        """
        Sets the workday of this ShiftFilter.
        Fetch the `Shift`s based on workday date range.

        :param workday: The workday of this ShiftFilter.
        :type: ShiftWorkday
        """

        self._workday = workday

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

        for attr, _ in 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

        return result

    def to_str(self):
        """
        Returns the string representation of the model
        """
        return 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
        """
        return self.__dict__ == other.__dict__

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