예제 #1
0
        public void Process(ProgramFiles programFiles)
        {
            Debug.Assert(programFiles != null);
            log.InfoFormat("Get input sentence from file {0}", programFiles.InputFileName);
            var inputSentence = new InputSentence(programFiles.InputFS);
            log.InfoFormat("Sentence info: {0}{1}", Environment.NewLine, inputSentence.ToString());

            var preProcessor = new SentencePreProcessor(inputSentence);
            preProcessor.Process();
            log.InfoFormat("Final sentence index is {0}", inputSentence.Index.ToInitialString());

            log.InfoFormat("Main proccessing for the sentence {0}{1}", Environment.NewLine, inputSentence.ModifiedText);
            //var mainProcessor = new SentenceMainProcessor(preProcessor.ResultSentence);
            //mainProcessor.Process();
            log.Info("DUMMY done.");

            byte[] info = new UTF8Encoding(true).GetBytes(preProcessor.ResultSentence.SentenceXML);
            programFiles.ResultFS.Write(info, 0, info.Length);

            //SaveReults(inputSentence);
        }
예제 #2
0
 public SentencePreProcessor(InputSentence sentence)
 {
     inputSentence = sentence;
     inputSentence.ModifiedText = sentence.InitialText;
 }