# coding: utf-8

"""
    DigitalRebar Provision Server

    # An RestFUL API-driven Provisioner and DHCP server  # noqa: E501

    OpenAPI spec version: 4.14.0
    Contact: support@rackn.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


import pprint
import re  # noqa: F401

import six

from drppy_client.configuration import Configuration


class AvailableAction(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 = {
        'command': 'str',
        'model': 'str',
        'optional_params': 'list[str]',
        'provider': 'str',
        'required_params': 'list[str]'
    }

    attribute_map = {
        'command': 'Command',
        'model': 'Model',
        'optional_params': 'OptionalParams',
        'provider': 'Provider',
        'required_params': 'RequiredParams'
    }

    def __init__(self, command=None, model=None, optional_params=None, provider=None, required_params=None, _configuration=None):  # noqa: E501
        """AvailableAction - a model defined in Swagger"""  # noqa: E501
        if _configuration is None:
            _configuration = Configuration()
        self._configuration = _configuration

        self._command = None
        self._model = None
        self._optional_params = None
        self._provider = None
        self._required_params = None
        self.discriminator = None

        if command is not None:
            self.command = command
        if model is not None:
            self.model = model
        if optional_params is not None:
            self.optional_params = optional_params
        if provider is not None:
            self.provider = provider
        if required_params is not None:
            self.required_params = required_params

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

        Command is the action name  # noqa: E501

        :return: The command of this AvailableAction.  # noqa: E501
        :rtype: str
        """
        return self._command

    @command.setter
    def command(self, command):
        """Sets the command of this AvailableAction.

        Command is the action name  # noqa: E501

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

        self._command = command

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

        Model is the type of object this action should apply.  # noqa: E501

        :return: The model of this AvailableAction.  # noqa: E501
        :rtype: str
        """
        return self._model

    @model.setter
    def model(self, model):
        """Sets the model of this AvailableAction.

        Model is the type of object this action should apply.  # noqa: E501

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

        self._model = model

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

        OptionalParams is a list of parameters that can alter the behavior of this action.  # noqa: E501

        :return: The optional_params of this AvailableAction.  # noqa: E501
        :rtype: list[str]
        """
        return self._optional_params

    @optional_params.setter
    def optional_params(self, optional_params):
        """Sets the optional_params of this AvailableAction.

        OptionalParams is a list of parameters that can alter the behavior of this action.  # noqa: E501

        :param optional_params: The optional_params of this AvailableAction.  # noqa: E501
        :type: list[str]
        """

        self._optional_params = optional_params

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

        Provider is the name of the provider that provides this action.  # noqa: E501

        :return: The provider of this AvailableAction.  # noqa: E501
        :rtype: str
        """
        return self._provider

    @provider.setter
    def provider(self, provider):
        """Sets the provider of this AvailableAction.

        Provider is the name of the provider that provides this action.  # noqa: E501

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

        self._provider = provider

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

        RequiredParams is a list of parameters that are required for this action.  # noqa: E501

        :return: The required_params of this AvailableAction.  # noqa: E501
        :rtype: list[str]
        """
        return self._required_params

    @required_params.setter
    def required_params(self, required_params):
        """Sets the required_params of this AvailableAction.

        RequiredParams is a list of parameters that are required for this action.  # noqa: E501

        :param required_params: The required_params of this AvailableAction.  # noqa: E501
        :type: list[str]
        """

        self._required_params = required_params

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

        return self.to_dict() == other.to_dict()

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

        return self.to_dict() != other.to_dict()
