public class AnalysisBase extends Object
Network
implementing classes) and presents
methods for a general breath first search and depth first search, which can be controlled by a
NetworkSearchAction
NetworkSearchAction
Constructor and Description |
---|
AnalysisBase(Network network)
Creates an analysis instance.
|
Modifier and Type | Method and Description |
---|---|
int |
bfs(int[] speciesSource,
int[] reactionSource,
NetworkSearchAction action)
Performs a breath first search starting at the given sources (which means the contents of
speciesSource and reactionSource are the initial content of the
queue. |
int |
dfs(int[] speciesSource,
int[] reactionSource,
NetworkSearchAction action)
Performs a depth first search starting at the given sources (which means the contents of
speciesSource and reactionSource are the initial content of the
stack. |
int |
search(IntSearchStructure str,
int[] speciesSource,
int[] reactionSource,
NetworkSearchAction action)
Performs a search starting at the given sources (which means the contents of
speciesSource and reactionSource are the initial content of the
search structure IntSearchStructure . |
public AnalysisBase(Network network)
Network
is required. If the
network is a ModifierNetwork
, the original network is also discovered and stored.network
- the network for analysispublic int bfs(int[] speciesSource, int[] reactionSource, NetworkSearchAction action)
speciesSource
and reactionSource
are the initial content of the
queue. The search is controlled by an NetworkSearchAction
.speciesSource
- indices of the species to start withreactionSource
- indices of the reactions to start withaction
- controls what species/reactions have to be visited and what to do after
discovering/finishing a species/reactionpublic int dfs(int[] speciesSource, int[] reactionSource, NetworkSearchAction action)
speciesSource
and reactionSource
are the initial content of the
stack. The search is controlled by an NetworkSearchAction
.speciesSource
- indices of the species to start withreactionSource
- indices of the reactions to start withaction
- controls what species/reactions have to be visited and what to do after
discovering/finishing a species/reactionpublic int search(IntSearchStructure str, int[] speciesSource, int[] reactionSource, NetworkSearchAction action)
speciesSource
and reactionSource
are the initial content of the
search structure IntSearchStructure
. The search is controlled by an NetworkSearchAction
.str
- the search structure (fifo/lifo)speciesSource
- indices of the species to start withreactionSource
- indices of the reactions to start withaction
- controls what species/reactions have to be visited and what to do after
discovering/finishing a species/reactionbfs(int[], int[], NetworkSearchAction)
,
dfs(int[], int[], NetworkSearchAction)
Copyright © 2007–2021. All rights reserved.