pub struct ClientBuilder { /* private fields */ }
Expand description
A builder for Client
Implementations§
Source§impl ClientBuilder
impl ClientBuilder
Sourcepub async fn build(self) -> Result<Client, BlobfsError>
pub async fn build(self) -> Result<Client, BlobfsError>
Opens the /blob directory in the component’s namespace with readable, writable, and/or
executable flags. Connects to the fuchsia.fxfs.BlobCreator and BlobReader if requested.
Connects to and initializes the VmexResource if use_vmex
is set. Returns a Client
.
Sourcepub fn use_reader(self) -> Self
pub fn use_reader(self) -> Self
Client
will connect to and use fuchsia.fxfs/BlobReader for reads. Sets the VmexResource
for Client
. The VmexResource is used by get_backing_memory
to mark blobs as executable.
Sourcepub fn use_reader_no_vmex(self) -> Self
pub fn use_reader_no_vmex(self) -> Self
Client
will connect to and use fuchsia.fxfs/BlobReader for reads. Does not set the
VmexResource.
Sourcepub fn use_creator(self) -> Self
pub fn use_creator(self) -> Self
If set, Client
will connect to and use fuchsia.fxfs/BlobCreator for writes.
Sourcepub fn readable(self) -> Self
pub fn readable(self) -> Self
If set, Client
will connect to /blob in the current component’s namespace with
OPEN_RIGHT_READABLE.
Sourcepub fn writable(self) -> Self
pub fn writable(self) -> Self
If set, Client
will connect to /blob in the current component’s namespace with
OPEN_RIGHT_WRITABLE. WRITABLE is needed so that delete_blob
can call
fuchsia.io/Directory.Unlink.
Sourcepub fn executable(self) -> Self
pub fn executable(self) -> Self
If set, Client
will connect to /blob in the current component’s namespace with
OPEN_RIGHT_EXECUTABLE.