|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.swfm.mica.model.MiModelEntity
com.swfm.mica.view.MiModelIOFormatManager
This class implements the MiiModelIOFormatManager interface. It reads and writes MiiModelDocuments to and from Streams. The format of the stream is lines of ASCII text, each line a seperate entity. If the first character of a line is a '#' or a '!' it is considered a comment. Entities are assumed to be sequences of name/value pairs. For example: "name = entity1, color = red, type = node"
| Field Summary |
| Constructor Summary | |
MiModelIOFormatManager()
Constructs a new MiModelIOFormatManager. |
|
| Method Summary | |
MiiModelDocument |
load(java.io.InputStream inputStream,
java.lang.String streamName)
Creates, loads contents (the entities of type MiModelEntity) of, and returns a new MiiModelDocument from the given Stream. |
static MiModelEntity |
makeModelEntityFromString(java.lang.String str,
java.lang.String streamName,
int lineNumber)
Creates a MiModelEntity from the given line of text. |
static java.lang.String |
makeStringFromModelEntity(MiiModelEntity entity)
Creates a String describing the given MiiModelEntity. |
static void |
postProcessesContainersAndConnections(MiiModelEntity document,
boolean createNodesAtEndsOfDanglingReferences)
|
void |
save(MiiModelEntity document,
java.io.OutputStream outputStream,
java.lang.String header)
Saves the contents (the entities of type MiModelEntity) of the given document to the given Stream. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public MiModelIOFormatManager()
| Method Detail |
public MiiModelDocument load(java.io.InputStream inputStream,
java.lang.String streamName)
throws java.io.IOException
load in interface MiiModelIOFormatManagerinputStream - the source of the data from which
the document contents will be
built.streamName - The name of the stream to be used
for error messages
java.io.IOException
public void save(MiiModelEntity document,
java.io.OutputStream outputStream,
java.lang.String header)
save in interface MiiModelIOFormatManagerdocument - The document to saveoutputStream - the destination of the data built
from the document contents.header - The first line output that identifies
the format of the data
public static MiModelEntity makeModelEntityFromString(java.lang.String str,
java.lang.String streamName,
int lineNumber)
str - the text describing the entitystreamName - the name of the source of the
text to be used for error messageslineNumber - the line number of the entity
public static java.lang.String makeStringFromModelEntity(MiiModelEntity entity)
entity - the entity to convert to text.
public static void postProcessesContainersAndConnections(MiiModelEntity document,
boolean createNodesAtEndsOfDanglingReferences)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||