pub struct BigqueryTableClient { /* private fields */ }Implementations§
source§impl BigqueryTableClient
impl BigqueryTableClient
pub fn new(inner: Arc<BigqueryClient>) -> Self
sourcepub async fn create(&self, metadata: &Table) -> Result<Table, Error>
pub async fn create(&self, metadata: &Table) -> Result<Table, Error>
https://cloud.google.com/bigquery/docs/reference/rest/v2/tables/create
use google_cloud_bigquery::http::bigquery_table_client::BigqueryTableClient;
use google_cloud_bigquery::http::error::Error;
use google_cloud_bigquery::http::table::{Table, TableFieldSchema, TableFieldType, TableReference, TableSchema};
async fn run(client: BigqueryTableClient) -> Result<Table, Error> {
let table = Table {
table_reference: TableReference {
project_id: "project".to_string(),
dataset_id: "dataset".to_string(),
table_id: "table".to_string()
},
schema: Some(TableSchema {
fields: vec![
TableFieldSchema {
name: "col1".to_string(),
data_type: TableFieldType::String,
max_length: Some(32),
..Default::default()
}
]
}),
..Default::default()
};
client.create(&table).await
}sourcepub async fn delete(
&self,
project_id: &str,
dataset_id: &str,
table_id: &str
) -> Result<(), Error>
pub async fn delete( &self, project_id: &str, dataset_id: &str, table_id: &str ) -> Result<(), Error>
https://cloud.google.com/bigquery/docs/reference/rest/v2/tables/delete
sourcepub async fn patch(&self, metadata: &Table) -> Result<Table, Error>
pub async fn patch(&self, metadata: &Table) -> Result<Table, Error>
https://cloud.google.com/bigquery/docs/reference/rest/v2/tables/patch
sourcepub async fn get(
&self,
project_id: &str,
dataset_id: &str,
table_id: &str
) -> Result<Table, Error>
pub async fn get( &self, project_id: &str, dataset_id: &str, table_id: &str ) -> Result<Table, Error>
https://cloud.google.com/bigquery/docs/reference/rest/v2/tables/get
sourcepub async fn get_iam_policy(
&self,
project_id: &str,
dataset_id: &str,
table_id: &str,
req: &GetIamPolicyRequest
) -> Result<Policy, Error>
pub async fn get_iam_policy( &self, project_id: &str, dataset_id: &str, table_id: &str, req: &GetIamPolicyRequest ) -> Result<Policy, Error>
https://cloud.google.com/bigquery/docs/reference/rest/v2/tables/get_iam_policy
sourcepub async fn set_iam_policy(
&self,
project_id: &str,
dataset_id: &str,
table_id: &str,
req: &SetIamPolicyRequest
) -> Result<Policy, Error>
pub async fn set_iam_policy( &self, project_id: &str, dataset_id: &str, table_id: &str, req: &SetIamPolicyRequest ) -> Result<Policy, Error>
https://cloud.google.com/bigquery/docs/reference/rest/v2/tables/set_iam_policy
sourcepub async fn test_iam_permissions(
&self,
project_id: &str,
dataset_id: &str,
table_id: &str,
req: &TestIamPermissionsRequest
) -> Result<TestIamPermissionsResponse, Error>
pub async fn test_iam_permissions( &self, project_id: &str, dataset_id: &str, table_id: &str, req: &TestIamPermissionsRequest ) -> Result<TestIamPermissionsResponse, Error>
https://cloud.google.com/bigquery/docs/reference/rest/v2/tables/test_iam_policy
sourcepub async fn list(
&self,
project_id: &str,
dataset_id: &str,
req: &ListTablesRequest
) -> Result<Vec<TableOverview>, Error>
pub async fn list( &self, project_id: &str, dataset_id: &str, req: &ListTablesRequest ) -> Result<Vec<TableOverview>, Error>
https://cloud.google.com/bigquery/docs/reference/rest/v2/tables/list
Trait Implementations§
source§impl Clone for BigqueryTableClient
impl Clone for BigqueryTableClient
source§fn clone(&self) -> BigqueryTableClient
fn clone(&self) -> BigqueryTableClient
Returns a copy 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 !RefUnwindSafe for BigqueryTableClient
impl Send for BigqueryTableClient
impl Sync for BigqueryTableClient
impl Unpin for BigqueryTableClient
impl !UnwindSafe for BigqueryTableClient
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> 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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request