Struct objectscale_client::client::ObjectstoreClient

source ·
pub struct ObjectstoreClient { /* private fields */ }

Implementations§

source§

impl ObjectstoreClient

source

pub fn create_bucket(&mut self, bucket: Bucket) -> Result<Bucket>

Create an bucket.

bucket: Bucket to create.

source

pub fn get_bucket(&mut self, name: &str, namespace: &str) -> Result<Bucket>

Gets bucket information for the specified bucket.

name: Bucket name for which information will be retrieved. Cannot be empty. namespace: Namespace associated. Cannot be empty.

source

pub fn delete_bucket( &mut self, name: &str, namespace: &str, empty_bucket: bool, ) -> Result<()>

Deletes the specified bucket.

name: Bucket name to be deleted. Cannot be empty. namespace: Namespace associated. Cannot be empty. emptyBucket: If true, the contents of the bucket will be emptied as part of the delete, otherwise it will fail if the bucket is not empty..

source

pub fn list_buckets( &mut self, namespace: &str, name_prefix: &str, ) -> Result<Vec<Bucket>>

Gets the list of buckets for the specified namespace.

namespace: Namespace for which buckets should be listed. Cannot be empty. name_prefix: Case sensitive prefix of the Bucket name with a wild card(). Can be empty or any_prefix_string.

source

pub fn create_tenant(&mut self, tenant: Tenant) -> Result<Tenant>

Creates the tenant which will associate an IAM Account within an objectstore.

tenant: Tenant to create

source

pub fn delete_tenant(&mut self, name: &str) -> Result<()>

Delete the tenant from an object store. Tenant must not own any buckets.

name: The associated account id. Cannot be empty.

source

pub fn get_tenant(&mut self, name: &str) -> Result<Tenant>

Get the tenant.

name: The associated account id. Cannot be empty.

source

pub fn list_tenants(&mut self, name_prefix: &str) -> Result<Vec<Tenant>>

Get the list of tenants.

name_prefix: Case sensitive prefix of the tenant name with a wild card(). Can be empty or any_prefix_string.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more