[−][src]Struct caminos_lib::topology::neighbourslists::NeighboursLists
A topology based on having sotred the list of neighbours to each router. It is used
- to load a topology from a file (topology=File)
- and to create a topology with random links (topology=RandomRegularGraph).
Implementations
impl NeighboursLists
[src]
pub fn new(
list: Vec<Vec<(usize, usize)>>,
servers: Vec<usize>
) -> NeighboursLists
[src]
list: Vec<Vec<(usize, usize)>>,
servers: Vec<usize>
) -> NeighboursLists
Build a topology with the given list of adjacency for routers and servers. list[i][j] = (r,p) with r the j-th neighbour router of the i-th router, where i is the p-th neighbour of r. servers[i] = amount of servers connected to the i-th router.
pub fn new_cfg(
cv: &ConfigurationValue,
rng: &RefCell<StdRng>
) -> NeighboursLists
[src]
cv: &ConfigurationValue,
rng: &RefCell<StdRng>
) -> NeighboursLists
Trait Implementations
impl Debug for NeighboursLists
[src]
impl Quantifiable for NeighboursLists
[src]
pub fn total_memory(&self) -> usize
[src]
pub fn print_memory_breakdown(&self)
[src]
pub fn forecast_total_memory(&self) -> usize
[src]
impl Topology for NeighboursLists
[src]
pub fn num_routers(&self) -> usize
[src]
pub fn num_servers(&self) -> usize
[src]
pub fn num_arcs(&self) -> usize
[src]
pub fn neighbour(&self, router_index: usize, port: usize) -> (Location, usize)
[src]
pub fn server_neighbour(&self, server_index: usize) -> (Location, usize)
[src]
pub fn diameter(&self) -> usize
[src]
pub fn average_distance(&self) -> f32
[src]
pub fn distance(&self, origin: usize, destination: usize) -> usize
[src]
pub fn amount_shortest_paths(&self, origin: usize, destination: usize) -> usize
[src]
pub fn average_amount_shortest_paths(&self) -> f32
[src]
pub fn distance_distribution(&self, _origin: usize) -> Vec<usize>
[src]
pub fn maximum_degree(&self) -> usize
[src]
pub fn minimum_degree(&self) -> usize
[src]
pub fn degree(&self, router_index: usize) -> usize
[src]
pub fn ports(&self, router_index: usize) -> usize
[src]
pub fn cartesian_data(&self) -> Option<&CartesianData>
[src]
pub fn coordinated_routing_record(
&self,
_coordinates_a: &Vec<usize>,
_coordinates_b: &Vec<usize>,
_rng: Option<&RefCell<StdRng>>
) -> Vec<i32>
[src]
&self,
_coordinates_a: &Vec<usize>,
_coordinates_b: &Vec<usize>,
_rng: Option<&RefCell<StdRng>>
) -> Vec<i32>
pub fn is_direction_change(
&self,
_router_index: usize,
_input_port: usize,
_output_port: usize
) -> bool
[src]
&self,
_router_index: usize,
_input_port: usize,
_output_port: usize
) -> bool
pub fn bfs(&self, origin: usize, class_weight: Option<&[usize]>) -> Vec<usize>
[src]
pub fn compute_distance_matrix(
&self,
class_weight: Option<&[usize]>
) -> Matrix<usize>
[src]
&self,
class_weight: Option<&[usize]>
) -> Matrix<usize>
pub fn floyd(&self) -> Matrix<usize>
[src]
pub fn compute_amount_shortest_paths(&self) -> (Matrix<usize>, Matrix<usize>)
[src]
pub fn components(&self, allowed_classes: &[bool]) -> Vec<Vec<usize>>
[src]
pub fn compute_near_far_matrices(&self) -> (Matrix<usize>, Matrix<usize>)
[src]
pub fn eccentricity(&self, router_index: usize) -> usize
[src]
pub fn check_adjacency_consistency(&self, amount_link_classes: Option<usize>)
[src]
Auto Trait Implementations
impl RefUnwindSafe for NeighboursLists
impl Send for NeighboursLists
impl Sync for NeighboursLists
impl Unpin for NeighboursLists
impl UnwindSafe for NeighboursLists
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,