at.dms.msggen
Class MessageDefinition

java.lang.Object
  |
  +--at.dms.msggen.MessageDefinition

class MessageDefinition
extends java.lang.Object

A parsed definition of a compiler message.


Constructor Summary
MessageDefinition(java.lang.String identifier, java.lang.String format, java.lang.String jlsReference, int level)
          Constructs a message definition.
 
Method Summary
 void checkIdentifiers(java.util.Map identifiers, java.lang.String sourceFile)
          Checks for duplicate identifiers.
 void printInterface(java.io.PrintWriter out, java.lang.String prefix)
          Prints the token definition to interface file (java)
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MessageDefinition

public MessageDefinition(java.lang.String identifier,
                         java.lang.String format,
                         java.lang.String jlsReference,
                         int level)
Constructs a message definition.
Parameters:
identifier - The java identifier that is used by the compiler to refer to this message.
format - The textual message format (with placeholders)
jlsReference - The document describing the reason for this message
level - The severity level of this message
Method Detail

checkIdentifiers

public void checkIdentifiers(java.util.Map identifiers,
                             java.lang.String sourceFile)
                      throws MsggenError
Checks for duplicate identifiers.
Parameters:
identifiers - a table of all token identifiers
prefix - the literal prefix
id - the id of the token
sourceFile - the file where the token is defined

printInterface

public void printInterface(java.io.PrintWriter out,
                           java.lang.String prefix)
Prints the token definition to interface file (java)
Parameters:
out - the output stream
prefix - the literal prefix