|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdatabionics.io.BaseFile
databionics.io.ListFile
databionics.io.MapFile
public abstract class MapFile
Base class for files with lists that need fast access by index. This is done by an additional Map.
| Field Summary | |
|---|---|
protected static org.apache.log4j.Logger |
log
Log4j logging. |
protected java.util.Map |
map
Hashtable with data. |
| Fields inherited from class databionics.io.ListFile |
|---|
data |
| Fields inherited from class databionics.io.BaseFile |
|---|
allowEmptyLines, comment, commentPrefix, delimiter, delimiters, file, header, headerPrefix, loc, nf |
| Constructor Summary | |
|---|---|
MapFile()
Standard constructor |
|
MapFile(java.lang.String filename)
Constructor with a filename |
|
| Method Summary | |
|---|---|
void |
add(DataItem item)
Add item to list and map. |
java.util.Map |
getMap()
Get the data in the map. |
void |
remove(DataItem item)
Remove item from list and map. |
void |
remove(int index)
Remove item by index from list and map. |
void |
setData(java.util.List data)
Change the data in the list and the map. |
void |
setMap(java.util.Map map)
Change the data in the map and the list. |
| Methods inherited from class databionics.io.ListFile |
|---|
buildLine, getData, getSize |
| Methods inherited from class databionics.io.BaseFile |
|---|
buildHeader, checkHeader, checkHeaderAgainstSize, getComment, getFile, getFilename, getHeader, getLocale, getNumberFormat, init, isHeader, isNaN, isNumber, load, load, parseError, parseHeader, parseLine, save, save, setComment, setFilename, setLocale, writeStringList, writeStringList |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static org.apache.log4j.Logger log
protected java.util.Map map
| Constructor Detail |
|---|
public MapFile()
public MapFile(java.lang.String filename)
filename - Name of the file| Method Detail |
|---|
public java.util.Map getMap()
public void setMap(java.util.Map map)
map - Map with the data itemspublic void setData(java.util.List data)
setData in class ListFiledata - List with the data itemspublic void remove(DataItem item)
item - Item to removepublic void remove(int index)
index - Index field of itempublic void add(DataItem item)
index - Item to add
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||