Package org.apache.iceberg.viewdepoc
Class CommentUpdate
- java.lang.Object
-
- org.apache.iceberg.viewdepoc.CommentUpdate
-
- All Implemented Interfaces:
org.apache.iceberg.PendingUpdate<org.apache.iceberg.Schema>,UpdateComment
public class CommentUpdate extends java.lang.Object implements UpdateComment
Update comments API implementation.
-
-
Constructor Summary
Constructors Constructor Description CommentUpdate(ViewOperations ops)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.iceberg.Schemaapply()Apply the pending changes to the original schema and returns the result.voidcommit()UpdateCommentupdateColumnDoc(java.lang.String name, java.lang.String doc)Update the comment of a column in the schema.
-
-
-
Constructor Detail
-
CommentUpdate
public CommentUpdate(ViewOperations ops)
-
-
Method Detail
-
updateColumnDoc
public UpdateComment updateColumnDoc(java.lang.String name, java.lang.String doc)
Description copied from interface:UpdateCommentUpdate the comment of a column in the schema.The name is used to find the column to update using
Schema.findField(String).- Specified by:
updateColumnDocin interfaceUpdateComment- Parameters:
name- name of the column whose comment is being updateddoc- replacement comment string for the column- Returns:
- this for method chaining
-
apply
public org.apache.iceberg.Schema apply()
Apply the pending changes to the original schema and returns the result.This does not result in a permanent update.
- Specified by:
applyin interfaceorg.apache.iceberg.PendingUpdate<org.apache.iceberg.Schema>- Returns:
- the result Schema when all pending updates are applied
-
commit
public void commit()
- Specified by:
commitin interfaceorg.apache.iceberg.PendingUpdate<org.apache.iceberg.Schema>
-
-