Search in sources :

Example 16 with ContributionContextTypeRegistry

use of org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry in project webtools.sourceediting by eclipse.

the class JSONUIPlugin method getTemplateContextRegistry.

/**
 * Returns the template context type registry for the JSON plugin.
 *
 * @return the template context type registry for the JSON plugin
 */
public ContextTypeRegistry getTemplateContextRegistry() {
    if (fContextTypeRegistry == null) {
        ContributionContextTypeRegistry registry = new ContributionContextTypeRegistry();
        registry.addContextType(TemplateContextTypeIdsJSON.ALL);
        registry.addContextType(TemplateContextTypeIdsJSON.NEW);
        registry.addContextType(TemplateContextTypeIdsJSON.PACKAGE);
        fContextTypeRegistry = registry;
    }
    return fContextTypeRegistry;
}
Also used : ContributionContextTypeRegistry(org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry)

Example 17 with ContributionContextTypeRegistry

use of org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry in project webtools.sourceediting by eclipse.

the class JSPUIPlugin method getTemplateContextRegistry.

/**
 * Returns the template context type registry for the jsp plugin.
 *
 * @return the template context type registry for the jsp plugin
 */
public ContextTypeRegistry getTemplateContextRegistry() {
    if (fContextTypeRegistry == null) {
        ContributionContextTypeRegistry registry = new ContributionContextTypeRegistry();
        registry.addContextType(TemplateContextTypeIdsJSP.ALL);
        registry.addContextType(TemplateContextTypeIdsJSP.NEW);
        registry.addContextType(TemplateContextTypeIdsJSP.TAG);
        registry.addContextType(TemplateContextTypeIdsJSP.ATTRIBUTE);
        registry.addContextType(TemplateContextTypeIdsJSP.ATTRIBUTE_VALUE);
        registry.addContextType(TemplateContextTypeIdsJSP.NEW_TAG);
        fContextTypeRegistry = registry;
    }
    return fContextTypeRegistry;
}
Also used : ContributionContextTypeRegistry(org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry)

Example 18 with ContributionContextTypeRegistry

use of org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry in project webtools.sourceediting by eclipse.

the class XSLUIPlugin method getTemplateContextRegistry.

/**
 * Returns the template context type registry for the xsl plugin.
 *
 * @return the template context type registry for the xsl plugin
 */
public ContextTypeRegistry getTemplateContextRegistry() {
    if (fContextTypeRegistry == null) {
        ContributionContextTypeRegistry registry = new ContributionContextTypeRegistry();
        registry.addContextType(TemplateContextTypeXSL.XSL_NEW);
        registry.addContextType(TemplateContextTypeXSL.XSL_TAG);
        registry.addContextType(TemplateContextTypeXSL.XSL_ATTR);
        fContextTypeRegistry = registry;
    }
    return fContextTypeRegistry;
}
Also used : ContributionContextTypeRegistry(org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry)

Example 19 with ContributionContextTypeRegistry

use of org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry in project liferay-ide by liferay.

the class KaleoUI method getContextTypeRegistry.

public ContextTypeRegistry getContextTypeRegistry() {
    if (_contextTypeRegistry == null) {
        _contextTypeRegistry = new ContributionContextTypeRegistry();
        KaleoTemplateContextType contextType = new KaleoTemplateContextType();
        _contextTypeRegistry.addContextType(contextType);
    }
    return _contextTypeRegistry;
}
Also used : ContributionContextTypeRegistry(org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry)

Example 20 with ContributionContextTypeRegistry

use of org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry in project liferay-ide by liferay.

the class LayoutTplUI method getTemplateContextRegistry.

public ContextTypeRegistry getTemplateContextRegistry() {
    if (_fContextTypeRegistry == null) {
        ContributionContextTypeRegistry registry = new ContributionContextTypeRegistry();
        registry.addContextType(LayoutTplTemplateContextTypeIds.NEW);
        _fContextTypeRegistry = registry;
    }
    return _fContextTypeRegistry;
}
Also used : ContributionContextTypeRegistry(org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry)

Aggregations

ContributionContextTypeRegistry (org.eclipse.ui.editors.text.templates.ContributionContextTypeRegistry)23 KaleoTemplateContext (com.liferay.ide.kaleo.ui.xml.KaleoTemplateContext)1 StructuresTemplateContext (com.liferay.ide.portal.ui.templates.StructuresTemplateContext)1 AbstractJavaContextType (org.eclipse.jdt.internal.corext.template.java.AbstractJavaContextType)1 CodeTemplateContextType (org.eclipse.jdt.internal.corext.template.java.CodeTemplateContextType)1 ContextTypeRegistry (org.eclipse.jface.text.templates.ContextTypeRegistry)1 TemplateContextType (org.eclipse.jface.text.templates.TemplateContextType)1