code: public void decode(TypedValueDecoder tvd)
          throws IllegalArgumentException
      {
          char[] buf;
          int start, end;
  
          if (mInputStart >= 0) { // shared buffer, common case
              buf = mInputBuffer;
              start = mInputStart;
              end = start + mInputLen;
          } else {
              buf = getTextBuffer();
              start = 0;
              end = mSegmentSize + mCurrentSize;
          }
  
          // Need to trim first
          while (true) {
              if (start >= end) {
                  tvd.handleEmptyValue();
                  return;
              }
              if (!StringUtil.isSpace(buf[start])) {
                  break;
              }
              ++start;
          }
          // Trailing space?
          while (--end > start && StringUtil.isSpace(buf[end])) { }
          tvd.decode(buf, start, end+1);
      }
docs: Generic pass-through method which call given decoder
  with accumulated data