class TreeMetaDataProvider {

  public Optional<Token> previousToken(TextRange textRange) {
    int textRangeIndex = indexOfFirstElement(sortedTokens, textRange);
    if (textRangeIndex <= 0) {
      return Optional.empty();
    } else {
      return Optional.of(sortedTokens.get(textRangeIndex - 1));
    }
  }

  public  TreeMetaDataProvider(List<Comment> comments, List<Token> tokens);

}