Class ADSentenceStream.SentenceParser

  • Enclosing class:
    ADSentenceStream

    public static class ADSentenceStream.SentenceParser
    extends Object
    Parses a sample of AD corpus. A sentence in AD corpus is represented by a Tree. In this class we declare some types to represent that tree. Today we get only the first alternative (A1).
    • Constructor Detail

      • SentenceParser

        public SentenceParser()
    • Method Detail

      • parse

        public ADSentenceStream.Sentence parse​(String sentenceString,
                                               int para,
                                               boolean isTitle,
                                               boolean isBox)
        Parses a sentence string into a ADSentenceStream.Sentence.
        Parameters:
        sentenceString - The input string to parse.
        isTitle - true if it represents a title element, false otherwise.
        para - The parameter number.
        isBox - true if it represents a box element, false otherwise.
        Returns:
        A ADSentenceStream.Sentence instance parsed from sentenceString.