github.com/filecoin-project/bacalhau@v0.3.23-0.20230228154132-45c989550ace/clients/python/bacalhau_apiclient/models/build_version_info.py (about)

     1  # coding: utf-8
     2  
     3  """
     4      Bacalhau API
     5  
     6      This page is the reference of the Bacalhau REST API. Project docs are available at https://docs.bacalhau.org/. Find more information about Bacalhau at https://github.com/filecoin-project/bacalhau.  # noqa: E501
     7  
     8      OpenAPI spec version: 0.3.22.post4
     9      Contact: team@bacalhau.org
    10      Generated by: https://github.com/swagger-api/swagger-codegen.git
    11  """
    12  
    13  
    14  import pprint
    15  import re  # noqa: F401
    16  
    17  import six
    18  
    19  from bacalhau_apiclient.configuration import Configuration
    20  
    21  
    22  class BuildVersionInfo(object):
    23      """NOTE: This class is auto generated by the swagger code generator program.
    24  
    25      Do not edit the class manually.
    26      """
    27  
    28      """
    29      Attributes:
    30        swagger_types (dict): The key is attribute name
    31                              and the value is attribute type.
    32        attribute_map (dict): The key is attribute name
    33                              and the value is json key in definition.
    34      """
    35      swagger_types = {
    36          'builddate': 'str',
    37          'gitcommit': 'str',
    38          'gitversion': 'str',
    39          'goarch': 'str',
    40          'goos': 'str',
    41          'major': 'str',
    42          'minor': 'str'
    43      }
    44  
    45      attribute_map = {
    46          'builddate': 'builddate',
    47          'gitcommit': 'gitcommit',
    48          'gitversion': 'gitversion',
    49          'goarch': 'goarch',
    50          'goos': 'goos',
    51          'major': 'major',
    52          'minor': 'minor'
    53      }
    54  
    55      def __init__(self, builddate=None, gitcommit=None, gitversion=None, goarch=None, goos=None, major=None, minor=None, _configuration=None):  # noqa: E501
    56          """BuildVersionInfo - a model defined in Swagger"""  # noqa: E501
    57          if _configuration is None:
    58              _configuration = Configuration()
    59          self._configuration = _configuration
    60  
    61          self._builddate = None
    62          self._gitcommit = None
    63          self._gitversion = None
    64          self._goarch = None
    65          self._goos = None
    66          self._major = None
    67          self._minor = None
    68          self.discriminator = None
    69  
    70          if builddate is not None:
    71              self.builddate = builddate
    72          if gitcommit is not None:
    73              self.gitcommit = gitcommit
    74          if gitversion is not None:
    75              self.gitversion = gitversion
    76          if goarch is not None:
    77              self.goarch = goarch
    78          if goos is not None:
    79              self.goos = goos
    80          if major is not None:
    81              self.major = major
    82          if minor is not None:
    83              self.minor = minor
    84  
    85      @property
    86      def builddate(self):
    87          """Gets the builddate of this BuildVersionInfo.  # noqa: E501
    88  
    89  
    90          :return: The builddate of this BuildVersionInfo.  # noqa: E501
    91          :rtype: str
    92          """
    93          return self._builddate
    94  
    95      @builddate.setter
    96      def builddate(self, builddate):
    97          """Sets the builddate of this BuildVersionInfo.
    98  
    99  
   100          :param builddate: The builddate of this BuildVersionInfo.  # noqa: E501
   101          :type: str
   102          """
   103  
   104          self._builddate = builddate
   105  
   106      @property
   107      def gitcommit(self):
   108          """Gets the gitcommit of this BuildVersionInfo.  # noqa: E501
   109  
   110  
   111          :return: The gitcommit of this BuildVersionInfo.  # noqa: E501
   112          :rtype: str
   113          """
   114          return self._gitcommit
   115  
   116      @gitcommit.setter
   117      def gitcommit(self, gitcommit):
   118          """Sets the gitcommit of this BuildVersionInfo.
   119  
   120  
   121          :param gitcommit: The gitcommit of this BuildVersionInfo.  # noqa: E501
   122          :type: str
   123          """
   124  
   125          self._gitcommit = gitcommit
   126  
   127      @property
   128      def gitversion(self):
   129          """Gets the gitversion of this BuildVersionInfo.  # noqa: E501
   130  
   131  
   132          :return: The gitversion of this BuildVersionInfo.  # noqa: E501
   133          :rtype: str
   134          """
   135          return self._gitversion
   136  
   137      @gitversion.setter
   138      def gitversion(self, gitversion):
   139          """Sets the gitversion of this BuildVersionInfo.
   140  
   141  
   142          :param gitversion: The gitversion of this BuildVersionInfo.  # noqa: E501
   143          :type: str
   144          """
   145  
   146          self._gitversion = gitversion
   147  
   148      @property
   149      def goarch(self):
   150          """Gets the goarch of this BuildVersionInfo.  # noqa: E501
   151  
   152  
   153          :return: The goarch of this BuildVersionInfo.  # noqa: E501
   154          :rtype: str
   155          """
   156          return self._goarch
   157  
   158      @goarch.setter
   159      def goarch(self, goarch):
   160          """Sets the goarch of this BuildVersionInfo.
   161  
   162  
   163          :param goarch: The goarch of this BuildVersionInfo.  # noqa: E501
   164          :type: str
   165          """
   166  
   167          self._goarch = goarch
   168  
   169      @property
   170      def goos(self):
   171          """Gets the goos of this BuildVersionInfo.  # noqa: E501
   172  
   173  
   174          :return: The goos of this BuildVersionInfo.  # noqa: E501
   175          :rtype: str
   176          """
   177          return self._goos
   178  
   179      @goos.setter
   180      def goos(self, goos):
   181          """Sets the goos of this BuildVersionInfo.
   182  
   183  
   184          :param goos: The goos of this BuildVersionInfo.  # noqa: E501
   185          :type: str
   186          """
   187  
   188          self._goos = goos
   189  
   190      @property
   191      def major(self):
   192          """Gets the major of this BuildVersionInfo.  # noqa: E501
   193  
   194  
   195          :return: The major of this BuildVersionInfo.  # noqa: E501
   196          :rtype: str
   197          """
   198          return self._major
   199  
   200      @major.setter
   201      def major(self, major):
   202          """Sets the major of this BuildVersionInfo.
   203  
   204  
   205          :param major: The major of this BuildVersionInfo.  # noqa: E501
   206          :type: str
   207          """
   208  
   209          self._major = major
   210  
   211      @property
   212      def minor(self):
   213          """Gets the minor of this BuildVersionInfo.  # noqa: E501
   214  
   215  
   216          :return: The minor of this BuildVersionInfo.  # noqa: E501
   217          :rtype: str
   218          """
   219          return self._minor
   220  
   221      @minor.setter
   222      def minor(self, minor):
   223          """Sets the minor of this BuildVersionInfo.
   224  
   225  
   226          :param minor: The minor of this BuildVersionInfo.  # noqa: E501
   227          :type: str
   228          """
   229  
   230          self._minor = minor
   231  
   232      def to_dict(self):
   233          """Returns the model properties as a dict"""
   234          result = {}
   235  
   236          for attr, _ in six.iteritems(self.swagger_types):
   237              value = getattr(self, attr)
   238              if isinstance(value, list):
   239                  result[attr] = list(map(
   240                      lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
   241                      value
   242                  ))
   243              elif hasattr(value, "to_dict"):
   244                  result[attr] = value.to_dict()
   245              elif isinstance(value, dict):
   246                  result[attr] = dict(map(
   247                      lambda item: (item[0], item[1].to_dict())
   248                      if hasattr(item[1], "to_dict") else item,
   249                      value.items()
   250                  ))
   251              else:
   252                  result[attr] = value
   253          if issubclass(BuildVersionInfo, dict):
   254              for key, value in self.items():
   255                  result[key] = value
   256  
   257          return result
   258  
   259      def to_str(self):
   260          """Returns the string representation of the model"""
   261          return pprint.pformat(self.to_dict())
   262  
   263      def __repr__(self):
   264          """For `print` and `pprint`"""
   265          return self.to_str()
   266  
   267      def __eq__(self, other):
   268          """Returns true if both objects are equal"""
   269          if not isinstance(other, BuildVersionInfo):
   270              return False
   271  
   272          return self.to_dict() == other.to_dict()
   273  
   274      def __ne__(self, other):
   275          """Returns true if both objects are not equal"""
   276          if not isinstance(other, BuildVersionInfo):
   277              return True
   278  
   279          return self.to_dict() != other.to_dict()