# coding: utf-8

"""
    NetSuite REST API

    NetSuite REST Record API generated 2023-01-18 at 19:40:11 UTC for account 472052, user will@theapiguys.com with role Keap Integration.  # noqa: E501

    OpenAPI spec version: v1
    Contact: info@netsuite.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

import pprint
import re  # noqa: F401

import six

class NsError(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 = {
        'type': 'str',
        'title': 'str',
        'status': 'int',
        'oerror_details': 'list[NsErrorOerrorDetails]'
    }

    attribute_map = {
        'type': 'type',
        'title': 'title',
        'status': 'status',
        'oerror_details': 'o:errorDetails'
    }

    def __init__(self, type=None, title=None, status=None, oerror_details=None):  # noqa: E501
        """NsError - a model defined in Swagger"""  # noqa: E501
        self._type = None
        self._title = None
        self._status = None
        self._oerror_details = None
        self.discriminator = None
        if type is not None:
            self.type = type
        if title is not None:
            self.title = title
        if status is not None:
            self.status = status
        if oerror_details is not None:
            self.oerror_details = oerror_details

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

        A URI reference to the documentation about the problem type.  # noqa: E501

        :return: The type of this NsError.  # noqa: E501
        :rtype: str
        """
        return self._type

    @type.setter
    def type(self, type):
        """Sets the type of this NsError.

        A URI reference to the documentation about the problem type.  # noqa: E501

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

        self._type = type

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

        A human-readable description of the problem type.  # noqa: E501

        :return: The title of this NsError.  # noqa: E501
        :rtype: str
        """
        return self._title

    @title.setter
    def title(self, title):
        """Sets the title of this NsError.

        A human-readable description of the problem type.  # noqa: E501

        :param title: The title of this NsError.  # noqa: E501
        :type: str
        """

        self._title = title

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

        The HTTP status code generated by the server the request originates from.  # noqa: E501

        :return: The status of this NsError.  # noqa: E501
        :rtype: int
        """
        return self._status

    @status.setter
    def status(self, status):
        """Sets the status of this NsError.

        The HTTP status code generated by the server the request originates from.  # noqa: E501

        :param status: The status of this NsError.  # noqa: E501
        :type: int
        """

        self._status = status

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

        An array containing one or more problem types.  # noqa: E501

        :return: The oerror_details of this NsError.  # noqa: E501
        :rtype: list[NsErrorOerrorDetails]
        """
        return self._oerror_details

    @oerror_details.setter
    def oerror_details(self, oerror_details):
        """Sets the oerror_details of this NsError.

        An array containing one or more problem types.  # noqa: E501

        :param oerror_details: The oerror_details of this NsError.  # noqa: E501
        :type: list[NsErrorOerrorDetails]
        """

        self._oerror_details = oerror_details

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

        return self.__dict__ == other.__dict__

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