Struct minidump::MinidumpSystemInfo
source · pub struct MinidumpSystemInfo {
pub raw: MINIDUMP_SYSTEM_INFO,
pub os: Os,
pub cpu: Cpu,
/* private fields */
}
Expand description
Information about the system that generated the minidump.
Fields§
§raw: MINIDUMP_SYSTEM_INFO
The MINIDUMP_SYSTEM_INFO
direct from the minidump
os: Os
The operating system that generated the minidump
cpu: Cpu
The CPU on which the minidump was generated
Implementations§
source§impl MinidumpSystemInfo
impl MinidumpSystemInfo
sourcepub fn print<T: Write>(&self, f: &mut T) -> Result<()>
pub fn print<T: Write>(&self, f: &mut T) -> Result<()>
Write a human-readable description of this MinidumpSystemInfo
to f
.
This is very verbose, it is the format used by minidump_dump
.
sourcepub fn csd_version(&self) -> Option<Cow<'_, str>>
pub fn csd_version(&self) -> Option<Cow<'_, str>>
If the minidump was generated on:
- Windows: Returns the the name of the Service Pack.
- macOS: Returns the product build number.
- Linux: Returns the contents of
uname -srvmo
.
sourcepub fn cpu_info(&self) -> Option<Cow<'_, str>>
pub fn cpu_info(&self) -> Option<Cow<'_, str>>
Returns a string describing the cpu’s vendor and model.
sourcepub fn os_parts(&self) -> (String, Option<String>)
pub fn os_parts(&self) -> (String, Option<String>)
Strings identifying the version and build number of the operating system. Returns a tuple in the format of (version, build number). This may be useful to use if the minidump was created on a Linux machine and is an producing empty-ish version number (0.0.0).
Tries to parse the version number from the build if it cannot be found in the version string. If the stream already contains a valid version number or parsing from the build string fails, this will return what’s directly stored in the stream.
Trait Implementations§
source§impl Clone for MinidumpSystemInfo
impl Clone for MinidumpSystemInfo
source§fn clone(&self) -> MinidumpSystemInfo
fn clone(&self) -> MinidumpSystemInfo
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for MinidumpSystemInfo
impl Debug for MinidumpSystemInfo
source§impl<'a> MinidumpStream<'a> for MinidumpSystemInfo
impl<'a> MinidumpStream<'a> for MinidumpSystemInfo
source§const STREAM_TYPE: u32 = 7u32
const STREAM_TYPE: u32 = 7u32
md::MDRawDirectory
entry.
This is usually a MINIDUMP_STREAM_TYPE but it’s left as a u32
to allow external projects to add support for their own custom streams.