some minor changes
Borrowed the FlowInspector class from package no.uib.ii.algo.st8.algorithms. Needs to be modified for our application.