Package eu.bandm.tools.umod
Class Main
java.lang.Object
eu.bandm.tools.umod.Main
Class with the main entry methods, both by command line or
programmatically.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static MessagePrinter<SimpleMessage<@Opt XMLDocumentIdentifier>> Drain for all messages.protected static MessageCounterDrain for all messages.protected static MessageTee<SimpleMessage<@Opt XMLDocumentIdentifier>> Drain for all messages. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected static voidcheckErrors(String text) Exit the application when errors or failures have occured.static Stringprotected static voidSend a logging message to the standard drains.protected static voidSend a logging-start message to the standard drains.protected static voidSend a logging-start message to the standard drains.static voidMain entry point, called by the command line.static UMod.Foreststream2umod(UMod.Forest forest, InputStream str, String sourcefilename, MessageReceiver<SimpleMessage<@Opt XMLDocumentIdentifier>> msg) Main worker method, can be called from other classes.static UMod.Foreststream2umod(UMod.Forest forest, InputStream str, String sourcefilename, MessageReceiver<SimpleMessage<@Opt XMLDocumentIdentifier>> msg, ContentPrinter cp) Main worker method, can be called from other classes.
-
Field Details
-
msg_count
Drain for all messages. -
msg_interactive
Drain for all messages. -
mp_interactive
Drain for all messages.
-
-
Constructor Details
-
Main
public Main()
-
-
Method Details
-
stream2umod
@Opt public static UMod.Forest stream2umod(@Opt UMod.Forest forest, InputStream str, String sourcefilename, MessageReceiver<SimpleMessage<@Opt XMLDocumentIdentifier>> msg) Main worker method, can be called from other classes.- Parameters:
forest- incomplete meta-model to be completedstr- source text describing the umod meta-modelsourcefilename- to locate error messagesmsg- target of all messages
-
stream2umod
@Opt public static UMod.Forest stream2umod(@Opt UMod.Forest forest, InputStream str, String sourcefilename, MessageReceiver<SimpleMessage<@Opt XMLDocumentIdentifier>> msg, ContentPrinter cp) Main worker method, can be called from other classes.- Parameters:
forest- incomplete meta-model to be completedstr- source text describing the umod meta-modelsourcefilename- to locate error messagesmsg- target of all messagescp- additional diagnosis/debug parameter which prints the parsed source text
-
getVersionValue
-
log
Send a logging message to the standard drains.- Parameters:
s- the text of the message
-
logS
Send a logging-start message to the standard drains.- Parameters:
s- the text of the message
-
logE
Send a logging-start message to the standard drains.- Parameters:
s- the text of the message
-
checkErrors
Exit the application when errors or failures have occured.- Parameters:
text- to be printed to the terminal
-
main
Main entry point, called by the command line. Parses one or multiple input files into a meta-model, generates the Java source for the model elements and visitors, and generates documentation files.- Parameters:
args- the command line arguments.- Throws:
Exception
-