Package org.apache.gravitino.model
Interface ModelChange
- All Known Implementing Classes:
ModelChange.RemoveProperty,ModelChange.RenameModel,ModelChange.SetProperty,ModelChange.UpdateComment
A model change is a change to a model. It can be used to rename a model, update the comment of a
model, set a property and value pair for a model, or remove a property from a model.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA ModelChange to remove a property from model.static final classA ModelChange to rename a model.static final classA ModelChange to set a property and value of a model.static final classA ModelChange to update the comment of a model. -
Method Summary
Static MethodsModifier and TypeMethodDescriptionstatic ModelChangeremoveProperty(String property) Create a ModelChange for removing a property from a model.static ModelChangeCreate a ModelChange for renaming a model.static ModelChangesetProperty(String property, String value) Create a ModelChange for setting a property and value of a model.static ModelChangeupdateComment(String newComment) Create a ModelChange for updating the comment of a model.
-
Method Details
-
rename
Create a ModelChange for renaming a model.- Parameters:
newName- The new model name.- Returns:
- A ModelChange for the rename.
-
setProperty
Create a ModelChange for setting a property and value of a model.- Parameters:
property- The name of the property to be set.value- The value to be set for the property.- Returns:
- A ModelChange for the property set.
-
removeProperty
Create a ModelChange for removing a property from a model.- Parameters:
property- The name of the property to be removed from the model.- Returns:
- A ModelChange for the property removal.
-
updateComment
Create a ModelChange for updating the comment of a model.- Parameters:
newComment- The new comment of the model.- Returns:
- A ModelChange for the comment update.
-