fern.network
Class NetworkLoader
java.lang.Object
fern.network.NetworkLoader
public class NetworkLoader
- extends Object
NetworkLoader
public NetworkLoader()
getAvailableTypes
public static String[][] getAvailableTypes()
- Gets types of networks that are readable by FERN. They are returned as String[N][2]
containing for N types a description and the file pattern.
- Returns:
- readable file types
readNetwork
public static Network readNetwork(File file)
throws IOException,
org.jdom.JDOMException,
FeatureNotSupportedException,
ClassNotFoundException
- Tries to read the given file and returns the network in it (if there is one)
- Parameters:
file
- network file
- Returns:
- network object
- Throws:
IOException
- file could not be found
org.jdom.JDOMException
- file could not be parsed correctly
FeatureNotSupportedException
- file contains a not supported sbml feature
ClassNotFoundException
- the class SBMLNetwork could not be found
addTypesToFileChooser
public static void addTypesToFileChooser(JFileChooser dialog)
- Adds available types of networks to a
JFileChooser
.
- Parameters:
dialog
- the JFileChooser