|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectat.tuwien.ifs.somtoolbox.input.AbstractSOMInputReader
at.tuwien.ifs.somtoolbox.input.SOMLibFormatInputReader
public class SOMLibFormatInputReader
Provides the functionality to read a saved network model in SOMLib format.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class at.tuwien.ifs.somtoolbox.input.AbstractSOMInputReader |
---|
AbstractSOMInputReader.UnitInformation |
Field Summary | |
---|---|
private java.lang.String |
mapDescriptionFileName
|
static java.lang.String |
mapFileNameSuffix
The suffix of the map description files |
private java.lang.String |
unitDescriptionFileName
|
static java.lang.String |
unitFileNameSuffix
The suffix of the unit description files |
static java.lang.String |
weightFileNameSuffix
The suffix of the weight vector files |
private java.lang.String |
weightVectorFileName
|
Fields inherited from class at.tuwien.ifs.somtoolbox.input.AbstractSOMInputReader |
---|
allVectorNames, commonLabelPrefix, contentType, dim, gridLayout, gridTopology, labelled, metricName, unitInfo, xSize, ySize, zSize |
Fields inherited from interface at.tuwien.ifs.somtoolbox.input.SOMInputReader |
---|
MAP_FILE, UNIT_FILE, WEIGHT_VECTOR |
Constructor Summary | |
---|---|
SOMLibFormatInputReader(java.lang.String weightVectorFileName,
java.lang.String unitDescriptionFileName,
java.lang.String mapDescriptionFileName)
Sole constructor taking the name of the weight vector file, the unit description file and the map description file as arguments. |
Method Summary | |
---|---|
java.lang.String |
getFilePath()
Returns the name of the path where the files are located. |
static java.lang.String |
getFormatName()
|
java.lang.String |
getMapDescriptionFileName()
Returns the name of the map description file, or null if not loaded. |
java.lang.String |
getUnitDescriptionFileName()
Returns the name of the unit description file, or null if not loaded. |
java.lang.String |
getWeightVectorFileName()
Returns the name of the weight vector file, or null if not loaded. |
protected void |
processUnitElement(java.lang.String line,
int k,
int j,
int i)
|
protected void |
readMapDescriptionFile(java.lang.String fileName)
Reads a SOMLib map description file with the given name. |
protected void |
readUnitDescriptionFile(java.lang.String fileName)
Reads a SOMLib unit description file with the given name. |
private void |
readWeightVectorFile(java.lang.String fileName)
Reads a SOMLib weight vector file with the given name. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String mapFileNameSuffix
public static final java.lang.String weightFileNameSuffix
public static final java.lang.String unitFileNameSuffix
private java.lang.String mapDescriptionFileName
private java.lang.String unitDescriptionFileName
private java.lang.String weightVectorFileName
Constructor Detail |
---|
public SOMLibFormatInputReader(java.lang.String weightVectorFileName, java.lang.String unitDescriptionFileName, java.lang.String mapDescriptionFileName) throws java.io.FileNotFoundException, SOMLibFileFormatException
weightVectorFileName
- the name of the weight vector file.unitDescriptionFileName
- the name of the unit description file.mapDescriptionFileName
- the name of the map description file.
java.io.FileNotFoundException
- if one of the files with the given name is not found.
SOMLibFileFormatException
- if the format of one of the file is corrupt.Method Detail |
---|
public java.lang.String getFilePath()
SOMInputReader
SOMInputReader.getFilePath()
public java.lang.String getMapDescriptionFileName()
SOMInputReader
public java.lang.String getUnitDescriptionFileName()
SOMInputReader
null
if not loaded.
null
if not loaded.public java.lang.String getWeightVectorFileName()
SOMInputReader
null
if not loaded.
null
if not loaded.protected void readMapDescriptionFile(java.lang.String fileName) throws java.io.FileNotFoundException, SOMLibFileFormatException
fileName
- the name of the file to open.
java.io.FileNotFoundException
SOMLibFileFormatException
protected void readUnitDescriptionFile(java.lang.String fileName) throws java.io.FileNotFoundException, SOMLibFileFormatException
fileName
- the name of the file to open.
java.io.FileNotFoundException
SOMLibFileFormatException
private void readWeightVectorFile(java.lang.String fileName) throws java.io.FileNotFoundException, SOMLibFileFormatException
fileName
- the name of the file to open.
java.io.FileNotFoundException
SOMLibFileFormatException
protected void processUnitElement(java.lang.String line, int k, int j, int i)
public static java.lang.String getFormatName()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |