use std::collections::HashMap;
use super::index::CsrIndex;
impl CsrIndex {
pub fn node_to_id_map(&self) -> &HashMap<String, u32> {
&self.node_to_id
}
pub fn id_to_node_list(&self) -> &[String] {
&self.id_to_node
}
pub fn label_to_id_map(&self) -> &HashMap<String, u16> {
&self.label_to_id
}
pub fn id_to_label_list(&self) -> &[String] {
&self.id_to_label
}
pub fn out_offsets_slice(&self) -> &[u32] {
&self.out_offsets
}
pub fn out_targets_slice(&self) -> &[u32] {
&self.out_targets
}
pub fn out_labels_slice(&self) -> &[u16] {
&self.out_labels
}
pub fn out_weights_slice(&self) -> Option<&[f64]> {
self.out_weights.as_deref()
}
pub fn in_offsets_slice(&self) -> &[u32] {
&self.in_offsets
}
pub fn in_targets_slice(&self) -> &[u32] {
&self.in_targets
}
pub fn in_labels_slice(&self) -> &[u16] {
&self.in_labels
}
pub fn in_weights_slice(&self) -> Option<&[f64]> {
self.in_weights.as_deref()
}
}