pub fn getflow<'a>(index: c_ulong) -> &'a mut Flow
Expand description
Returns the flow::Flow
structure of the flow with flow_index=index
.
Corresponds to Tranalyzer2 internal flows[index]
.
Example
use t2plugin::{getflow, HASHTABLE_ENTRY_NOT_FOUND};
use t2plugin::flow::Flow;
fn get_opposite_flow<'a>(flow: &'a Flow) -> Option<&'a mut Flow> {
match flow.opposite_flow_index {
HASHTABLE_ENTRY_NOT_FOUND => None,
index => Some(getflow(index)),
}
}