本文整理汇总了Java中org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor类的典型用法代码示例。如果您正苦于以下问题:Java DiagramEditor类的具体用法?Java DiagramEditor怎么用?Java DiagramEditor使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
DiagramEditor类属于org.eclipse.gmf.runtime.diagram.ui.parts包,在下文中一共展示了DiagramEditor类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
StatemachineDiagramEditorUtil.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:spoenemann,项目名称:xtext-gef,代码行数:26,代码来源:StatemachineMarkerNavigationProvider.java
示例2: setUp
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
@Before
public void setUp(){
IMultiDiagramEditor editor = Mockito.mock(IMultiDiagramEditor.class);
ServicesRegistry reg = Mockito.mock(ServicesRegistry.class);
this.ms = Mockito.mock(ModelSet.class);
try {
Mockito.when(reg.getService(ModelSet.class)).thenReturn(this.ms);
} catch (ServiceException e) {
e.printStackTrace();
}
this.editorPart = Mockito.mock(DiagramEditor.class);
Mockito.when(editor.getServicesRegistry()).thenReturn(reg);
Mockito.when(editor.getActiveEditor()).thenReturn(this.editorPart);
this.diagramManager = new DiagramManager(editor);
}
开发者ID:ELTE-Soft,项目名称:txtUML,代码行数:21,代码来源:DiagramManagerUnitTest.java
示例3: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
SimpleBPMN.diagram.part.SimpleBPMNDiagramEditorUtil
.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:bluezio,项目名称:simplified-bpmn-example,代码行数:27,代码来源:SimpleBPMNMarkerNavigationProvider.java
示例4: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker.getAttribute(org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID, null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer().getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource().getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
edu.toronto.cs.se.modelepedia.icse15_sequencediagram_mavo.diagram.part.ICSE15_SequenceDiagram_MAVODiagramEditorUtil
.selectElementsInDiagram(editor, Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:21,代码来源:ICSE15_SequenceDiagram_MAVOMarkerNavigationProvider.java
示例5: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
edu.toronto.cs.se.modelepedia.necsis14_classdiagram.diagram.part.NECSIS14_ClassDiagramDiagramEditorUtil
.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:27,代码来源:NECSIS14_ClassDiagramMarkerNavigationProvider.java
示例6: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
edu.toronto.cs.se.modelepedia.necsis14_databaseschema.diagram.part.NECSIS14_DatabaseSchemaDiagramEditorUtil
.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:27,代码来源:NECSIS14_DatabaseSchemaMarkerNavigationProvider.java
示例7: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker.getAttribute(org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID, null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer().getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource().getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
MIDDiagramEditorUtil.selectElementsInDiagram(editor, Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:20,代码来源:MIDMarkerNavigationProvider.java
示例8: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker.getAttribute(org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID, null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer().getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource().getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
MIDDiagramEditorUtil.selectElementsInDiagram(editor, Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:20,代码来源:MIDMarkerNavigationProvider.java
示例9: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker.getAttribute(org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID, null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer().getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource().getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
edu.toronto.cs.se.modelepedia.relationaldatabase_mavo.diagram.part.RelationalDatabase_MAVODiagramEditorUtil
.selectElementsInDiagram(editor, Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:21,代码来源:RelationalDatabase_MAVOMarkerNavigationProvider.java
示例10: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
RelationalDatabaseDiagramEditorUtil.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:26,代码来源:RelationalDatabaseMarkerNavigationProvider.java
示例11: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker.getAttribute(org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID, null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer().getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource().getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
edu.toronto.cs.se.modelepedia.istar_mavo.diagram.part.IStar_MAVODiagramEditorUtil
.selectElementsInDiagram(editor, Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:21,代码来源:IStar_MAVOMarkerNavigationProvider.java
示例12: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
IStarDiagramEditorUtil.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:26,代码来源:IStarMarkerNavigationProvider.java
示例13: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
StateMachineDiagramEditorUtil.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:26,代码来源:StateMachineMarkerNavigationProvider.java
示例14: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker.getAttribute(org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID, null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer().getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource().getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
edu.toronto.cs.se.modelepedia.statemachine_mavo.diagram.part.StateMachine_MAVODiagramEditorUtil
.selectElementsInDiagram(editor, Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:21,代码来源:StateMachine_MAVOMarkerNavigationProvider.java
示例15: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
StateDiagramEditorUtil.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:26,代码来源:StateMarkerNavigationProvider.java
示例16: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
ArmyDiagramEditorUtil.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:26,代码来源:ArmyMarkerNavigationProvider.java
示例17: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker
.getAttribute(
org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID,
null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer()
.getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource()
.getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
EconomyDiagramEditorUtil.selectElementsInDiagram(editor,
Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:26,代码来源:EconomyMarkerNavigationProvider.java
示例18: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker.getAttribute(org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID, null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer().getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource().getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
ClassDiagramDiagramEditorUtil
.selectElementsInDiagram(editor, Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:21,代码来源:ClassDiagramMarkerNavigationProvider.java
示例19: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker.getAttribute(org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID, null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer().getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource().getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
edu.toronto.cs.se.modelepedia.classdiagram_mavo.diagram.part.ClassDiagram_MAVODiagramEditorUtil
.selectElementsInDiagram(editor, Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:21,代码来源:ClassDiagram_MAVOMarkerNavigationProvider.java
示例20: doGotoMarker
import org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor; //导入依赖的package包/类
/**
* @generated
*/
protected void doGotoMarker(IMarker marker) {
String elementId = marker.getAttribute(org.eclipse.gmf.runtime.common.core.resources.IMarker.ELEMENT_ID, null);
if (elementId == null || !(getEditor() instanceof DiagramEditor)) {
return;
}
DiagramEditor editor = (DiagramEditor) getEditor();
Map editPartRegistry = editor.getDiagramGraphicalViewer().getEditPartRegistry();
EObject targetView = editor.getDiagram().eResource().getEObject(elementId);
if (targetView == null) {
return;
}
EditPart targetEditPart = (EditPart) editPartRegistry.get(targetView);
if (targetEditPart != null) {
edu.toronto.cs.se.modelepedia.graph_mavo.diagram.part.Graph_MAVODiagramEditorUtil
.selectElementsInDiagram(editor, Arrays.asList(new EditPart[] { targetEditPart }));
}
}
开发者ID:adisandro,项目名称:MMINT,代码行数:21,代码来源:Graph_MAVOMarkerNavigationProvider.java
注:本文中的org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditor类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论