pub struct PadmetSpec {
pub dic_of_relations_in: HashMap<String, Vec<Relation>>,
pub dic_of_relations_out: HashMap<String, Vec<Relation>>,
pub dic_of_nodes: HashMap<String, Node>,
pub policy: Policy,
pub info: HashMap<String, HashMap<String, String>>,
}Fields§
§dic_of_relations_in: HashMap<String, Vec<Relation>>§dic_of_relations_out: HashMap<String, Vec<Relation>>§dic_of_nodes: HashMap<String, Node>§policy: Policy§info: HashMap<String, HashMap<String, String>>Implementations§
Source§impl PadmetSpec
impl PadmetSpec
pub fn new( dic_of_relations_in: HashMap<String, Vec<Relation>>, dic_of_relations_out: HashMap<String, Vec<Relation>>, dic_of_nodes: HashMap<String, Node>, policy: Policy, info: HashMap<String, HashMap<String, String>>, ) -> Self
pub fn from_file<P>(filename: P) -> Result<PadmetSpec>
Sourcepub fn get_all_relations(&self) -> Vec<Relation>
pub fn get_all_relations(&self) -> Vec<Relation>
Get a set of all relations in the padmet object
Sourcepub fn get_relations_type_id_in(
&self,
relation_type: &String,
relation_id_in: &String,
) -> Vec<Relation>
pub fn get_relations_type_id_in( &self, relation_type: &String, relation_id_in: &String, ) -> Vec<Relation>
Get the list of relations of a certain type, coming from a certain node
Sourcepub fn get_relations_type_id_out(
&self,
relation_type: &String,
relation_id_out: &String,
) -> Vec<Relation>
pub fn get_relations_type_id_out( &self, relation_type: &String, relation_id_out: &String, ) -> Vec<Relation>
Get the list of relations of a certain type, leading to a certain node
Sourcepub fn get_relations(
self,
relation_id_in: &String,
relation_type: &String,
relation_id_out: &String,
) -> Vec<Relation>
pub fn get_relations( self, relation_id_in: &String, relation_type: &String, relation_id_out: &String, ) -> Vec<Relation>
Get relation from relation_id_in to relation_id_out nodes and with a specific relation_type
pub fn get_nodes_of_type(&self, node_type: &str) -> Vec<Node>
Sourcepub fn get_compounds(&self) -> Vec<Node>
pub fn get_compounds(&self) -> Vec<Node>
Get all the compounds from a padmet instance.
Sourcepub fn get_reactions(&self) -> Vec<Node>
pub fn get_reactions(&self) -> Vec<Node>
Get all the reactions from a padmet instance
Sourcepub fn get_pathways(&self) -> Vec<Node>
pub fn get_pathways(&self) -> Vec<Node>
Get all the pathways from a padmet instance
Trait Implementations§
Source§impl Clone for PadmetSpec
impl Clone for PadmetSpec
Source§fn clone(&self) -> PadmetSpec
fn clone(&self) -> PadmetSpec
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 moreAuto Trait Implementations§
impl Freeze for PadmetSpec
impl RefUnwindSafe for PadmetSpec
impl Send for PadmetSpec
impl Sync for PadmetSpec
impl Unpin for PadmetSpec
impl UnwindSafe for PadmetSpec
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