#[non_exhaustive]pub enum Coercion {
String,
Integer,
Timestamp,
UnixSeconds,
Ip,
}Expand description
A conversion of a source value to an OCSF type.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
String
Text; a number becomes its decimal text.
Integer
A whole number, from a number, its decimal text, or its hexadecimal
text after 0x, as Windows writes process and logon identifiers.
Timestamp
An RFC 3339 time, such as 2025-12-25T14:30:27.369114Z, as the
milliseconds since the Unix epoch OCSF stores.
UnixSeconds
Seconds since the Unix epoch, with a fraction if any, such as
auditd’s 1727251200.123, as milliseconds.
Ip
An IP address, v4 or v6, kept as written. Text that is not one, such
as the service name AWS writes where a service made a call, is
reported and kept under unmapped, never written as an address.
Trait Implementations§
impl Copy for Coercion
Source§impl<'de> Deserialize<'de> for Coercion
impl<'de> Deserialize<'de> for Coercion
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
impl Eq for Coercion
impl StructuralPartialEq for Coercion
Auto Trait Implementations§
impl Freeze for Coercion
impl RefUnwindSafe for Coercion
impl Send for Coercion
impl Sync for Coercion
impl Unpin for Coercion
impl UnsafeUnpin for Coercion
impl UnwindSafe for Coercion
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