Nuxeo Enterprise Platform 5.4

org.nuxeo.ecm.gwt.runtime.rebind
Class JSourceWriter

java.lang.Object
  extended by java.io.Writer
      extended by java.io.StringWriter
          extended by org.nuxeo.ecm.gwt.runtime.rebind.JSourceWriter
All Implemented Interfaces:
com.google.gwt.user.rebind.SourceWriter, java.io.Closeable, java.io.Flushable, java.lang.Appendable

public class JSourceWriter
extends java.io.StringWriter
implements com.google.gwt.user.rebind.SourceWriter

A source writer that is writing in memory. Used to be able to add imports after begining to write

Author:
Bogdan Stefanescu

Constructor Summary
JSourceWriter(com.google.gwt.user.rebind.ClassSourceFileComposerFactory composer, com.google.gwt.core.ext.GeneratorContext context, java.io.PrintWriter printWriter)
           
 
Method Summary
 void addImplementedInterface(java.lang.String intfName)
           
 void addImport(java.lang.String imp)
           
 void beginJavaDocComment()
           
 void commit(com.google.gwt.core.ext.TreeLogger logger)
           
 void endJavaDocComment()
           
 com.google.gwt.user.rebind.ClassSourceFileComposerFactory getComposer()
           
 void indent()
           
 void indentln(java.lang.String s)
           
 void outdent()
           
 void print(java.lang.String s)
           
 void println()
           
 void println(java.lang.String str)
           
 void tabs()
           
 
Methods inherited from class java.io.StringWriter
append, append, append, close, flush, getBuffer, toString, write, write, write, write
 
Methods inherited from class java.io.Writer
write
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

JSourceWriter

public JSourceWriter(com.google.gwt.user.rebind.ClassSourceFileComposerFactory composer,
                     com.google.gwt.core.ext.GeneratorContext context,
                     java.io.PrintWriter printWriter)
Method Detail

getComposer

public com.google.gwt.user.rebind.ClassSourceFileComposerFactory getComposer()
Returns:
the composer.

println

public void println()
Specified by:
println in interface com.google.gwt.user.rebind.SourceWriter

println

public void println(java.lang.String str)
Specified by:
println in interface com.google.gwt.user.rebind.SourceWriter

print

public void print(java.lang.String s)
Specified by:
print in interface com.google.gwt.user.rebind.SourceWriter

indent

public void indent()
Specified by:
indent in interface com.google.gwt.user.rebind.SourceWriter

outdent

public void outdent()
Specified by:
outdent in interface com.google.gwt.user.rebind.SourceWriter

indentln

public void indentln(java.lang.String s)
Specified by:
indentln in interface com.google.gwt.user.rebind.SourceWriter

tabs

public void tabs()

beginJavaDocComment

public void beginJavaDocComment()
Specified by:
beginJavaDocComment in interface com.google.gwt.user.rebind.SourceWriter

endJavaDocComment

public void endJavaDocComment()
Specified by:
endJavaDocComment in interface com.google.gwt.user.rebind.SourceWriter

commit

public void commit(com.google.gwt.core.ext.TreeLogger logger)
Specified by:
commit in interface com.google.gwt.user.rebind.SourceWriter

addImport

public void addImport(java.lang.String imp)

addImplementedInterface

public void addImplementedInterface(java.lang.String intfName)

Nuxeo Enterprise Platform 5.4

Copyright © 2010 Nuxeo SAS. All Rights Reserved.