pub struct Registry { /* private fields */ }Implementations§
Source§impl Registry
impl Registry
pub fn open(path: impl AsRef<Path>) -> Self
pub fn register(&self, entry: RegistryEntry) -> Result<(), String>
pub fn lookup(&self, name: &str) -> Option<RegistryEntry>
pub fn by_capability(&self, cap: &str) -> Vec<RegistryEntry>
pub fn list(&self) -> Vec<RegistryEntry>
pub fn unregister(&self, name: &str) -> Result<bool, String>
Sourcepub fn entry_from_card(card: &AgentCard) -> RegistryEntry
pub fn entry_from_card(card: &AgentCard) -> RegistryEntry
Build a registry entry from a signed AgentCard (§7). The card is the source of truth: name, endpoint (as aid), capabilities, public key.
Sourcepub fn register_card(&self, card: &AgentCard) -> Result<(), String>
pub fn register_card(&self, card: &AgentCard) -> Result<(), String>
Register an agent directly from its AgentCard (replaces by name).
Sourcepub fn discover_cards(&self, cap: &str) -> Vec<AgentCard>
pub fn discover_cards(&self, cap: &str) -> Vec<AgentCard>
Discovery: agents with a capability, returned as best-effort AgentCards reconstructed from the registry (public key restored when present; signature NOT carried — verify at contact time).
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Registry
impl RefUnwindSafe for Registry
impl Send for Registry
impl Sync for Registry
impl Unpin for Registry
impl UnsafeUnpin for Registry
impl UnwindSafe for Registry
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