當前位置: 首頁>>代碼示例>>Java>>正文


Java MarkProvider類代碼示例

本文整理匯總了Java中org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider的典型用法代碼示例。如果您正苦於以下問題:Java MarkProvider類的具體用法?Java MarkProvider怎麽用?Java MarkProvider使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


MarkProvider類屬於org.netbeans.modules.editor.errorstripe.privatespi包,在下文中一共展示了MarkProvider類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: createMarkProviders

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
private static void createMarkProviders(Collection<? extends MarkProviderCreator> creators, List<MarkProvider> providers, JTextComponent pane) {
    for (MarkProviderCreator creator : creators) {
        if (LOG.isLoggable(Level.FINE)) {
            LOG.fine("creator = " + creator);
        }

        MarkProvider provider = creator.createMarkProvider(pane);
        if (provider != null) {
            providers.add(provider);
        }
    }
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:13,代碼來源:AnnotationViewDataImpl.java

示例2: addListenersToMarkProviders

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
private void addListenersToMarkProviders() {
    for (Iterator p = markProviders.iterator(); p.hasNext(); ) {
        MarkProvider provider = (MarkProvider) p.next();
        
        PropertyChangeListener weakL = WeakListeners.propertyChange(this, provider);
        provider.addPropertyChangeListener(weakL);
        statusProvidersWeakLs.add(weakL);
    }
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:10,代碼來源:AnnotationViewDataImpl.java

示例3: removeListenersFromMarkProviders

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
private void removeListenersFromMarkProviders() {
    if (markProvidersWeakLs.size() == markProviders.size()) { // Check if the listeners were not removed already
        int lIndex = 0;
        for (MarkProvider markProvider : markProviders) {
            markProvider.removePropertyChangeListener(markProvidersWeakLs.get(lIndex));
        }
    }
    markProvidersWeakLs.clear();
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:10,代碼來源:AnnotationViewDataImpl.java

示例4: createMergedMarks

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
static Collection<Mark> createMergedMarks(List<MarkProvider> providers) {
    Collection<Mark> result = new LinkedHashSet<Mark>();
    
    for(MarkProvider provider : providers) {
        result.addAll(provider.getMarks());
    }
    
    return result;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:10,代碼來源:AnnotationViewDataImpl.java

示例5: gatherProviders

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
private void gatherProviders(JTextComponent pane) {
    long start = System.currentTimeMillis();

    // Collect legacy mark providers
    List<MarkProvider> newMarkProviders = new ArrayList<MarkProvider>();
    if (legacyCrap != null) {
        createMarkProviders(legacyCrap.getMarkProviderCreators(), newMarkProviders, pane);
    }
    
    // Collect mark providers
    String mimeType = DocumentUtilities.getMimeType(pane);

    if (mimeType == null) {
        mimeType = pane.getUI().getEditorKit(pane).getContentType();
    }
    
    Collection<? extends MarkProviderCreator> creators = 
        mime2Creators.get(mimeType);

    if (creators == null) { //nothing for current mimeType, probably wrong init
        lookupProviders(mimeType);
        creators = mime2Creators.get(mimeType);
    }

    createMarkProviders(creators, newMarkProviders, pane);

    removeListenersFromMarkProviders();
    this.markProviders = newMarkProviders;
    addListenersToMarkProviders();

    
    // Collect legacy status providers
    List<UpToDateStatusProvider> newStatusProviders = new ArrayList<UpToDateStatusProvider>();
    if (legacyCrap != null) {
        createStatusProviders(legacyCrap.getUpToDateStatusProviderFactories(), newStatusProviders, pane);
    }
    
    // Collect status providers
    Collection<? extends UpToDateStatusProviderFactory> factories = 
        mime2StatusProviders.get(mimeType);
    if (factories != null) {
        createStatusProviders(factories, newStatusProviders, pane);
    } else {
        if (LOG.isLoggable(Level.FINE)) {
            LOG.fine("Factories set to null in mimeType " + mimeType); //NOI18N
        }
    }

    removeListenersFromStatusProviders();
    this.statusProviders = newStatusProviders;
    addListenersToStatusProviders();
    
    
    long end = System.currentTimeMillis();
    if (AnnotationView.TIMING_ERR.isLoggable(ErrorManager.INFORMATIONAL)) {
        AnnotationView.TIMING_ERR.log(ErrorManager.INFORMATIONAL, "gather providers took: " + (end - start));
    }
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:59,代碼來源:AnnotationViewDataImpl.java

示例6: createMarkProvider

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
public MarkProvider createMarkProvider(JTextComponent document) {
    if (ENABLE && !switchOff)
        return new CaretMarkProvider(document);
    else
        return null;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:7,代碼來源:CaretMarkProviderCreator.java

示例7: setProvider

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
public void setProvider(MarkProvider provider) {
    this.provider = provider;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:4,代碼來源:TestMarkProviderCreator.java

示例8: createMarkProvider

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
public MarkProvider createMarkProvider(JTextComponent document) {
    return provider;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:4,代碼來源:TestMarkProviderCreator.java

示例9: createMarkProvider

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
@Override
public MarkProvider createMarkProvider (JTextComponent pane) {
    AnnotationMarkProvider amp = new AnnotationMarkProvider();
    pane.putClientProperty(PROVIDER_KEY, amp);
    return amp;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:7,代碼來源:AnnotationMarkInstaller.java

示例10: createMarkProvider

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
public MarkProvider createMarkProvider(JTextComponent pane) {
    return OccurrencesMarkProvider.get(pane.getDocument());
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:4,代碼來源:OccurrencesMarkProviderCreator.java

示例11: createMarkProvider

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
public MarkProvider createMarkProvider(JTextComponent pane) {
    AnnotationMarkProvider amp = new AnnotationMarkProvider();
    pane.putClientProperty(PROVIDER_KEY, amp);
    return amp;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:6,代碼來源:AnnotationMarkInstaller.java

示例12: createMarkProvider

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
public MarkProvider createMarkProvider(JTextComponent pane) {
    AnnotationMarkProvider amp = new AnnotationMarkProvider();
    pane.putClientProperty(AnnotationMarkInstaller.PROVIDER_KEY, amp);
    return amp;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:6,代碼來源:AnnotationMarkInstaller.java

示例13: setMarks

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
public void setMarks(List<AnnotationMark> marks) {
    List old = this.marks;
    this.marks = marks;
    firePropertyChange(MarkProvider.PROP_MARKS, old, marks);
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:6,代碼來源:AnnotationMarkProvider.java

示例14: createMarkProvider

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
MarkProvider createMarkProvider(JTextComponent target) {
    DiffSidebar sideBar = getSideBar(target);
    return (sideBar != null) ? sideBar.getMarkProvider() : null;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:5,代碼來源:DiffSidebarManager.java

示例15: getMarkProvider

import org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider; //導入依賴的package包/類
MarkProvider getMarkProvider() {
    return markProvider;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:4,代碼來源:DiffSidebar.java


注:本文中的org.netbeans.modules.editor.errorstripe.privatespi.MarkProvider類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。