code: public TextObject append(Reader reader) throws IOException {
          char[] buf = new char[1024];
          while (reader.ready() && (maxTextLength==0 || stringBuilder.length()<maxTextLength)) {
              int length = reader.read(buf);
              append(String.valueOf(buf, 0, length));
          }
          return this;
      }
docs: Append the target text for language detection.
  This method read the text from specified input reader.
  If the total size of target text exceeds the limit size,
  the rest is ignored.
  
  @param reader the input reader (BufferedReader as usual)
  @throws java.io.IOException Can't read the reader.