public ERDiagramElementStateListener(final ERDiagramMultiPageEditor editorPart) { this.editorPart = editorPart; documentProvider = DocumentProviderRegistry.getDefault().getDocumentProvider(editorPart.getEditorInput()); documentProvider.addElementStateListener(this); try { documentProvider.connect(editorPart.getEditorInput()); } catch (final CoreException e) { ERDiagramActivator.showExceptionDialog(e); } }
public ERDiagramElementStateListener(ERDiagramMultiPageEditor editorPart) { this.editorPart = editorPart; documentProvider = DocumentProviderRegistry.getDefault() .getDocumentProvider(editorPart.getEditorInput()); documentProvider.addElementStateListener(this); try { documentProvider.connect(editorPart.getEditorInput()); } catch (CoreException e) { ERDiagramActivator.showExceptionDialog(e); } }
@Override protected void doSetInput(IEditorInput input) throws CoreException { if (input != null) { setDocumentProvider(DocumentProviderRegistry.getDefault().getDocumentProvider(input)); } super.doSetInput(input); inputSet = true; }
public ERDiagramElementStateListener(ERFluteMultiPageEditor editorPart) { this.editorPart = editorPart; documentProvider = DocumentProviderRegistry.getDefault().getDocumentProvider(editorPart.getEditorInput()); documentProvider.addElementStateListener(this); try { documentProvider.connect(editorPart.getEditorInput()); } catch (final CoreException e) { Activator.showExceptionDialog(e); } }
/** * @brief Implements the singleton pattern on LipsDocumentProvider * * @return A singleton instance to LipsDocumentProvider */ public static LipsDocumentProvider instance() { if (theInstance == null) { final DocumentProviderRegistry dr = DocumentProviderRegistry.getDefault(); theInstance = (LipsDocumentProvider) dr.getDocumentProvider(EXTENSION); if (theInstance == null) { throw new IllegalStateException("No document provider found for " + EXTENSION); } } return theInstance; }
protected void setDocumentProvider(final IEditorInput input) { fImplicitDocumentProvider = DocumentProviderRegistry.getDefault().getDocumentProvider(input); }
protected void setDocumentProvider(IEditorInput input) { fImplicitDocumentProvider = DocumentProviderRegistry.getDefault() .getDocumentProvider(input); }