pub struct EngineProxy { /* private fields */ }
Implementations§
Source§impl EngineProxy
impl EngineProxy
Sourcepub fn take_event_stream(&self) -> EngineEventStream
pub fn take_event_stream(&self) -> EngineEventStream
Get a Stream of events from the remote end of the protocol.
§Panics
Panics if the event stream was already taken.
Sourcepub fn start_edit_transaction(
&self,
transaction: ServerEnd<EditTransactionMarker>,
) -> Result<(), Error>
pub fn start_edit_transaction( &self, transaction: ServerEnd<EditTransactionMarker>, ) -> Result<(), Error>
Begins a rule edit transaction.
- request
transaction
a request for an [EditTransaction
].
Sourcepub fn list(&self, iterator: ServerEnd<RuleIteratorMarker>) -> Result<(), Error>
pub fn list(&self, iterator: ServerEnd<RuleIteratorMarker>) -> Result<(), Error>
Returns an iterator over all rewrite rules.
- request
iterator
a request for an iterator.
Sourcepub fn list_static(
&self,
iterator: ServerEnd<RuleIteratorMarker>,
) -> Result<(), Error>
pub fn list_static( &self, iterator: ServerEnd<RuleIteratorMarker>, ) -> Result<(), Error>
Returns an iterator over all static (immutable) rewrite rules. These
rules are handled as lower priority than dynamic rules and cannot be
modified (although they can be overridden) by [EditTransaction
]s.
- request
iterator
a request for an iterator.
Sourcepub fn test_apply(
&self,
url: &str,
) -> QueryResponseFut<EngineTestApplyResult, DefaultFuchsiaResourceDialect>
pub fn test_apply( &self, url: &str, ) -> QueryResponseFut<EngineTestApplyResult, DefaultFuchsiaResourceDialect>
Rewrites the given url
with the current rewrite rule set, returning the
rewritten
url. If no rules match or a rule matches but performs an
identity transformation, this API returns url
unchanged.
This API is intended only for reflecting on rule side effects. Using
this API to pre-apply the rules, then passing the result to
[fuchsia.pkg/PackageResolver.Resolve
] would apply the rules twice.
- request
url
the url to rewrite.
- response
rewritten
the rewritten url.
- error a zx_status value indicating failure. One of the following:
ZX_ERR_INVALID_ARGS
ifurl
is not a validfuchsia-pkg://
URL. Seefuchsia-pkg URL
.
Trait Implementations§
Source§impl Clone for EngineProxy
impl Clone for EngineProxy
Source§fn clone(&self) -> EngineProxy
fn clone(&self) -> EngineProxy
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for EngineProxy
impl Debug for EngineProxy
Source§impl EngineProxyInterface for EngineProxy
impl EngineProxyInterface for EngineProxy
type TestApplyResponseFut = QueryResponseFut<Result<String, i32>>
fn start_edit_transaction( &self, transaction: ServerEnd<EditTransactionMarker>, ) -> Result<(), Error>
fn list(&self, iterator: ServerEnd<RuleIteratorMarker>) -> Result<(), Error>
fn list_static( &self, iterator: ServerEnd<RuleIteratorMarker>, ) -> Result<(), Error>
fn test_apply(&self, url: &str) -> Self::TestApplyResponseFut
Source§impl Proxy for EngineProxy
impl Proxy for EngineProxy
Source§type Protocol = EngineMarker
type Protocol = EngineMarker
Proxy
controls.Source§fn from_channel(inner: AsyncChannel) -> Self
fn from_channel(inner: AsyncChannel) -> Self
Source§fn into_channel(self) -> Result<AsyncChannel, Self>
fn into_channel(self) -> Result<AsyncChannel, Self>
Source§fn as_channel(&self) -> &AsyncChannel
fn as_channel(&self) -> &AsyncChannel
§fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
Auto Trait Implementations§
impl Freeze for EngineProxy
impl !RefUnwindSafe for EngineProxy
impl Send for EngineProxy
impl Sync for EngineProxy
impl Unpin for EngineProxy
impl !UnwindSafe for EngineProxy
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
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)
clone_to_uninit
)