Package org.apache.iceberg.viewdepoc
Interface Views
-
- All Known Implementing Classes:
BaseMetastoreViews,HadoopViews,NessieExtCatalog,NessieViewCatalog
public interface ViewsGeneric interface for creating and loading a view implementation.The 'viewIdentifier' field should be interpreted by the underlying implementation (e.g. catalog.database.view_name)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidcreate(java.lang.String viewIdentifier, ViewDefinition viewDefinition, java.util.Map<java.lang.String,java.lang.String> properties)Create a view without replacing any existing view.voiddrop(java.lang.String viewIdentifier)Drops a view.Viewload(java.lang.String viewIdentifier)Loads a view by name.ViewDefinitionloadDefinition(java.lang.String viewIdentifier)Loads a view by name.default voidrename(java.lang.String oldIdentifier, java.lang.String newIdentifier)Renames a view.voidreplace(java.lang.String viewIdentifier, ViewDefinition viewDefinition, java.util.Map<java.lang.String,java.lang.String> properties)Replaces a view.
-
-
-
Method Detail
-
create
void create(java.lang.String viewIdentifier, ViewDefinition viewDefinition, java.util.Map<java.lang.String,java.lang.String> properties)Create a view without replacing any existing view.- Parameters:
viewIdentifier- view name or locationviewDefinition- SQL metadata of the viewproperties- Version property genie-id of the operation, as well as table properties such as owner, table type, common view flag etc.
-
replace
void replace(java.lang.String viewIdentifier, ViewDefinition viewDefinition, java.util.Map<java.lang.String,java.lang.String> properties)Replaces a view.- Parameters:
viewIdentifier- view name or locationviewDefinition- SQL metadata of the viewproperties- Version property genie-id of the operation, as well as table properties such as owner, table type, common view flag etc.
-
load
View load(java.lang.String viewIdentifier)
Loads a view by name.- Parameters:
viewIdentifier- view name or location- Returns:
- All the metadata of the view
-
loadDefinition
ViewDefinition loadDefinition(java.lang.String viewIdentifier)
Loads a view by name.- Parameters:
viewIdentifier- view name or location- Returns:
- SQL metadata of the view
-
drop
void drop(java.lang.String viewIdentifier)
Drops a view.- Parameters:
viewIdentifier- view name or location
-
rename
default void rename(java.lang.String oldIdentifier, java.lang.String newIdentifier)Renames a view.- Parameters:
oldIdentifier- the view identifier of the existing view to renamenewIdentifier- the new view identifier of the view
-
-