Package org.apache.iceberg.view
Interface View
- All Known Implementing Classes:
- BaseView
public interface View
Interface for view definition.
- 
Method SummaryModifier and TypeMethodDescriptionGet the current version for this view, or null if there are no versions.history()Get the version history of this table.default Stringlocation()Return the view's base location.name()Return a map of string properties for this view.default ReplaceViewVersionCreate a newReplaceViewVersionto replace the view's current version.schema()Return theschemafor this view.schemas()Return a map ofschemafor this view.default SQLViewRepresentationReturns the view representation for the given SQL dialectdefault UpdateLocationCreate a newUpdateLocationto set the view's location.Create a newUpdateViewPropertiesto update view properties.default UUIDuuid()Returns the view's UUIDversion(int versionId) Get a version in this view by ID.versions()Get the versions of this view.
- 
Method Details- 
nameString name()
- 
schemaSchema schema()Return theschemafor this view.- Returns:
- this table's schema
 
- 
schemasReturn a map ofschemafor this view.- Returns:
- this table's schema map
 
- 
currentVersionViewVersion currentVersion()Get the current version for this view, or null if there are no versions.- Returns:
- the current view version.
 
- 
versionsIterable<ViewVersion> versions()Get the versions of this view.- Returns:
- an Iterable of versions of this view.
 
- 
versionGet a version in this view by ID.- Parameters:
- versionId- version ID
- Returns:
- a version, or null if the ID cannot be found
 
- 
historyList<ViewHistoryEntry> history()Get the version history of this table.- Returns:
- a list of ViewHistoryEntry
 
- 
propertiesReturn a map of string properties for this view.- Returns:
- this view's properties map
 
- 
locationReturn the view's base location.- Returns:
- this view's location
 
- 
updatePropertiesUpdateViewProperties updateProperties()Create a newUpdateViewPropertiesto update view properties.- Returns:
- a new UpdateViewProperties
 
- 
replaceVersionCreate a newReplaceViewVersionto replace the view's current version.- Returns:
- a new ReplaceViewVersion
 
- 
updateLocationCreate a newUpdateLocationto set the view's location.- Returns:
- a new UpdateLocation
 
- 
uuidReturns the view's UUID- Returns:
- the view's UUID
 
- 
sqlForReturns the view representation for the given SQL dialect- Returns:
- the view representation for the given SQL dialect, or null if no representation could be resolved
 
 
-