pub struct ModelApi { /* private fields */ }
Expand description
A model API handler.
Implementations§
Source§impl ModelApi
impl ModelApi
Sourcepub async fn list(
&self,
project_id: &str,
dataset_id: &str,
options: ListOptions,
) -> Result<ListModelsResponse, BQError>
pub async fn list( &self, project_id: &str, dataset_id: &str, options: ListOptions, ) -> Result<ListModelsResponse, BQError>
Lists all models in the specified dataset. Requires the READER dataset role.
§Arguments
project_id
- Project ID of the models to list.dataset_id
- Dataset ID of the models to list.
Sourcepub async fn delete(
&self,
project_id: &str,
dataset_id: &str,
model_id: &str,
) -> Result<(), BQError>
pub async fn delete( &self, project_id: &str, dataset_id: &str, model_id: &str, ) -> Result<(), BQError>
Deletes the model specified by modelId from the dataset.
§Arguments
project_id
- Project ID of the model to deletedataset_id
- Dataset ID of the model to deletemodel_id
- Model ID of the model to delete
Sourcepub async fn get(
&self,
project_id: &str,
dataset_id: &str,
model_id: &str,
) -> Result<Model, BQError>
pub async fn get( &self, project_id: &str, dataset_id: &str, model_id: &str, ) -> Result<Model, BQError>
Gets the specified model resource by model ID.
§Arguments
project_id
- Project ID of the requested modeldataset_id
- Dataset ID of the requested modelroutine_id
- Routine ID of the requested model
Sourcepub async fn update(
&self,
project_id: &str,
dataset_id: &str,
model_id: &str,
model: Model,
) -> Result<Model, BQError>
pub async fn update( &self, project_id: &str, dataset_id: &str, model_id: &str, model: Model, ) -> Result<Model, BQError>
Patch specific fields in the specified model.
§Arguments
project_id
- Project ID of the model to patchdataset_id
- Dataset ID of the model to patchmodel_id
- Routine ID of the model to patchmodel
- Model to patch
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ModelApi
impl !RefUnwindSafe for ModelApi
impl Send for ModelApi
impl Sync for ModelApi
impl Unpin for ModelApi
impl !UnwindSafe for ModelApi
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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