Package org.jf.util
Class TwoColumnOutput
- java.lang.Object
-
- org.jf.util.TwoColumnOutput
-
public final class TwoColumnOutput extends java.lang.Object
Class that takes a combined output destination and provides two output writers, one of which ends up writing to the left column and one which goes on the right.
-
-
Constructor Summary
Constructors Constructor Description TwoColumnOutput(java.io.OutputStream out, int leftWidth, int rightWidth, java.lang.String spacer)
Constructs an instance.TwoColumnOutput(java.io.Writer out, int leftWidth, int rightWidth, java.lang.String spacer)
Constructs an instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
write(java.lang.String left, java.lang.String right)
-
-
-
Constructor Detail
-
TwoColumnOutput
public TwoColumnOutput(@Nonnull java.io.Writer out, int leftWidth, int rightWidth, @Nonnull java.lang.String spacer)
Constructs an instance.- Parameters:
out
- non-null; writer to send final output toleftWidth
- > 0; width of the left column, in charactersrightWidth
- > 0; width of the right column, in charactersspacer
- non-null; spacer string to sit between the two columns
-
TwoColumnOutput
public TwoColumnOutput(java.io.OutputStream out, int leftWidth, int rightWidth, java.lang.String spacer)
Constructs an instance.- Parameters:
out
- non-null; stream to send final output toleftWidth
- >= 1; width of the left column, in charactersrightWidth
- >= 1; width of the right column, in charactersspacer
- non-null; spacer string to sit between the two columns
-
-