JML

org.multijava.util.msggen
Class MessageDefinition

java.lang.Object
  extended byorg.multijava.util.msggen.MessageDefinition

class MessageDefinition
extends Object


Field Summary
private  String format
           
private  String identifier
           
private  int level
           
private  String reference
           
 
Constructor Summary
MessageDefinition(String identifier, String format, String reference, int level)
          Constructs a message definition
 
Method Summary
 void checkIdentifiers(Hashtable identifiers, String sourceFile)
          Checks for duplicate identifiers.
 void printInterface(PrintWriter out, 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
 

Field Detail

identifier

private final String identifier

format

private final String format

reference

private final String reference

level

private final int level
Constructor Detail

MessageDefinition

public MessageDefinition(String identifier,
                         String format,
                         String reference,
                         int level)
Constructs a message definition

Parameters:
identifier - the message identifier
format - the textual message format (with placeholders)
reference - the document describing the reason for this message
level - the severity level of this message
Method Detail

checkIdentifiers

public void checkIdentifiers(Hashtable identifiers,
                             String sourceFile)
                      throws MsggenError
Checks for duplicate identifiers.

Parameters:
identifiers - a table of all token identifiers
sourceFile - the file where the token is defined
Throws:
MsggenError

printInterface

public void printInterface(PrintWriter out,
                           String prefix)
Prints the token definition to interface file (java)

Parameters:
out - the output stream
prefix - the literal prefix

JML

JML is Copyright (C) 1998-2002 by Iowa State University and is distributed under the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This release depends on code from the MultiJava project and is based in part on the Kopi project Copyright (C) 1990-99 DMS Decision Management Systems Ges.m.b.H.