com.sun.tools.apt.mirror.apt
Class MessagerImpl

java.lang.Object
  extended by com.sun.tools.apt.mirror.apt.MessagerImpl
All Implemented Interfaces:
Messager

public class MessagerImpl
extends java.lang.Object
implements Messager

Implementation of Messager.


Field Summary
private  Bark bark
           
private static Context.Key<MessagerImpl> messagerKey
           
 
Constructor Summary
private MessagerImpl(Context context)
           
 
Method Summary
static MessagerImpl instance(Context context)
           
 void printError(SourcePosition pos, java.lang.String msg)
          Prints an error message.
 void printError(java.lang.String msg)
          Prints an error message.
 void printNotice(SourcePosition pos, java.lang.String msg)
          Prints a notice.
 void printNotice(java.lang.String msg)
          Prints a notice.
 void printWarning(SourcePosition pos, java.lang.String msg)
          Prints a warning message.
 void printWarning(java.lang.String msg)
          Prints a warning message.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

bark

private final Bark bark

messagerKey

private static final Context.Key<MessagerImpl> messagerKey
Constructor Detail

MessagerImpl

private MessagerImpl(Context context)
Method Detail

instance

public static MessagerImpl instance(Context context)

printError

public void printError(java.lang.String msg)
Prints an error message. Equivalent to printError(null, msg).

Specified by:
printError in interface Messager
Parameters:
msg - the message, or an empty string if none

printError

public void printError(SourcePosition pos,
                       java.lang.String msg)
Prints an error message.

Specified by:
printError in interface Messager
Parameters:
pos - the position where the error occured, or null if it is unknown or not applicable
msg - the message, or an empty string if none

printWarning

public void printWarning(java.lang.String msg)
Prints a warning message. Equivalent to printWarning(null, msg).

Specified by:
printWarning in interface Messager
Parameters:
msg - the message, or an empty string if none

printWarning

public void printWarning(SourcePosition pos,
                         java.lang.String msg)
Prints a warning message.

Specified by:
printWarning in interface Messager
Parameters:
pos - the position where the warning occured, or null if it is unknown or not applicable
msg - the message, or an empty string if none

printNotice

public void printNotice(java.lang.String msg)
Prints a notice. Equivalent to printNotice(null, msg).

Specified by:
printNotice in interface Messager
Parameters:
msg - the message, or an empty string if none

printNotice

public void printNotice(SourcePosition pos,
                        java.lang.String msg)
Prints a notice.

Specified by:
printNotice in interface Messager
Parameters:
pos - the position where the noticed occured, or null if it is unknown or not applicable
msg - the message, or an empty string if none