Class Justif

java.lang.Object
aQute.lib.justif.Justif

public class Justif extends Object
Formatter. This formatter allows you to build up an input string and then wraps the text. The following markup is available
  • $- - Line over the remaining width
  • \\t[0-9] - Go to tab position, and set indent to that position
  • \\f - Newlin
  • Field Details

  • Constructor Details

    • Justif

      public Justif(int width, int... tabs)
    • Justif

      public Justif()
  • Method Details

    • wrap

      public void wrap(StringBuilder sb)
      Routine to wrap a stringbuffer. Basically adds line endings but has the following control characters:
      • Space at the beginnng of a line is repeated when wrapped for indent.
      • A tab will mark the current position and wrapping will return to that position
      • A form feed in a tabbed colum will break but stay in the column
      Parameters:
      sb -
    • wrap

      public String wrap()
    • formatter

      public Formatter formatter()
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • indent

      public void indent(int indent, String string)
    • entry

      public void entry(String key, String separator, Object value)
    • table

      public void table(Map<?,?> table, String separator)
    • toString

      public String toString(Object o)