Search in sources :

Example 1 with NewVaadinPortletClassDataModelProvider

use of com.liferay.ide.portlet.vaadin.core.operation.NewVaadinPortletClassDataModelProvider in project liferay-ide by liferay.

the class NewVaadinPortletWizard method getDefaultProvider.

@Override
protected IDataModelProvider getDefaultProvider() {
    // for now, no need for own template store and context type
    TemplateStore templateStore = PortletUIPlugin.getDefault().getTemplateStore();
    ContextTypeRegistry contextTypeRegistry = PortletUIPlugin.getDefault().getTemplateContextRegistry();
    TemplateContextType contextType = contextTypeRegistry.getContextType(PortletTemplateContextTypeIds.NEW);
    return new NewVaadinPortletClassDataModelProvider(fragment) {

        @Override
        public IDataModelOperation getDefaultOperation() {
            return new AddVaadinApplicationOperation(model, templateStore, contextType);
        }
    };
}
Also used : NewVaadinPortletClassDataModelProvider(com.liferay.ide.portlet.vaadin.core.operation.NewVaadinPortletClassDataModelProvider) ContextTypeRegistry(org.eclipse.jface.text.templates.ContextTypeRegistry) TemplateStore(org.eclipse.jface.text.templates.persistence.TemplateStore) TemplateContextType(org.eclipse.jface.text.templates.TemplateContextType)

Aggregations

NewVaadinPortletClassDataModelProvider (com.liferay.ide.portlet.vaadin.core.operation.NewVaadinPortletClassDataModelProvider)1 ContextTypeRegistry (org.eclipse.jface.text.templates.ContextTypeRegistry)1 TemplateContextType (org.eclipse.jface.text.templates.TemplateContextType)1 TemplateStore (org.eclipse.jface.text.templates.persistence.TemplateStore)1