Struct script::dom::servoparser::ParserContext
source · pub struct ParserContext {
parser: Option<Trusted<ServoParser>>,
is_synthesized_document: bool,
id: PipelineId,
url: ServoUrl,
resource_timing: ResourceFetchTiming,
pushed_entry_index: Option<usize>,
}
Expand description
The context required for asynchronously fetching a document and parsing it progressively.
Fields§
§parser: Option<Trusted<ServoParser>>
The parser that initiated the request.
is_synthesized_document: bool
Is this a synthesized document
id: PipelineId
The pipeline associated with this document.
url: ServoUrl
The URL for this document.
resource_timing: ResourceFetchTiming
timing data for this resource
pushed_entry_index: Option<usize>
pushed entry index
Implementations§
source§impl ParserContext
impl ParserContext
pub fn new(id: PipelineId, url: ServoUrl) -> ParserContext
Trait Implementations§
source§impl FetchResponseListener for ParserContext
impl FetchResponseListener for ParserContext
fn process_request_body(&mut self)
fn process_request_eof(&mut self)
fn process_response(&mut self, meta_result: Result<FetchMetadata, NetworkError>)
fn process_response_chunk(&mut self, payload: Vec<u8>)
fn process_response_eof(
&mut self,
status: Result<ResourceFetchTiming, NetworkError>
)
fn resource_timing_mut(&mut self) -> &mut ResourceFetchTiming
fn resource_timing(&self) -> &ResourceFetchTiming
fn submit_resource_timing(&mut self)
source§impl PreInvoke for ParserContext
impl PreInvoke for ParserContext
fn should_invoke(&self) -> bool
Auto Trait Implementations§
impl !RefUnwindSafe for ParserContext
impl Send for ParserContext
impl !Sync for ParserContext
impl Unpin for ParserContext
impl !UnwindSafe for ParserContext
Blanket Implementations§
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> MaybeBoxed<Box<T, Global>> for T
impl<T> MaybeBoxed<Box<T, Global>> for T
source§fn maybe_boxed(self) -> Box<T, Global>
fn maybe_boxed(self) -> Box<T, Global>
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