[][src]Struct ferrisetw::parser::Parser

pub struct Parser<'a> { /* fields omitted */ }
[]

Represents a Parser

This structure holds the necessary data to parse the ETW event and retrieve the data from the event

Implementations

impl<'a> Parser<'a>[src][]

pub fn create(schema: &'a Schema) -> Self[src][]

Use the create function to create an instance of a Parser

Arguments

  • schema - The Schema from the ETW Event we want to parse

Example

let my_callback = |record: EventRecord, schema_locator: &mut SchemaLocator| {
    let schema = schema_locator.event_schema(record)?;
    let parser = Parse::create(&schema);
};

Trait Implementations

impl<'_> TryParse<Guid> for Parser<'_>[src][+]

impl<'_> TryParse<IpAddr> for Parser<'_>[src][+]

impl<'_> TryParse<Pointer> for Parser<'_>[src][+]

impl<'_> TryParse<String> for Parser<'_>[src][+]

The String impl of the TryParse trait should be used to retrieve the following TdhInTypes:

  • InTypeUnicodeString
  • InTypeAnsiString
  • InTypeCountedString
  • InTypeGuid

On success a String with the with the data from the name property will be returned

Arguments

  • name - Name of the property to be found in the Schema

Example

let my_callback = |record: EventRecord, schema_locator: &mut SchemaLocator| {
    let schema = schema_locator.event_schema(record)?;
    let parser = Parse::create(&schema);
    let image_name: String = parser.try_parse("ImageName")?;
};

impl<'_> TryParse<Vec<u8>> for Parser<'_>[src][+]

impl<'_> TryParse<i16> for Parser<'_>[src][+]

impl<'_> TryParse<i32> for Parser<'_>[src][+]

impl<'_> TryParse<i64> for Parser<'_>[src][+]

impl<'_> TryParse<i8> for Parser<'_>[src][+]

impl<'_> TryParse<isize> for Parser<'_>[src][+]

impl<'_> TryParse<u16> for Parser<'_>[src][+]

impl<'_> TryParse<u32> for Parser<'_>[src][+]

impl<'_> TryParse<u64> for Parser<'_>[src][+]

impl<'_> TryParse<u8> for Parser<'_>[src][+]

impl<'_> TryParse<usize> for Parser<'_>[src][+]

Auto Trait Implementations

impl<'a> !RefUnwindSafe for Parser<'a>

impl<'a> !Send for Parser<'a>

impl<'a> !Sync for Parser<'a>

impl<'a> Unpin for Parser<'a>

impl<'a> UnwindSafe for Parser<'a>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src][+]

impl<T> Borrow<T> for T where
    T: ?Sized
[src][+]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src][+]

impl<T> From<T> for T[src][+]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src][+]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src][+]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src][+]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[+]