pub struct TagManager {
pub cache: RwLock<HashMap<String, TagMetadata>>,
/* private fields */
}
Expand description
Manager for PLC tag discovery and caching
Fields§
§cache: RwLock<HashMap<String, TagMetadata>>
Implementations§
Source§impl TagManager
impl TagManager
pub fn new() -> Self
pub async fn get_metadata(&self, tag_name: &str) -> Option<TagMetadata>
pub async fn update_metadata(&self, tag_name: String, metadata: TagMetadata)
pub async fn validate_tag( &self, tag_name: &str, required_permissions: &TagPermissions, ) -> Result<()>
pub async fn clear_cache(&self)
pub async fn remove_stale_entries(&self)
pub fn parse_tag_list( &self, response: &[u8], ) -> Result<Vec<(String, TagMetadata)>>
Trait Implementations§
Source§impl Debug for TagManager
impl Debug for TagManager
Auto Trait Implementations§
impl !Freeze for TagManager
impl RefUnwindSafe for TagManager
impl Send for TagManager
impl Sync for TagManager
impl Unpin for TagManager
impl UnwindSafe for TagManager
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