pub struct HwKnowledgeGraph {
pub signals: Vec<KgSignal>,
pub properties: Vec<KgProperty>,
pub edges: Vec<KgEdge>,
pub entities: Vec<(String, HwEntityType)>,
pub typed_edges: Vec<(String, String, HwRelation)>,
}Expand description
Hardware Knowledge Graph — extracted from Kripke-lowered FOL.
Fields§
§signals: Vec<KgSignal>§properties: Vec<KgProperty>§edges: Vec<KgEdge>§entities: Vec<(String, HwEntityType)>Typed entities from the formal ontology (Sprint 0E).
typed_edges: Vec<(String, String, HwRelation)>Typed relations from the formal ontology (Sprint 0E).
Implementations§
Source§impl HwKnowledgeGraph
impl HwKnowledgeGraph
pub fn new() -> Self
pub fn add_entity(&mut self, name: impl Into<String>, entity: HwEntityType)
pub fn add_typed_edge( &mut self, from: impl Into<String>, to: impl Into<String>, relation: HwRelation, )
pub fn add_signal( &mut self, name: impl Into<String>, width: u32, role: SignalRole, )
pub fn add_property( &mut self, name: impl Into<String>, property_type: impl Into<String>, operator: impl Into<String>, )
pub fn add_edge( &mut self, from: impl Into<String>, to: impl Into<String>, relation: KgRelation, property: Option<String>, )
Trait Implementations§
Source§impl Clone for HwKnowledgeGraph
impl Clone for HwKnowledgeGraph
Source§fn clone(&self) -> HwKnowledgeGraph
fn clone(&self) -> HwKnowledgeGraph
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 HwKnowledgeGraph
impl Debug for HwKnowledgeGraph
Auto Trait Implementations§
impl Freeze for HwKnowledgeGraph
impl RefUnwindSafe for HwKnowledgeGraph
impl Send for HwKnowledgeGraph
impl Sync for HwKnowledgeGraph
impl Unpin for HwKnowledgeGraph
impl UnwindSafe for HwKnowledgeGraph
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