/** * Write the Metawidget output using the given Writer. * * @param initialIndent * the initialIndent that will be applied to every line. 0 for no initial indent. -1 * for no subsequent indenting either */ public void write( Writer writer, int initialIndent ) { try { mPipeline.buildWidgets( inspect() ); Writer writerToUse = writer; if ( initialIndent >= 0 ) { writerToUse = new IndentedWriter( writer, initialIndent ); } super.write( writerToUse ); } catch ( Exception e ) { throw MetawidgetException.newException( e ); } }
/** * Write the Metawidget output using the given Writer. * * @param initialIndent * the initialIndent that will be applied to every line. 0 for no initial indent. -1 * for no subsequent indenting either */ public void write( Writer writer, int initialIndent ) { try { mPipeline.buildWidgets( inspect() ); Writer writerToUse = writer; if ( initialIndent >= 0 ) { writerToUse = new IndentedWriter( writer, initialIndent ); } super.write( writerToUse ); } catch ( Exception e ) { throw MetawidgetException.newException( e ); } }