pub struct DomainAgentRegistry {
pub agents: HashMap<String, DomainAgentMetadata>,
pub knowledge_bases: HashMap<String, String>,
}Expand description
Domain agent registry entry
Fields§
§agents: HashMap<String, DomainAgentMetadata>Registered agents by domain
knowledge_bases: HashMap<String, String>Knowledge bases by domain
Implementations§
Source§impl DomainAgentRegistry
impl DomainAgentRegistry
Sourcepub fn register_agent(&mut self, domain: &str, metadata: DomainAgentMetadata)
pub fn register_agent(&mut self, domain: &str, metadata: DomainAgentMetadata)
Register an agent
Sourcepub fn register_knowledge_base(&mut self, domain: &str, path: String)
pub fn register_knowledge_base(&mut self, domain: &str, path: String)
Register a knowledge base
Sourcepub fn get_agent(&self, domain: &str) -> Option<&DomainAgentMetadata>
pub fn get_agent(&self, domain: &str) -> Option<&DomainAgentMetadata>
Get agent for domain
Sourcepub fn get_knowledge_base(&self, domain: &str) -> Option<&str>
pub fn get_knowledge_base(&self, domain: &str) -> Option<&str>
Get knowledge base path for domain
Trait Implementations§
Source§impl Clone for DomainAgentRegistry
impl Clone for DomainAgentRegistry
Source§fn clone(&self) -> DomainAgentRegistry
fn clone(&self) -> DomainAgentRegistry
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DomainAgentRegistry
impl Debug for DomainAgentRegistry
Source§impl Default for DomainAgentRegistry
impl Default for DomainAgentRegistry
Source§impl<'de> Deserialize<'de> for DomainAgentRegistry
impl<'de> Deserialize<'de> for DomainAgentRegistry
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
Auto Trait Implementations§
impl Freeze for DomainAgentRegistry
impl RefUnwindSafe for DomainAgentRegistry
impl Send for DomainAgentRegistry
impl Sync for DomainAgentRegistry
impl Unpin for DomainAgentRegistry
impl UnwindSafe for DomainAgentRegistry
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