fr.inria.opengve.bridge.interfaces
Interface MultiFlow<V,A extends Arc<V>>


public interface MultiFlow<V,A extends Arc<V>>

This interface is used to manage multi-flow. This multi-flow is build by adding various Flow to this one.

Author:
fabrice.peix@sophia.inria.fr

Method Summary
 void addFlow(Flow<V,A> f)
          Add a given flow to this multi-flow.
 java.util.Iterator<V> destinationIterator()
          Give an iterator on the destination vertex of this multi-flow.
 java.util.Iterator<A> edgeWithFlowIterator()
          Give a Iterator on all edges with a flow not null.
 AbstractScalar getFlow(A e)
          Give the quantity of flow associated with an edge.
 Flow<V,A> getFlow(V source, V destination)
          Return the flow between two vertices.
 AbstractScalar getIncomingFlow(V v)
          Return the quantity of flow incoming to vertex v.
 AbstractScalar getOutgoingFlow(V v)
          Return the quantity of flow outgoing from vertex v.
 Graph<V,A> getSupportingGraph()
          Give the supporting graph associated with this flow.
 java.util.Iterator<V> sourceIterator()
          Give an iterator on the source vertex of this multi-flow.
 boolean verify()
          Verify the coherence of the flow.
 

Method Detail

addFlow

void addFlow(Flow<V,A> f)
Add a given flow to this multi-flow.

Parameters:
f - The flow to add.

sourceIterator

java.util.Iterator<V> sourceIterator()
Give an iterator on the source vertex of this multi-flow.

Returns:
An iterator on source of this flow.

destinationIterator

java.util.Iterator<V> destinationIterator()
Give an iterator on the destination vertex of this multi-flow.

Returns:
An iterator on destination of this flow.

getIncomingFlow

AbstractScalar getIncomingFlow(V v)
Return the quantity of flow incoming to vertex v.

Parameters:
v - The vertex.
Returns:
A value representing the quantity of flow entering from v.

getOutgoingFlow

AbstractScalar getOutgoingFlow(V v)
Return the quantity of flow outgoing from vertex v.

Parameters:
v - The vertex.
Returns:
A value representing the quantity of flow outgoing from v.

getFlow

AbstractScalar getFlow(A e)
Give the quantity of flow associated with an edge.

Parameters:
e - The edge.
Returns:
The quantity of flow associated with the edge e.

getFlow

Flow<V,A> getFlow(V source,
                  V destination)
Return the flow between two vertices.

Parameters:
source - The source of the flow
destination - The destination of the flow
Returns:
The flow between the two vertices or null if no flow is define between this two vertices.

edgeWithFlowIterator

java.util.Iterator<A> edgeWithFlowIterator()
Give a Iterator on all edges with a flow not null.

Returns:
A Iterator over edges with flow.

getSupportingGraph

Graph<V,A> getSupportingGraph()
Give the supporting graph associated with this flow.

Returns:
The supporting graph associated with this flow.

verify

boolean verify()
Verify the coherence of the flow. The exact implementation of this method is not define, each implementatiom of MultiFlow must define exactly what this method do.

Returns:
true if this flow is coherent with verifications and false otherwise.


Copyright © 2009 INRIA (Projet Mascotte). All Rights Reserved.