# 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 V1Timecard(object):
    """
    NOTE: This class is auto generated by the swagger code generator program.
    Do not edit the class manually.
    """
    def __init__(self, id=None, employee_id=None, deleted=None, clockin_time=None, clockout_time=None, clockin_location_id=None, clockout_location_id=None, created_at=None, updated_at=None, regular_seconds_worked=None, overtime_seconds_worked=None, doubletime_seconds_worked=None):
        """
        V1Timecard - 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 = {
            'id': 'str',
            'employee_id': 'str',
            'deleted': 'bool',
            'clockin_time': 'str',
            'clockout_time': 'str',
            'clockin_location_id': 'str',
            'clockout_location_id': 'str',
            'created_at': 'str',
            'updated_at': 'str',
            'regular_seconds_worked': 'float',
            'overtime_seconds_worked': 'float',
            'doubletime_seconds_worked': 'float'
        }

        self.attribute_map = {
            'id': 'id',
            'employee_id': 'employee_id',
            'deleted': 'deleted',
            'clockin_time': 'clockin_time',
            'clockout_time': 'clockout_time',
            'clockin_location_id': 'clockin_location_id',
            'clockout_location_id': 'clockout_location_id',
            'created_at': 'created_at',
            'updated_at': 'updated_at',
            'regular_seconds_worked': 'regular_seconds_worked',
            'overtime_seconds_worked': 'overtime_seconds_worked',
            'doubletime_seconds_worked': 'doubletime_seconds_worked'
        }

        self._id = id
        self._employee_id = employee_id
        self._deleted = deleted
        self._clockin_time = clockin_time
        self._clockout_time = clockout_time
        self._clockin_location_id = clockin_location_id
        self._clockout_location_id = clockout_location_id
        self._created_at = created_at
        self._updated_at = updated_at
        self._regular_seconds_worked = regular_seconds_worked
        self._overtime_seconds_worked = overtime_seconds_worked
        self._doubletime_seconds_worked = doubletime_seconds_worked

    @property
    def id(self):
        """
        Gets the id of this V1Timecard.
        The timecard's unique ID.

        :return: The id of this V1Timecard.
        :rtype: str
        """
        return self._id

    @id.setter
    def id(self, id):
        """
        Sets the id of this V1Timecard.
        The timecard's unique ID.

        :param id: The id of this V1Timecard.
        :type: str
        """

        self._id = id

    @property
    def employee_id(self):
        """
        Gets the employee_id of this V1Timecard.
        The ID of the employee the timecard is associated with.

        :return: The employee_id of this V1Timecard.
        :rtype: str
        """
        return self._employee_id

    @employee_id.setter
    def employee_id(self, employee_id):
        """
        Sets the employee_id of this V1Timecard.
        The ID of the employee the timecard is associated with.

        :param employee_id: The employee_id of this V1Timecard.
        :type: str
        """

        self._employee_id = employee_id

    @property
    def deleted(self):
        """
        Gets the deleted of this V1Timecard.
        If true, the timecard was deleted by the merchant, and it is no longer valid.

        :return: The deleted of this V1Timecard.
        :rtype: bool
        """
        return self._deleted

    @deleted.setter
    def deleted(self, deleted):
        """
        Sets the deleted of this V1Timecard.
        If true, the timecard was deleted by the merchant, and it is no longer valid.

        :param deleted: The deleted of this V1Timecard.
        :type: bool
        """

        self._deleted = deleted

    @property
    def clockin_time(self):
        """
        Gets the clockin_time of this V1Timecard.
        The clock-in time for the timecard, in ISO 8601 format.

        :return: The clockin_time of this V1Timecard.
        :rtype: str
        """
        return self._clockin_time

    @clockin_time.setter
    def clockin_time(self, clockin_time):
        """
        Sets the clockin_time of this V1Timecard.
        The clock-in time for the timecard, in ISO 8601 format.

        :param clockin_time: The clockin_time of this V1Timecard.
        :type: str
        """

        self._clockin_time = clockin_time

    @property
    def clockout_time(self):
        """
        Gets the clockout_time of this V1Timecard.
        The clock-out time for the timecard, in ISO 8601 format. Provide this value only if importing timecard information from another system.

        :return: The clockout_time of this V1Timecard.
        :rtype: str
        """
        return self._clockout_time

    @clockout_time.setter
    def clockout_time(self, clockout_time):
        """
        Sets the clockout_time of this V1Timecard.
        The clock-out time for the timecard, in ISO 8601 format. Provide this value only if importing timecard information from another system.

        :param clockout_time: The clockout_time of this V1Timecard.
        :type: str
        """

        self._clockout_time = clockout_time

    @property
    def clockin_location_id(self):
        """
        Gets the clockin_location_id of this V1Timecard.
        The ID of the location the employee clocked in from. We strongly reccomend providing a clockin_location_id. Square uses the clockin_location_id to determine a timecard’s timezone and overtime rules.

        :return: The clockin_location_id of this V1Timecard.
        :rtype: str
        """
        return self._clockin_location_id

    @clockin_location_id.setter
    def clockin_location_id(self, clockin_location_id):
        """
        Sets the clockin_location_id of this V1Timecard.
        The ID of the location the employee clocked in from. We strongly reccomend providing a clockin_location_id. Square uses the clockin_location_id to determine a timecard’s timezone and overtime rules.

        :param clockin_location_id: The clockin_location_id of this V1Timecard.
        :type: str
        """

        self._clockin_location_id = clockin_location_id

    @property
    def clockout_location_id(self):
        """
        Gets the clockout_location_id of this V1Timecard.
        The ID of the location the employee clocked out from. Provide this value only if importing timecard information from another system.

        :return: The clockout_location_id of this V1Timecard.
        :rtype: str
        """
        return self._clockout_location_id

    @clockout_location_id.setter
    def clockout_location_id(self, clockout_location_id):
        """
        Sets the clockout_location_id of this V1Timecard.
        The ID of the location the employee clocked out from. Provide this value only if importing timecard information from another system.

        :param clockout_location_id: The clockout_location_id of this V1Timecard.
        :type: str
        """

        self._clockout_location_id = clockout_location_id

    @property
    def created_at(self):
        """
        Gets the created_at of this V1Timecard.
        The time when the timecard was created, in ISO 8601 format.

        :return: The created_at of this V1Timecard.
        :rtype: str
        """
        return self._created_at

    @created_at.setter
    def created_at(self, created_at):
        """
        Sets the created_at of this V1Timecard.
        The time when the timecard was created, in ISO 8601 format.

        :param created_at: The created_at of this V1Timecard.
        :type: str
        """

        self._created_at = created_at

    @property
    def updated_at(self):
        """
        Gets the updated_at of this V1Timecard.
        The time when the timecard was most recently updated, in ISO 8601 format.

        :return: The updated_at of this V1Timecard.
        :rtype: str
        """
        return self._updated_at

    @updated_at.setter
    def updated_at(self, updated_at):
        """
        Sets the updated_at of this V1Timecard.
        The time when the timecard was most recently updated, in ISO 8601 format.

        :param updated_at: The updated_at of this V1Timecard.
        :type: str
        """

        self._updated_at = updated_at

    @property
    def regular_seconds_worked(self):
        """
        Gets the regular_seconds_worked of this V1Timecard.
        The total number of regular (non-overtime) seconds worked in the timecard.

        :return: The regular_seconds_worked of this V1Timecard.
        :rtype: float
        """
        return self._regular_seconds_worked

    @regular_seconds_worked.setter
    def regular_seconds_worked(self, regular_seconds_worked):
        """
        Sets the regular_seconds_worked of this V1Timecard.
        The total number of regular (non-overtime) seconds worked in the timecard.

        :param regular_seconds_worked: The regular_seconds_worked of this V1Timecard.
        :type: float
        """

        self._regular_seconds_worked = regular_seconds_worked

    @property
    def overtime_seconds_worked(self):
        """
        Gets the overtime_seconds_worked of this V1Timecard.
        The total number of overtime seconds worked in the timecard.

        :return: The overtime_seconds_worked of this V1Timecard.
        :rtype: float
        """
        return self._overtime_seconds_worked

    @overtime_seconds_worked.setter
    def overtime_seconds_worked(self, overtime_seconds_worked):
        """
        Sets the overtime_seconds_worked of this V1Timecard.
        The total number of overtime seconds worked in the timecard.

        :param overtime_seconds_worked: The overtime_seconds_worked of this V1Timecard.
        :type: float
        """

        self._overtime_seconds_worked = overtime_seconds_worked

    @property
    def doubletime_seconds_worked(self):
        """
        Gets the doubletime_seconds_worked of this V1Timecard.
        The total number of doubletime seconds worked in the timecard.

        :return: The doubletime_seconds_worked of this V1Timecard.
        :rtype: float
        """
        return self._doubletime_seconds_worked

    @doubletime_seconds_worked.setter
    def doubletime_seconds_worked(self, doubletime_seconds_worked):
        """
        Sets the doubletime_seconds_worked of this V1Timecard.
        The total number of doubletime seconds worked in the timecard.

        :param doubletime_seconds_worked: The doubletime_seconds_worked of this V1Timecard.
        :type: float
        """

        self._doubletime_seconds_worked = doubletime_seconds_worked

    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
