## org.codehaus.groovy.control.messages
Class Message

    java.lang.Object
      org.codehaus.groovy.control.messages.Message

Direct Known Subclasses:
  ExceptionMessage, SimpleMessage, SyntaxErrorMessage

    public abstract class Message

extends Object

A base class for compilation messages.

Version:
  $Id: Message.java 6778 2007-07-02 10:40:33Z glaforge $
Author:
  Chris Poirier

Constructor Summary
`Message()`

Method Summary
`static Message` `create(String text, Object data, ProcessingUnit owner)` Creates a new Message from the specified text.
`static Message` `create(String text, ProcessingUnit owner)` Creates a new Message from the specified text.
`static Message` `create(SyntaxException error, SourceUnit owner)` Creates a new Message from the specified SyntaxException.
`void` `write(PrintWriter writer)` A synonyn for write( writer, owner, null ).
`abstract void` `write(PrintWriter writer, Janitor janitor)` Writes the message to the specified PrintWriter.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### Message

    public Message()

Method Detail

### write

    public abstract void write(PrintWriter writer,
                               Janitor janitor)

  Writes the message to the specified PrintWriter. The supplied ProcessingUnit is the unit that holds this Message.

### write

    public final void write(PrintWriter writer)

  A synonyn for write( writer, owner, null ).

### create

    public static Message create(String text,
                                 ProcessingUnit owner)

  Creates a new Message from the specified text.

### create

    public static Message create(String text,
                                 Object data,
                                 ProcessingUnit owner)

  Creates a new Message from the specified text.

### create

    public static Message create(SyntaxException error,
                                 SourceUnit owner)

  Creates a new Message from the specified SyntaxException.

Copyright © 2003-2008 The Codehaus. All rights reserved.