pub(crate) struct DevtoolsInstance {
pub(crate) registry: Arc<ActorRegistry>,
pub(crate) id_map: Arc<Mutex<IdMap>>,
pub(crate) browsing_contexts: FxHashMap<BrowsingContextId, String>,
pub(crate) sender: Sender<DevtoolsControlMsg>,
pub(crate) receiver: Receiver<DevtoolsControlMsg>,
pub(crate) pipelines: FxHashMap<PipelineId, BrowsingContextId>,
pub(crate) actor_workers: FxHashMap<WorkerId, String>,
pub(crate) actor_requests: HashMap<String, String>,
pub(crate) connections: Arc<Mutex<FxHashMap<StreamId, DevtoolsConnection>>>,
pub(crate) next_resource_id: u64,
}Fields§
§registry: Arc<ActorRegistry>§id_map: Arc<Mutex<IdMap>>§browsing_contexts: FxHashMap<BrowsingContextId, String>§sender: Sender<DevtoolsControlMsg>This is handed to clients so they can notify the devtools instance when their connection closes.
receiver: Receiver<DevtoolsControlMsg>§pipelines: FxHashMap<PipelineId, BrowsingContextId>§actor_workers: FxHashMap<WorkerId, String>§actor_requests: HashMap<String, String>§connections: Arc<Mutex<FxHashMap<StreamId, DevtoolsConnection>>>A map of active TCP connections to devtools clients.
Client threads remove their connection from here once they exit.
next_resource_id: u64Implementations§
Source§impl DevtoolsInstance
impl DevtoolsInstance
pub(crate) fn create( sender: Sender<DevtoolsControlMsg>, receiver: Receiver<DevtoolsControlMsg>, embedder: EmbedderProxy, ) -> Option<Self>
pub(crate) fn run(self)
pub(crate) fn handle_framerate_tick(&self, actor_name: String, tick: f64)
pub(crate) fn handle_new_global( &mut self, ids: (BrowsingContextId, PipelineId, Option<WorkerId>, WebViewId), script_sender: GenericSender<DevtoolScriptControlMsg>, page_info: DevtoolsPageInfo, )
pub(crate) fn handle_title_changed( &self, pipeline_id: PipelineId, title: String, )
pub(crate) fn handle_console_resource( &mut self, pipeline_id: PipelineId, worker_id: Option<WorkerId>, resource: ConsoleResource, )
pub(crate) fn handle_dom_mutation( &mut self, pipeline_id: PipelineId, dom_mutation: DomMutation, ) -> Result<(), ActorError>
pub(crate) fn handle_clear_console( &mut self, pipeline_id: PipelineId, worker_id: Option<WorkerId>, )
pub(crate) fn find_console_actor( &self, pipeline_id: PipelineId, worker_id: Option<WorkerId>, ) -> Option<String>
pub(crate) fn handle_network_event( &mut self, connections: Vec<DevtoolsConnection>, request_id: String, network_event: NetworkEvent, )
Sourcepub(crate) fn create_network_event_actor(
&mut self,
request_id: String,
watcher_name: String,
) -> String
pub(crate) fn create_network_event_actor( &mut self, request_id: String, watcher_name: String, ) -> String
Create a new NetworkEventActor for a given request ID and watcher name.
pub(crate) fn handle_create_source_actor( &mut self, script_sender: GenericSender<DevtoolScriptControlMsg>, pipeline_id: PipelineId, source_info: SourceInfo, )
pub(crate) fn handle_update_source_content( &mut self, pipeline_id: PipelineId, source_content: String, )
pub(crate) fn handle_debugger_pause( &mut self, pipeline_id: PipelineId, frame_offset: FrameOffset, pause_reason: PauseReason, )
pub(crate) fn handle_create_frame_actor( &mut self, result_sender: GenericSender<String>, pipeline_id: PipelineId, frame: FrameInfo, )
pub(crate) fn handle_create_environment_actor( &mut self, result_sender: GenericSender<String>, environment_info: EnvironmentInfo, parent: Option<String>, )
Trait Implementations§
Source§impl MallocSizeOf for DevtoolsInstance
impl MallocSizeOf for DevtoolsInstance
Source§fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
Measure the heap usage of all descendant heap-allocated structures, but
not the space taken up by the value itself.
Auto Trait Implementations§
impl Freeze for DevtoolsInstance
impl !RefUnwindSafe for DevtoolsInstance
impl Send for DevtoolsInstance
impl Sync for DevtoolsInstance
impl Unpin for DevtoolsInstance
impl !UnwindSafe for DevtoolsInstance
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> MaybeBoxed<Box<T>> for T
impl<T> MaybeBoxed<Box<T>> for T
Source§fn maybe_boxed(self) -> Box<T>
fn maybe_boxed(self) -> Box<T>
Convert
Source§impl<T> MaybeBoxed<T> for T
impl<T> MaybeBoxed<T> for T
Source§fn maybe_boxed(self) -> T
fn maybe_boxed(self) -> T
Convert