Function il2_iltags::tags::tag_downcast_ref_with_id [−][src]
pub fn tag_downcast_ref_with_id<T: ILTag>(
tag_id: u64,
tag: &dyn ILTag
) -> Option<&T>
Expand description
Downcasts a ILTag
into a reference to its concrete type it if matches
the specified tag Id.
Arguments:
tag_id
: The expected tag Id;tag
: The tag to be downcast;
Returns: An option with a reference to the concrete type or None if the conversion is not possible or the tag id does not match.