pub struct CreateTableBuilder { /* private fields */ }
Expand description
Builder for CreateTable
.
Implementations§
Source§impl CreateTableBuilder
impl CreateTableBuilder
Sourcepub fn with_location<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn with_location<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
Location tables base location
Sourcepub fn with_schema(&mut self, value: Schema) -> &mut Self
pub fn with_schema(&mut self, value: Schema) -> &mut Self
Table schemma
Sourcepub fn with_partition_spec(&mut self, value: PartitionSpec) -> &mut Self
pub fn with_partition_spec(&mut self, value: PartitionSpec) -> &mut Self
Partition spec
Sourcepub fn with_sort_order(&mut self, value: SortOrder) -> &mut Self
pub fn with_sort_order(&mut self, value: SortOrder) -> &mut Self
Sort order
Sourcepub fn with_stage_create(&mut self, value: bool) -> &mut Self
pub fn with_stage_create(&mut self, value: bool) -> &mut Self
stage create
Sourcepub fn with_properties(&mut self, value: HashMap<String, String>) -> &mut Self
pub fn with_properties(&mut self, value: HashMap<String, String>) -> &mut Self
Table properties
Sourcepub fn with_property<VALUE>(&mut self, item: VALUE) -> &mut Self
pub fn with_property<VALUE>(&mut self, item: VALUE) -> &mut Self
Table properties
Sourcepub fn create(&self) -> Result<CreateTable, CreateTableBuilderError>
pub fn create(&self) -> Result<CreateTable, CreateTableBuilderError>
Source§impl CreateTableBuilder
impl CreateTableBuilder
Sourcepub async fn build(
&mut self,
namespace: &[String],
catalog: Arc<dyn Catalog>,
) -> Result<Table, Error>
pub async fn build( &mut self, namespace: &[String], catalog: Arc<dyn Catalog>, ) -> Result<Table, Error>
Builds and registers a new table in the catalog
§Arguments
namespace
- The namespace where the table will be createdcatalog
- The catalog where the table will be registered
§Returns
Ok(Table)
- The newly created tableErr(Error)
- If table creation fails, e.g. due to missing name or catalog errors
This method finalizes the table configuration and registers it in the specified catalog. It uses the builder’s current state to create the table metadata.
Trait Implementations§
Source§impl Clone for CreateTableBuilder
impl Clone for CreateTableBuilder
Source§fn clone(&self) -> CreateTableBuilder
fn clone(&self) -> CreateTableBuilder
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for CreateTableBuilder
impl RefUnwindSafe for CreateTableBuilder
impl Send for CreateTableBuilder
impl Sync for CreateTableBuilder
impl Unpin for CreateTableBuilder
impl UnwindSafe for CreateTableBuilder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more