pub struct RepositoryManagerProxy { /* private fields */ }Implementations§
Source§impl RepositoryManagerProxy
impl RepositoryManagerProxy
Sourcepub fn new(channel: AsyncChannel) -> Self
pub fn new(channel: AsyncChannel) -> Self
Create a new Proxy for fuchsia.pkg/RepositoryManager.
Sourcepub fn take_event_stream(&self) -> RepositoryManagerEventStream
pub fn take_event_stream(&self) -> RepositoryManagerEventStream
Get a Stream of events from the remote end of the protocol.
§Panics
Panics if the event stream was already taken.
Sourcepub fn add(
&self,
repo: &RepositoryConfig,
) -> QueryResponseFut<RepositoryManagerAddResult, DefaultFuchsiaResourceDialect>
pub fn add( &self, repo: &RepositoryConfig, ) -> QueryResponseFut<RepositoryManagerAddResult, DefaultFuchsiaResourceDialect>
Adds a repository. This will overwrite the repository if it already exists.
- request
repoa repository to add to the resolver.
- error a zx_status value indicating failure. One of the following:
ZX_ERR_ACCESS_DENIEDif editing repositories is permanently disabled.ZX_ERR_ALREADY_EXISTSif the repository already exists.ZX_ERR_INVALID_ARGSif the repository is malformed.
Sourcepub fn remove(
&self,
repo_url: &str,
) -> QueryResponseFut<RepositoryManagerRemoveResult, DefaultFuchsiaResourceDialect>
pub fn remove( &self, repo_url: &str, ) -> QueryResponseFut<RepositoryManagerRemoveResult, DefaultFuchsiaResourceDialect>
Removes a repository.
Removing a repository will prevent future packages from being cached from this repository, but in-flight downloads may not be interrupted.
- request
repo_urlthe URL of the repository we want to remove.
- error a zx_status value indicating failure. One of the following:
ZX_ERR_ACCESS_DENIEDif editing repositories is permanently disabled or therepo_urlmatches a static repository.ZX_ERR_INVALID_ARGSif therepo_urlis malformed.ZX_ERR_NOT_FOUNDif the repository does not exist.
Sourcepub fn add_mirror(
&self,
repo_url: &str,
mirror: &MirrorConfig,
) -> QueryResponseFut<RepositoryManagerAddMirrorResult, DefaultFuchsiaResourceDialect>
pub fn add_mirror( &self, repo_url: &str, mirror: &MirrorConfig, ) -> QueryResponseFut<RepositoryManagerAddMirrorResult, DefaultFuchsiaResourceDialect>
Adds a mirror to a repository. This will overwrite the mirror if it already exists.
- request
repo_urlthe URL of the repository to add the mirror to. - request
mirrorthe mirror config used to add the mirror.
- error a zx_status value indicating failure. One of the following:
ZX_ERR_ALREADY_EXISTSif the mirror for this repository already exists.ZX_ERR_INVALID_ARGSif therepo_urlor themirroris malformed.ZX_ERR_NOT_FOUNDif the repository does not exist.
Sourcepub fn remove_mirror(
&self,
repo_url: &str,
mirror_url: &str,
) -> QueryResponseFut<RepositoryManagerRemoveMirrorResult, DefaultFuchsiaResourceDialect>
pub fn remove_mirror( &self, repo_url: &str, mirror_url: &str, ) -> QueryResponseFut<RepositoryManagerRemoveMirrorResult, DefaultFuchsiaResourceDialect>
Removes a mirror from a repository.
Removing a mirror will prevent future packages from being cached from that mirror, but in-flight downloads may not be interrupted.
- request
repo_urlthe URL of the mirror’s repository. - request
mirror_urlthe URL of the mirror we want to remove.
- error a zx_status value indicating failure. One of the following:
ZX_ERR_INVALID_ARGSif therepo_urlor themirror_urlis malformed.ZX_ERR_NOT_FOUNDif the repository or mirror does not exist.
Trait Implementations§
Source§impl Clone for RepositoryManagerProxy
impl Clone for RepositoryManagerProxy
Source§fn clone(&self) -> RepositoryManagerProxy
fn clone(&self) -> RepositoryManagerProxy
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 moreSource§impl Debug for RepositoryManagerProxy
impl Debug for RepositoryManagerProxy
Source§impl Proxy for RepositoryManagerProxy
impl Proxy for RepositoryManagerProxy
Source§type Protocol = RepositoryManagerMarker
type Protocol = RepositoryManagerMarker
The protocol which this
Proxy controls.Source§fn from_channel(inner: AsyncChannel) -> Self
fn from_channel(inner: AsyncChannel) -> Self
Create a proxy over the given channel.
Source§fn into_channel(self) -> Result<AsyncChannel, Self>
fn into_channel(self) -> Result<AsyncChannel, Self>
Attempt to convert the proxy back into a channel. Read more
Source§fn as_channel(&self) -> &AsyncChannel
fn as_channel(&self) -> &AsyncChannel
Get a reference to the proxy’s underlying channel. Read more
Source§fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
Attempt to convert the proxy back into a client end. Read more
Source§fn on_closed(&self) -> OnSignals<'_, Unowned<'_, NullableHandle>>
fn on_closed(&self) -> OnSignals<'_, Unowned<'_, NullableHandle>>
Returns a future that completes when the proxy receives the
PEER_CLOSED signal.Source§impl RepositoryManagerProxyInterface for RepositoryManagerProxy
impl RepositoryManagerProxyInterface for RepositoryManagerProxy
type AddResponseFut = QueryResponseFut<Result<(), i32>>
type RemoveResponseFut = QueryResponseFut<Result<(), i32>>
type AddMirrorResponseFut = QueryResponseFut<Result<(), i32>>
type RemoveMirrorResponseFut = QueryResponseFut<Result<(), i32>>
fn add(&self, repo: &RepositoryConfig) -> Self::AddResponseFut
fn remove(&self, repo_url: &str) -> Self::RemoveResponseFut
fn add_mirror( &self, repo_url: &str, mirror: &MirrorConfig, ) -> Self::AddMirrorResponseFut
fn remove_mirror( &self, repo_url: &str, mirror_url: &str, ) -> Self::RemoveMirrorResponseFut
fn list( &self, iterator: ServerEnd<RepositoryIteratorMarker>, ) -> Result<(), Error>
Auto Trait Implementations§
impl Freeze for RepositoryManagerProxy
impl !RefUnwindSafe for RepositoryManagerProxy
impl Send for RepositoryManagerProxy
impl Sync for RepositoryManagerProxy
impl Unpin for RepositoryManagerProxy
impl UnsafeUnpin for RepositoryManagerProxy
impl !UnwindSafe for RepositoryManagerProxy
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, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
Source§impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
Source§impl<T> FromClient for Twhere
T: Proxy,
impl<T> FromClient for Twhere
T: Proxy,
§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> ProxyHasDomain for Twhere
T: Proxy,
impl<T> ProxyHasDomain for Twhere
T: Proxy,
Source§fn domain(&self) -> ZirconClient
fn domain(&self) -> ZirconClient
Get a “client” for this proxy. This is just an object which has methods
for a few common handle creation operations.