コード例 #1
0
 public JadeTokenizer(JadeClassifierProvider provider)
 {
     this.CComments            = false;
     this.MultilineCppComments = true;
     if (provider != null && provider.JsTaggerProvider != null)
     {
         this._jsBuffer = provider.BufferFactoryService.CreateTextBuffer(provider.JsContentType);
         this._jsTagger = provider.JsTaggerProvider.CreateTagger <ClassificationTag>(this._jsBuffer);
     }
     if (provider != null && provider.CssClassifierProvider != null)
     {
         this._cssBuffer     = provider.BufferFactoryService.CreateTextBuffer(provider.CssContentType);
         this._cssClassifier = provider.CssClassifierProvider.GetClassifier(this._cssBuffer);
     }
 }
コード例 #2
0
 public JadeClassifier(ITextBuffer textBuffer, JadeClassifierProvider provider) :
     base(textBuffer, new JadeTokenizer(provider), new JadeClassificationNameProvider(provider.ClassificationRegistryService))
 {
     this.LineBasedClassification = true;
     ServiceManager.AddService <JadeClassifier>(this, textBuffer);
 }