pub enum ContextRequest {
CreateFrame {
frame: ServerEnd<FrameMarker>,
control_handle: ContextControlHandle,
},
CreateFrameWithParams {
params: CreateFrameParams,
frame: ServerEnd<FrameMarker>,
control_handle: ContextControlHandle,
},
GetCookieManager {
manager: ServerEnd<CookieManagerMarker>,
control_handle: ContextControlHandle,
},
GetRemoteDebuggingPort {
responder: ContextGetRemoteDebuggingPortResponder,
},
}
Expand description
Manages browsing state (e.g. LocalStorage, cookies, etc) associated with a set of [Frame
].
Variants§
CreateFrame
Creates a new [Frame
] under this [Context
]. Destruction of a [Context
] triggers the
destruction of all of its associated [Frame
]. [Frame
] can be transferred to another
component but cannot be shared across multiple components.
frame
: An interface request that will be bound to the created [Frame
].
CreateFrameWithParams
Similar to [Context.CreateFrame
], with extra parameters.
params
: The configuration used to create the [Frame
]. This method will fail withZX_ERR_INVALID_ARGS
if the table is not clonable.frame
: An interface request that will be bound to the created [Frame
].
GetCookieManager
Used to observe cookies for sites hosted under this Context.
GetRemoteDebuggingPort
Waits until debugging is available on one or more Frames, and returns the DevTools port number. Multiple calls may be queued to received the port number.
If an error occurred, the ContextError
will be set to this value:
REMOTE_DEBUGGING_PORT_NOT_OPENED
:remote_debugging_port
was not set inCreateContextParams
or the remote debugging service failed to start.
Fields
§
responder: ContextGetRemoteDebuggingPortResponder
Implementations§
Source§impl ContextRequest
impl ContextRequest
pub fn into_create_frame( self, ) -> Option<(ServerEnd<FrameMarker>, ContextControlHandle)>
pub fn into_create_frame_with_params( self, ) -> Option<(CreateFrameParams, ServerEnd<FrameMarker>, ContextControlHandle)>
pub fn into_get_remote_debugging_port( self, ) -> Option<ContextGetRemoteDebuggingPortResponder>
Sourcepub fn method_name(&self) -> &'static str
pub fn method_name(&self) -> &'static str
Name of the method defined in FIDL
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ContextRequest
impl !RefUnwindSafe for ContextRequest
impl Send for ContextRequest
impl Sync for ContextRequest
impl Unpin for ContextRequest
impl !UnwindSafe for ContextRequest
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