cloudFPGA (cF) API  1.0
The documentation of the source code of cloudFPGA (cF)
images_body.py
Go to the documentation of this file.
1 # coding: utf-8
2 
3 """
4  cloudFPGA Resource Manager API
5 
6  No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
7 
8  OpenAPI spec version: 0.8
9 
10  Generated by: https://github.com/swagger-api/swagger-codegen.git
11 """
12 
13 import pprint
14 import re # noqa: F401
15 
16 import six
17 
18 class ImagesBody(object):
19  """NOTE: This class is auto generated by the swagger code generator program.
20 
21  Do not edit the class manually.
22  """
23  """
24  Attributes:
25  swagger_types (dict): The key is attribute name
26  and the value is attribute type.
27  attribute_map (dict): The key is attribute name
28  and the value is json key in definition.
29  """
30  swagger_types = {
31  'image_details': 'str',
32  'image_file': 'str',
33  'pr_verify_rpt': 'str'
34  }
35 
36  attribute_map = {
37  'image_details': 'image_details',
38  'image_file': 'image_file',
39  'pr_verify_rpt': 'pr_verify_rpt'
40  }
41 
42  def __init__(self, image_details=None, image_file=None, pr_verify_rpt=None): # noqa: E501
43  """ImagesBody - a model defined in Swagger""" # noqa: E501
44  self._image_details_image_details = None
45  self._image_file_image_file = None
46  self._pr_verify_rpt_pr_verify_rpt = None
47  self.discriminatordiscriminator = None
48  self.image_detailsimage_detailsimage_detailsimage_details = image_details
49  self.image_fileimage_fileimage_fileimage_file = image_file
50  if pr_verify_rpt is not None:
51  self.pr_verify_rptpr_verify_rptpr_verify_rptpr_verify_rpt = pr_verify_rpt
52 
53  @property
54  def image_details(self):
55  """Gets the image_details of this ImagesBody. # noqa: E501
56 
57  Must be a valid `image_detail` dict-representation. Example: ``` { \"breed\": \"SHELL\", \"fpga_board\": \"FMKU60\", \"shell_type\": \"Themisto\", \"comment\" : \"Some valuable information for humans (optional)\" } ``` # noqa: E501
58 
59  :return: The image_details of this ImagesBody. # noqa: E501
60  :rtype: str
61  """
62  return self._image_details_image_details
63 
64  @image_details.setter
65  def image_details(self, image_details):
66  """Sets the image_details of this ImagesBody.
67 
68  Must be a valid `image_detail` dict-representation. Example: ``` { \"breed\": \"SHELL\", \"fpga_board\": \"FMKU60\", \"shell_type\": \"Themisto\", \"comment\" : \"Some valuable information for humans (optional)\" } ``` # noqa: E501
69 
70  :param image_details: The image_details of this ImagesBody. # noqa: E501
71  :type: str
72  """
73  if image_details is None:
74  raise ValueError("Invalid value for `image_details`, must not be `None`") # noqa: E501
75 
76  self._image_details_image_details = image_details
77 
78  @property
79  def image_file(self):
80  """Gets the image_file of this ImagesBody. # noqa: E501
81 
82  FPGA bitfile to be programmed # noqa: E501
83 
84  :return: The image_file of this ImagesBody. # noqa: E501
85  :rtype: str
86  """
87  return self._image_file_image_file
88 
89  @image_file.setter
90  def image_file(self, image_file):
91  """Sets the image_file of this ImagesBody.
92 
93  FPGA bitfile to be programmed # noqa: E501
94 
95  :param image_file: The image_file of this ImagesBody. # noqa: E501
96  :type: str
97  """
98  if image_file is None:
99  raise ValueError("Invalid value for `image_file`, must not be `None`") # noqa: E501
100 
101  self._image_file_image_file = image_file
102 
103  @property
104  def pr_verify_rpt(self):
105  """Gets the pr_verify_rpt of this ImagesBody. # noqa: E501
106 
107  Result of the `pr_verify` command (currently optional) # noqa: E501
108 
109  :return: The pr_verify_rpt of this ImagesBody. # noqa: E501
110  :rtype: str
111  """
112  return self._pr_verify_rpt_pr_verify_rpt
113 
114  @pr_verify_rpt.setter
115  def pr_verify_rpt(self, pr_verify_rpt):
116  """Sets the pr_verify_rpt of this ImagesBody.
117 
118  Result of the `pr_verify` command (currently optional) # noqa: E501
119 
120  :param pr_verify_rpt: The pr_verify_rpt of this ImagesBody. # noqa: E501
121  :type: str
122  """
123 
124  self._pr_verify_rpt_pr_verify_rpt = pr_verify_rpt
125 
126  def to_dict(self):
127  """Returns the model properties as a dict"""
128  result = {}
129 
130  for attr, _ in six.iteritems(self.swagger_typesswagger_types):
131  value = getattr(self, attr)
132  if isinstance(value, list):
133  result[attr] = list(map(
134  lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
135  value
136  ))
137  elif hasattr(value, "to_dict"):
138  result[attr] = value.to_dict()
139  elif isinstance(value, dict):
140  result[attr] = dict(map(
141  lambda item: (item[0], item[1].to_dict())
142  if hasattr(item[1], "to_dict") else item,
143  value.items()
144  ))
145  else:
146  result[attr] = value
147  if issubclass(ImagesBody, dict):
148  for key, value in self.items():
149  result[key] = value
150 
151  return result
152 
153  def to_str(self):
154  """Returns the string representation of the model"""
155  return pprint.pformat(self.to_dictto_dict())
156 
157  def __repr__(self):
158  """For `print` and `pprint`"""
159  return self.to_strto_str()
160 
161  def __eq__(self, other):
162  """Returns true if both objects are equal"""
163  if not isinstance(other, ImagesBody):
164  return False
165 
166  return self.__dict____dict__ == other.__dict__
167 
168  def __ne__(self, other):
169  """Returns true if both objects are not equal"""
170  return not self == other
def __init__(self, image_details=None, image_file=None, pr_verify_rpt=None)
Definition: images_body.py:42