Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## groovy.io
Class GroovyPrintWriter

    java.lang.Object
      java.io.Writer
          java.io.PrintWriter
              groovy.io.GroovyPrintWriter

All Implemented Interfaces:
  Closeable, Flushable, Appendable

    public class GroovyPrintWriter

extends PrintWriter

A PrintWriter that outputs objects in Groovy style. That means print(Object) uses InvokerHelper.toString(Object) to produce the same results as Writer.print(Object).

Since:
  1.6
Author:
  Jim White

Field Summary

Fields inherited from class java.io.PrintWriter
`out`

Fields inherited from class java.io.Writer
`lock`

Constructor Summary
`GroovyPrintWriter(File file)`
`GroovyPrintWriter(File file, String csn)`
`GroovyPrintWriter(OutputStream out)`
`GroovyPrintWriter(OutputStream out, boolean autoflush)`
`GroovyPrintWriter(String filename)`
`GroovyPrintWriter(String filename, String csn)`
`GroovyPrintWriter(Writer out)`
`GroovyPrintWriter(Writer out, boolean autoflush)`

Method Summary
`void` | `print(Object x)`
`void` | `println(Object x)`

Methods inherited from class java.io.PrintWriter
`append, append, append, checkError, clearError, close, flush, format, format, print, print, print, print, print, print, print, print, printf, printf, println, println, println, println, println, println, println, println, println, setError, write, write, write, write, write`

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

Constructor Detail

### GroovyPrintWriter

    public GroovyPrintWriter(File file)
                      throws FileNotFoundException

Throws:
  `FileNotFoundException`

### GroovyPrintWriter

    public GroovyPrintWriter(File file,
                             String csn)
                      throws FileNotFoundException,
                             UnsupportedEncodingException

Throws:
  `FileNotFoundException`
  `UnsupportedEncodingException`

### GroovyPrintWriter

    public GroovyPrintWriter(Writer out)

### GroovyPrintWriter

    public GroovyPrintWriter(Writer out,
                             boolean autoflush)

### GroovyPrintWriter

    public GroovyPrintWriter(OutputStream out)

### GroovyPrintWriter

    public GroovyPrintWriter(OutputStream out,
                             boolean autoflush)

### GroovyPrintWriter

    public GroovyPrintWriter(String filename)
                      throws FileNotFoundException

Throws:
  `FileNotFoundException`

### GroovyPrintWriter

    public GroovyPrintWriter(String filename,
                             String csn)
                      throws FileNotFoundException,
                             UnsupportedEncodingException

Throws:
  `FileNotFoundException`
  `UnsupportedEncodingException`

Method Detail

### print

    public void print(Object x)

  Overrides:
    `print` in class `PrintWriter`

### println

    public void println(Object x)

  Overrides:
    `println` in class `PrintWriter`

Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2003-2009 The Codehaus. All rights reserved.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD