|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuchicago.src.sim.analysis.DataFileHeader
public class DataFileHeader
Given a model and this will create the appropriate header for any data file. For batch runs, constant parameters will be in one header (the true header), and dynamic parameters will be in a block header and reflect the parameter value at that time. Also, the user has an option to provide their own custom header. Note: the actual parameter values in the file header are created via the call to getFileHeader(). For DataRecorder's this call is made in the DataRecorder's constructor. Consequently, any changes to model parameter's made after this call are not reflected in the file header.
| Field Summary | |
|---|---|
static java.lang.String |
WRITE_HEADER
|
| Constructor Summary | |
|---|---|
DataFileHeader()
This should only be used for testing various Recorders that use DataFileHeader but don't need to create a model. |
|
DataFileHeader(SimModel model)
|
|
DataFileHeader(java.lang.String modelHeader)
Constructor which allows users to specify their own custom header. |
|
| Method Summary | |
|---|---|
void |
addHeaderComment(java.lang.String comment)
Prepends a comment to the usual file header. |
boolean |
doWriteHeader(java.lang.String fileName)
Should the header be written to the specified file during this run? |
java.lang.String |
getBlockHeader()
Gets the block header. |
java.lang.String |
getBlockHeaderAsComments()
Gets the block header. |
java.util.Hashtable |
getDynParamMethod()
|
java.lang.String |
getFileHeader()
Gets the true file header. |
java.lang.Object |
getPersistentObj(java.lang.Object key)
Gets a persistent object. |
boolean |
isBatch()
Is this DataFileHeader part of a batch run. |
void |
putPersistentObj(java.lang.Object key,
java.lang.Object val)
Puts an object in the persistent store. |
void |
setWriteHeader(java.lang.String fileName,
boolean val)
Sets whether the header should be written to the file. |
| 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 WRITE_HEADER
| Constructor Detail |
|---|
public DataFileHeader()
public DataFileHeader(java.lang.String modelHeader)
modelHeader - - user provided header.public DataFileHeader(SimModel model)
| Method Detail |
|---|
public void addHeaderComment(java.lang.String comment)
comment - the comment to prependpublic java.lang.String getFileHeader()
public java.lang.String getBlockHeader()
public java.lang.String getBlockHeaderAsComments()
public boolean isBatch()
public boolean doWriteHeader(java.lang.String fileName)
fileName - the fileName for this header.
public void setWriteHeader(java.lang.String fileName,
boolean val)
fileName - the fileName associated with this headerval - whether the header should be written to the specified file.doWriteHeader(String)
public void putPersistentObj(java.lang.Object key,
java.lang.Object val)
key - the key for the persistent objectval - the object to persist.public java.lang.Object getPersistentObj(java.lang.Object key)
key - the key for this object to getpublic java.util.Hashtable getDynParamMethod()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||