Skip to main content

EntryChanged

Struct EntryChanged 

Source
pub struct EntryChanged<const S: usize, const T: usize> {
    pub admin_node_id: Option<NodeId>,
    pub admin_passcode_id: Option<u16>,
    pub change_type: ChangeType,
    pub latest_value: Option<Entry<S, T>>,
    pub fabric_index: FabricIndex,
}
Expand description

What one change to the ACL attribute should be recorded as (§9.10.9.1).

The server “SHALL generate AccessControlEntryChanged events whenever its ACL attribute data is changed by an Administrator”, and the event names who: “Exactly one of AdminNodeID and AdminPasscodeID SHALL be set, depending on whether the change occurred via a CASE or PASE session”. Reported rather than logged here, because §7.14’s event store is the device’s and this cluster does not own one.

Fields§

§admin_node_id: Option<NodeId>

The administrator’s node id, when the change came over CASE.

§admin_passcode_id: Option<u16>

The passcode id, when it came over PASE. Always Some(0) in practice: “Non-zero values are reserved for future use”.

§change_type: ChangeType

What happened.

§latest_value: Option<Entry<S, T>>

LatestValue [4] — “The latest value of the changed entry”, which for a removal is the entry as it stood when it was removed.

None is the field’s null, which §9.10.9.1 permits only as a concession: “This field SHOULD be set if resources are adequate for it; otherwise it SHALL be set to NULL if resources are scarce.” An audit trail of when the list changed and never to what is most of the way to no audit trail, so this carries the entry wherever one is available.

§fabric_index: FabricIndex

The fabric whose list changed.

Implementations§

Source§

impl<const S: usize, const T: usize> EntryChanged<S, T>

Source

pub fn for_session( ctx: &InteractionContext<'_>, change_type: ChangeType, latest_value: Option<Entry<S, T>>, ) -> Self

The record for a change made on ctx’s session.

Source

pub fn for_fabric(self, fabric_index: FabricIndex) -> Self

The same record, attributed to a fabric the session does not yet carry.

§11.18.6.8 step 7 adds the administrator entry for a fabric during AddNOC, over a PASE session whose accessing fabric is bound only at step 10a — so at the moment of the change ctx.fabric_index is still none, and the event would be attributed to fabric 0 and visible to nobody. §7.14.4 makes a fabric-sensitive event readable only by its own fabric, which for this one means the fabric it just created.

Source

pub fn encode(&self, w: &mut TlvWriter<'_>, tag: Tag) -> Result<()>

Writes the event’s fields (§9.10.9.1).

Trait Implementations§

Source§

impl<const S: usize, const T: usize> Clone for EntryChanged<S, T>

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<const S: usize, const T: usize> Debug for EntryChanged<S, T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<const S: usize, const T: usize> Eq for EntryChanged<S, T>

Source§

impl<const S: usize, const T: usize> PartialEq for EntryChanged<S, T>

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl<const S: usize, const T: usize> StructuralPartialEq for EntryChanged<S, T>

Auto Trait Implementations§

§

impl<const S: usize, const T: usize> Forget for EntryChanged<S, T>

§

impl<const S: usize, const T: usize> Freeze for EntryChanged<S, T>
where Option<Entry<S, T>>: Freeze,

§

impl<const S: usize, const T: usize> Move for EntryChanged<S, T>

§

impl<const S: usize, const T: usize> RefUnwindSafe for EntryChanged<S, T>
where Option<Entry<S, T>>: RefUnwindSafe,

§

impl<const S: usize, const T: usize> Send for EntryChanged<S, T>
where Option<Entry<S, T>>: Send,

§

impl<const S: usize, const T: usize> Sync for EntryChanged<S, T>
where Option<Entry<S, T>>: Sync,

§

impl<const S: usize, const T: usize> Unpin for EntryChanged<S, T>
where Option<Entry<S, T>>: Unpin,

§

impl<const S: usize, const T: usize> UnsafeUnpin for EntryChanged<S, T>
where Option<Entry<S, T>>: UnsafeUnpin,

§

impl<const S: usize, const T: usize> UnwindSafe for EntryChanged<S, T>
where Option<Entry<S, T>>: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

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

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.