code: public String getStem() {
        if (isInstance(Types.TOKEN)) {
           putIfAbsent(Types.STEM, Stemmers
                                      .getStemmer(getLanguage())
                                      .stem(this));
           return get(Types.STEM).asString();
        }
        return tokens()
                  .stream()
                  .map(HString::getStem)
                  .collect(Collectors.joining(getLanguage().usesWhitespace() ? " " : ""));
     }
docs: Gets the stemmed version of the HString. Stems of token are determined using the <code>Stemmer</code> associated
  with the language that the token is in. Tokens store their stem using the <code>STEM</code> attribute, so that the
  stem only needs to be calculated once.Stems of longer phrases are constructed from token stems.
  
  @return The stemmed version of the HString.