pub struct DiagnosticsLogging {
options: [bool; 11],
}Expand description
The current configuration of the diagnostic options for Servo.
Fields§
§options: [bool; 11]Implementations§
Source§impl DiagnosticsLogging
impl DiagnosticsLogging
Sourcepub fn new() -> Self
pub fn new() -> Self
Create a new DiagnosticsLogging configuration.
In builds with debug assertions enabled, this will automatically read and parse the SERVO_DIAGNOSTICS environment variable if it is set.
Sourcepub fn toggle_option(&mut self, option: DiagnosticsLoggingOption, enabled: bool)
pub fn toggle_option(&mut self, option: DiagnosticsLoggingOption, enabled: bool)
Enables or disables the diagnostics represented by the given DiagnosticsLoggingOption
variant.
Sourcepub fn is_enabled(&self, option: DiagnosticsLoggingOption) -> bool
pub fn is_enabled(&self, option: DiagnosticsLoggingOption) -> bool
Returns true if the given diagnostic option is enabled.
Trait Implementations§
Source§impl Clone for DiagnosticsLogging
impl Clone for DiagnosticsLogging
Source§fn clone(&self) -> DiagnosticsLogging
fn clone(&self) -> DiagnosticsLogging
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 DiagnosticsLogging
impl Debug for DiagnosticsLogging
Source§impl Default for DiagnosticsLogging
impl Default for DiagnosticsLogging
Source§fn default() -> DiagnosticsLogging
fn default() -> DiagnosticsLogging
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for DiagnosticsLogging
impl<'de> Deserialize<'de> for DiagnosticsLogging
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for DiagnosticsLogging
impl RefUnwindSafe for DiagnosticsLogging
impl Send for DiagnosticsLogging
impl Sync for DiagnosticsLogging
impl Unpin for DiagnosticsLogging
impl UnsafeUnpin for DiagnosticsLogging
impl UnwindSafe for DiagnosticsLogging
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