diff --git a/Makefile b/Makefile index b5c670f..bfad331 100644 --- a/Makefile +++ b/Makefile @@ -27,3 +27,5 @@ python: make -C python licenses # Apply patch git apply templates/python/metadata_tags_metrics.patch + git apply templates/python/int_or_string.patch + diff --git a/python/docs/IntOrString.md b/python/docs/IntOrString.md index ef3be07..e4c51e9 100644 --- a/python/docs/IntOrString.md +++ b/python/docs/IntOrString.md @@ -3,9 +3,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**int_val** | **int** | | [optional] -**str_val** | **str** | | [optional] -**type** | [**Type**](Type.md) | | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/python/seldon_deploy_sdk/models/int_or_string.py b/python/seldon_deploy_sdk/models/int_or_string.py index e9c49bc..182fadf 100644 --- a/python/seldon_deploy_sdk/models/int_or_string.py +++ b/python/seldon_deploy_sdk/models/int_or_string.py @@ -31,95 +31,15 @@ class IntOrString(object): and the value is json key in definition. """ swagger_types = { - 'int_val': 'int', - 'str_val': 'str', - 'type': 'Type' } attribute_map = { - 'int_val': 'IntVal', - 'str_val': 'StrVal', - 'type': 'Type' } - def __init__(self, int_val=None, str_val=None, type=None): # noqa: E501 + def __init__(self): # noqa: E501 """IntOrString - a model defined in Swagger""" # noqa: E501 - - self._int_val = None - self._str_val = None - self._type = None self.discriminator = None - if int_val is not None: - self.int_val = int_val - if str_val is not None: - self.str_val = str_val - if type is not None: - self.type = type - - @property - def int_val(self): - """Gets the int_val of this IntOrString. # noqa: E501 - - - :return: The int_val of this IntOrString. # noqa: E501 - :rtype: int - """ - return self._int_val - - @int_val.setter - def int_val(self, int_val): - """Sets the int_val of this IntOrString. - - - :param int_val: The int_val of this IntOrString. # noqa: E501 - :type: int - """ - - self._int_val = int_val - - @property - def str_val(self): - """Gets the str_val of this IntOrString. # noqa: E501 - - - :return: The str_val of this IntOrString. # noqa: E501 - :rtype: str - """ - return self._str_val - - @str_val.setter - def str_val(self, str_val): - """Sets the str_val of this IntOrString. - - - :param str_val: The str_val of this IntOrString. # noqa: E501 - :type: str - """ - - self._str_val = str_val - - @property - def type(self): - """Gets the type of this IntOrString. # noqa: E501 - - - :return: The type of this IntOrString. # noqa: E501 - :rtype: Type - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this IntOrString. - - - :param type: The type of this IntOrString. # noqa: E501 - :type: Type - """ - - self._type = type - def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/templates/python/int_or_string.patch b/templates/python/int_or_string.patch new file mode 100644 index 0000000..22fa0a6 --- /dev/null +++ b/templates/python/int_or_string.patch @@ -0,0 +1,115 @@ +diff --git a/python/docs/IntOrString.md b/python/docs/IntOrString.md +index ef3be07..e4c51e9 100644 +--- a/python/docs/IntOrString.md ++++ b/python/docs/IntOrString.md +@@ -3,9 +3,6 @@ + ## Properties + Name | Type | Description | Notes + ------------ | ------------- | ------------- | ------------- +-**int_val** | **int** | | [optional] +-**str_val** | **str** | | [optional] +-**type** | [**Type**](Type.md) | | [optional] + + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + +diff --git a/python/seldon_deploy_sdk/models/int_or_string.py b/python/seldon_deploy_sdk/models/int_or_string.py +index e9c49bc..182fadf 100644 +--- a/python/seldon_deploy_sdk/models/int_or_string.py ++++ b/python/seldon_deploy_sdk/models/int_or_string.py +@@ -31,95 +31,15 @@ class IntOrString(object): + and the value is json key in definition. + """ + swagger_types = { +- 'int_val': 'int', +- 'str_val': 'str', +- 'type': 'Type' + } + + attribute_map = { +- 'int_val': 'IntVal', +- 'str_val': 'StrVal', +- 'type': 'Type' + } + +- def __init__(self, int_val=None, str_val=None, type=None): # noqa: E501 ++ def __init__(self): # noqa: E501 + """IntOrString - a model defined in Swagger""" # noqa: E501 +- +- self._int_val = None +- self._str_val = None +- self._type = None + self.discriminator = None + +- if int_val is not None: +- self.int_val = int_val +- if str_val is not None: +- self.str_val = str_val +- if type is not None: +- self.type = type +- +- @property +- def int_val(self): +- """Gets the int_val of this IntOrString. # noqa: E501 +- +- +- :return: The int_val of this IntOrString. # noqa: E501 +- :rtype: int +- """ +- return self._int_val +- +- @int_val.setter +- def int_val(self, int_val): +- """Sets the int_val of this IntOrString. +- +- +- :param int_val: The int_val of this IntOrString. # noqa: E501 +- :type: int +- """ +- +- self._int_val = int_val +- +- @property +- def str_val(self): +- """Gets the str_val of this IntOrString. # noqa: E501 +- +- +- :return: The str_val of this IntOrString. # noqa: E501 +- :rtype: str +- """ +- return self._str_val +- +- @str_val.setter +- def str_val(self, str_val): +- """Sets the str_val of this IntOrString. +- +- +- :param str_val: The str_val of this IntOrString. # noqa: E501 +- :type: str +- """ +- +- self._str_val = str_val +- +- @property +- def type(self): +- """Gets the type of this IntOrString. # noqa: E501 +- +- +- :return: The type of this IntOrString. # noqa: E501 +- :rtype: Type +- """ +- return self._type +- +- @type.setter +- def type(self, type): +- """Sets the type of this IntOrString. +- +- +- :param type: The type of this IntOrString. # noqa: E501 +- :type: Type +- """ +- +- self._type = type +- + def to_dict(self): + """Returns the model properties as a dict""" + result = {}