# coding: utf-8

"""
    Street Manager API

    See API specification Resource Guide > Work API for more information on endpoints NOTE: Swagger Editor/UI does not display all description text for enumerations and child elements, check swagger.json for full description text  # noqa: E501

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

import pprint
import re  # noqa: F401

import six

class Section58Response(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 = {
        'section_58_reference_number': 'str',
        'usrn': 'float',
        'street_name': 'str',
        'town': 'str',
        'area_name': 'str',
        'section_58_coordinates': 'object',
        'contact_organisation': 'str',
        'contact_details': 'str',
        'start_date': 'datetime',
        'end_date': 'datetime',
        'location_types': 'list[LocationTypeResponse]',
        'location_types_string': 'list[str]',
        'additional_information': 'str',
        'highway_authority_swa_code': 'str',
        'status_change_date': 'datetime',
        'section_58_status': 'Section58StatusResponse',
        'section_58_status_string': 'str',
        'restriction_duration': 'Section58DurationResponse',
        'restriction_duration_string': 'str',
        'restriction_extent': 'Section58ExtentResponse',
        'restriction_extent_string': 'str',
        'cancellation_reason': 'str'
    }

    attribute_map = {
        'section_58_reference_number': 'section_58_reference_number',
        'usrn': 'usrn',
        'street_name': 'street_name',
        'town': 'town',
        'area_name': 'area_name',
        'section_58_coordinates': 'section_58_coordinates',
        'contact_organisation': 'contact_organisation',
        'contact_details': 'contact_details',
        'start_date': 'start_date',
        'end_date': 'end_date',
        'location_types': 'location_types',
        'location_types_string': 'location_types_string',
        'additional_information': 'additional_information',
        'highway_authority_swa_code': 'highway_authority_swa_code',
        'status_change_date': 'status_change_date',
        'section_58_status': 'section_58_status',
        'section_58_status_string': 'section_58_status_string',
        'restriction_duration': 'restriction_duration',
        'restriction_duration_string': 'restriction_duration_string',
        'restriction_extent': 'restriction_extent',
        'restriction_extent_string': 'restriction_extent_string',
        'cancellation_reason': 'cancellation_reason'
    }

    def __init__(self, section_58_reference_number=None, usrn=None, street_name=None, town=None, area_name=None, section_58_coordinates=None, contact_organisation=None, contact_details=None, start_date=None, end_date=None, location_types=None, location_types_string=None, additional_information=None, highway_authority_swa_code=None, status_change_date=None, section_58_status=None, section_58_status_string=None, restriction_duration=None, restriction_duration_string=None, restriction_extent=None, restriction_extent_string=None, cancellation_reason=None):  # noqa: E501
        """Section58Response - a model defined in Swagger"""  # noqa: E501
        self._section_58_reference_number = None
        self._usrn = None
        self._street_name = None
        self._town = None
        self._area_name = None
        self._section_58_coordinates = None
        self._contact_organisation = None
        self._contact_details = None
        self._start_date = None
        self._end_date = None
        self._location_types = None
        self._location_types_string = None
        self._additional_information = None
        self._highway_authority_swa_code = None
        self._status_change_date = None
        self._section_58_status = None
        self._section_58_status_string = None
        self._restriction_duration = None
        self._restriction_duration_string = None
        self._restriction_extent = None
        self._restriction_extent_string = None
        self._cancellation_reason = None
        self.discriminator = None
        self.section_58_reference_number = section_58_reference_number
        self.usrn = usrn
        self.street_name = street_name
        if town is not None:
            self.town = town
        if area_name is not None:
            self.area_name = area_name
        self.section_58_coordinates = section_58_coordinates
        if contact_organisation is not None:
            self.contact_organisation = contact_organisation
        if contact_details is not None:
            self.contact_details = contact_details
        self.start_date = start_date
        self.end_date = end_date
        self.location_types = location_types
        self.location_types_string = location_types_string
        if additional_information is not None:
            self.additional_information = additional_information
        self.highway_authority_swa_code = highway_authority_swa_code
        self.status_change_date = status_change_date
        self.section_58_status = section_58_status
        self.section_58_status_string = section_58_status_string
        self.restriction_duration = restriction_duration
        self.restriction_duration_string = restriction_duration_string
        self.restriction_extent = restriction_extent
        self.restriction_extent_string = restriction_extent_string
        if cancellation_reason is not None:
            self.cancellation_reason = cancellation_reason

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


        :return: The section_58_reference_number of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._section_58_reference_number

    @section_58_reference_number.setter
    def section_58_reference_number(self, section_58_reference_number):
        """Sets the section_58_reference_number of this Section58Response.


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

        self._section_58_reference_number = section_58_reference_number

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


        :return: The usrn of this Section58Response.  # noqa: E501
        :rtype: float
        """
        return self._usrn

    @usrn.setter
    def usrn(self, usrn):
        """Sets the usrn of this Section58Response.


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

        self._usrn = usrn

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


        :return: The street_name of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._street_name

    @street_name.setter
    def street_name(self, street_name):
        """Sets the street_name of this Section58Response.


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

        self._street_name = street_name

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


        :return: The town of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._town

    @town.setter
    def town(self, town):
        """Sets the town of this Section58Response.


        :param town: The town of this Section58Response.  # noqa: E501
        :type: str
        """

        self._town = town

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


        :return: The area_name of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._area_name

    @area_name.setter
    def area_name(self, area_name):
        """Sets the area_name of this Section58Response.


        :param area_name: The area_name of this Section58Response.  # noqa: E501
        :type: str
        """

        self._area_name = area_name

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


        :return: The section_58_coordinates of this Section58Response.  # noqa: E501
        :rtype: object
        """
        return self._section_58_coordinates

    @section_58_coordinates.setter
    def section_58_coordinates(self, section_58_coordinates):
        """Sets the section_58_coordinates of this Section58Response.


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

        self._section_58_coordinates = section_58_coordinates

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


        :return: The contact_organisation of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._contact_organisation

    @contact_organisation.setter
    def contact_organisation(self, contact_organisation):
        """Sets the contact_organisation of this Section58Response.


        :param contact_organisation: The contact_organisation of this Section58Response.  # noqa: E501
        :type: str
        """

        self._contact_organisation = contact_organisation

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


        :return: The contact_details of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._contact_details

    @contact_details.setter
    def contact_details(self, contact_details):
        """Sets the contact_details of this Section58Response.


        :param contact_details: The contact_details of this Section58Response.  # noqa: E501
        :type: str
        """

        self._contact_details = contact_details

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


        :return: The start_date of this Section58Response.  # noqa: E501
        :rtype: datetime
        """
        return self._start_date

    @start_date.setter
    def start_date(self, start_date):
        """Sets the start_date of this Section58Response.


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

        self._start_date = start_date

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


        :return: The end_date of this Section58Response.  # noqa: E501
        :rtype: datetime
        """
        return self._end_date

    @end_date.setter
    def end_date(self, end_date):
        """Sets the end_date of this Section58Response.


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

        self._end_date = end_date

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


        :return: The location_types of this Section58Response.  # noqa: E501
        :rtype: list[LocationTypeResponse]
        """
        return self._location_types

    @location_types.setter
    def location_types(self, location_types):
        """Sets the location_types of this Section58Response.


        :param location_types: The location_types of this Section58Response.  # noqa: E501
        :type: list[LocationTypeResponse]
        """
        if location_types is None:
            raise ValueError("Invalid value for `location_types`, must not be `None`")  # noqa: E501

        self._location_types = location_types

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


        :return: The location_types_string of this Section58Response.  # noqa: E501
        :rtype: list[str]
        """
        return self._location_types_string

    @location_types_string.setter
    def location_types_string(self, location_types_string):
        """Sets the location_types_string of this Section58Response.


        :param location_types_string: The location_types_string of this Section58Response.  # noqa: E501
        :type: list[str]
        """
        if location_types_string is None:
            raise ValueError("Invalid value for `location_types_string`, must not be `None`")  # noqa: E501

        self._location_types_string = location_types_string

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


        :return: The additional_information of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._additional_information

    @additional_information.setter
    def additional_information(self, additional_information):
        """Sets the additional_information of this Section58Response.


        :param additional_information: The additional_information of this Section58Response.  # noqa: E501
        :type: str
        """

        self._additional_information = additional_information

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


        :return: The highway_authority_swa_code of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._highway_authority_swa_code

    @highway_authority_swa_code.setter
    def highway_authority_swa_code(self, highway_authority_swa_code):
        """Sets the highway_authority_swa_code of this Section58Response.


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

        self._highway_authority_swa_code = highway_authority_swa_code

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


        :return: The status_change_date of this Section58Response.  # noqa: E501
        :rtype: datetime
        """
        return self._status_change_date

    @status_change_date.setter
    def status_change_date(self, status_change_date):
        """Sets the status_change_date of this Section58Response.


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

        self._status_change_date = status_change_date

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


        :return: The section_58_status of this Section58Response.  # noqa: E501
        :rtype: Section58StatusResponse
        """
        return self._section_58_status

    @section_58_status.setter
    def section_58_status(self, section_58_status):
        """Sets the section_58_status of this Section58Response.


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

        self._section_58_status = section_58_status

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


        :return: The section_58_status_string of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._section_58_status_string

    @section_58_status_string.setter
    def section_58_status_string(self, section_58_status_string):
        """Sets the section_58_status_string of this Section58Response.


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

        self._section_58_status_string = section_58_status_string

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


        :return: The restriction_duration of this Section58Response.  # noqa: E501
        :rtype: Section58DurationResponse
        """
        return self._restriction_duration

    @restriction_duration.setter
    def restriction_duration(self, restriction_duration):
        """Sets the restriction_duration of this Section58Response.


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

        self._restriction_duration = restriction_duration

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


        :return: The restriction_duration_string of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._restriction_duration_string

    @restriction_duration_string.setter
    def restriction_duration_string(self, restriction_duration_string):
        """Sets the restriction_duration_string of this Section58Response.


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

        self._restriction_duration_string = restriction_duration_string

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


        :return: The restriction_extent of this Section58Response.  # noqa: E501
        :rtype: Section58ExtentResponse
        """
        return self._restriction_extent

    @restriction_extent.setter
    def restriction_extent(self, restriction_extent):
        """Sets the restriction_extent of this Section58Response.


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

        self._restriction_extent = restriction_extent

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


        :return: The restriction_extent_string of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._restriction_extent_string

    @restriction_extent_string.setter
    def restriction_extent_string(self, restriction_extent_string):
        """Sets the restriction_extent_string of this Section58Response.


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

        self._restriction_extent_string = restriction_extent_string

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


        :return: The cancellation_reason of this Section58Response.  # noqa: E501
        :rtype: str
        """
        return self._cancellation_reason

    @cancellation_reason.setter
    def cancellation_reason(self, cancellation_reason):
        """Sets the cancellation_reason of this Section58Response.


        :param cancellation_reason: The cancellation_reason of this Section58Response.  # noqa: E501
        :type: str
        """

        self._cancellation_reason = cancellation_reason

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

        return self.__dict__ == other.__dict__

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