pub struct Mask32 { /* private fields */ }
Expand description

A 32-bit identifier mask.

Implementations

Creates a 32-bit identifier mask that accepts all frames.

This will accept both standard and extended data and remote frames with any ID.

Creates a 32-bit identifier mask that accepts all frames with the given extended ID and mask combination.

Filter logic: frame_accepted = (incoming_id & mask) == (id & mask)

A mask of all all ones (0x1FFF_FFFF) matches an exact ID, a mask of 0 matches all IDs.

Both data and remote frames with id will be accepted. Standard frames will be rejected.

Creates a 32-bit identifier mask that accepts all frames with the given standard ID and mask combination.

Filter logic: frame_accepted = (incoming_id & mask) == (id & mask)

A mask of all all ones (0x7FF) matches the exact ID, a mask of 0 matches all IDs.

Both data and remote frames with id will be accepted. Extended frames will be rejected.

Make the filter accept data frames only.

Make the filter accept remote frames only.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Converts to this type from the input type.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.