gravitino.api.model_version_change.ModelVersionChange¶
- class gravitino.api.model_version_change.ModelVersionChange¶
Bases:
ABC
A model version change is a change to a model version. It can be used to update the comment of a model version, set a property and value pair for a model version, or remove a property from a model.
- __init__()¶
Methods
__init__
()remove_property
(key)Creates a new model version change to remove a property from the model version. Args: key: The key of the property. Returns: The model version change.
set_property
(key, value)Creates a new model version change to set a property and value pair for the model version. Args: key: The key of the property. value: The value of the property. Returns: The model version change.
update_comment
(comment)Creates a new model version change to update the comment of the model version. Args: comment: The new comment of the model version. Returns: The model version change.
update_uri
(uri)Creates a new model version change to update the uri of the model version. Args: uri: The new uri of the model version. Returns: The model version change.
- class RemoveProperty(key: str)¶
Bases:
object
A model version change to remove a property from the model version.
- property() str ¶
Retrieves the name of the property. Returns:
The name of the property.
- class SetProperty(key: str, value: str)¶
Bases:
object
A model version change to set a property and value pair for the model version.
- property() str ¶
Retrieves the name of the property. Returns:
The name of the property.
- value() str ¶
Retrieves the value of the property. Returns:
The value of the property.
- class UpdateComment(new_comment: str)¶
Bases:
object
A model version change to update the comment of the model version.
- new_comment() str ¶
Retrieves the new comment of the model version. Returns:
The new comment of the model version.
- class UpdateUri(new_uri: str)¶
Bases:
object
A model version change to update the URI of the model version.
- new_uri() str ¶
Retrieves the new URI of the model version. Returns:
The new URI of the model version.
- static remove_property(key: str)¶
Creates a new model version change to remove a property from the model version. Args:
key: The key of the property.
- Returns:
The model version change.
- static set_property(key, value)¶
Creates a new model version change to set a property and value pair for the model version. Args:
key: The key of the property. value: The value of the property.
- Returns:
The model version change.
- static update_comment(comment: str)¶
Creates a new model version change to update the comment of the model version. Args:
comment: The new comment of the model version.
- Returns:
The model version change.
- static update_uri(uri: str)¶
Creates a new model version change to update the uri of the model version. Args:
uri: The new uri of the model version.
- Returns:
The model version change.