Class WikiText.WikiContent

  • All Implemented Interfaces:
    Visitable
    Enclosing class:
    WikiText

    public final class WikiText.WikiContent
    extends WikiText.Token
    Upper element containing text/links/templates and comments interleaved
    • Method Detail

      • wikiTokensStream

        public Stream<WikiText.Token> wikiTokensStream()
        returns a stream serving all wikiTokens in the wikiText, that is all special media wiki constructs, excluding html comments. This does not return the text tokens that are intertwined between the wiki tokens.
        Returns:
        a Stream of Tokens
      • wikiTokens

        public List<WikiText.Token> wikiTokens()
        returns all wikiTokens in the wikiText, that is all special media wiki constructs, excluding html comments. This does not return the text tokens that are intertwined between the wiki tokens.
        Returns:
        a sequence of Tokens
      • wikiTokensStreamWithHtmlComments

        public Stream<WikiText.Token> wikiTokensStreamWithHtmlComments()
        returns a stream serving all wikiTokens in the wikiText, that is all special media wiki constructs, excluding html comments. This does not return the text tokens that are intertwined between the wiki tokens.
        Returns:
        a Stream of Tokens
      • wikiTokensWithHtmlComments

        public List<WikiText.Token> wikiTokensWithHtmlComments()
        returns all wikiTokens in the wikiText, that is all special media wiki constructs, including html comments. This does not return the text tokens that are intertwined between the wiki tokens.
        Returns:
        a sequence of all Wiki Tokens
      • tokens

        public List<WikiText.Token> tokens()
        returns a List of wikiTokens including Text tokens that may be intertwined. HTML comments are ignored. Two successive Texts may be found if a comment was present in the wiki source.
        Returns:
        a list of tokens (either text or wikiTokens)
      • tokensWithHtmlComments

        public List<WikiText.Token> tokensWithHtmlComments()
        returns a List of wikiTokens including Text tokens that may be intertwined. HTML comments are included in the list.
        Returns:
        a list of tokens (either text or wikiTokens)
      • accept

        public <T> T accept​(Visitor<T> visitor)