Class StringUtil.LineWrappedString

  • Enclosing class:
    StringUtil

    public static class StringUtil.LineWrappedString
    extends java.lang.Object
    Class for returning multiple values from the wrapLines method.
    Author:
    Matthew Wakeling
    • Constructor Summary

      Constructors 
      Constructor Description
      LineWrappedString​(java.lang.String wrapped, boolean truncated)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object o)
      java.lang.String getString()
      Returns the wrapped String.
      int hashCode()
      boolean isTruncated()
      Returns whether the String had to be truncated.
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • LineWrappedString

        public LineWrappedString​(java.lang.String wrapped,
                                 boolean truncated)
        Constructor.
        Parameters:
        wrapped - the String in converted form
        truncated - true if the String had to be truncated to make it fit
    • Method Detail

      • getString

        public java.lang.String getString()
        Returns the wrapped String.
        Returns:
        a String
      • isTruncated

        public boolean isTruncated()
        Returns whether the String had to be truncated.
        Returns:
        a boolean
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object