Skip to main content
summaryrefslogtreecommitdiffstats
blob: e46b2f0308944f5ccc301899b8252773b787fcf1 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
/**
 * Copyright (c) 2011 Mia-Software.
 *
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 * 	Nicolas Guyomar (Mia-Software) - Bug 349546 - EMF Facet facetSet editor
 *  Gregoire Dupe (Mia-Software) - Bug 361617 - Deprecation of APIs for the old Facet metamodels
 */
package org.eclipse.emf.facet.efacet.ui.internal;

import org.eclipse.emf.ecore.EParameter;
import org.eclipse.emf.edit.domain.EditingDomain;
import org.eclipse.emf.facet.efacet.metamodel.v0_2_0.efacet.Facet;
import org.eclipse.emf.facet.efacet.metamodel.v0_2_0.efacet.FacetAttribute;
import org.eclipse.emf.facet.efacet.metamodel.v0_2_0.efacet.FacetOperation;
import org.eclipse.emf.facet.efacet.metamodel.v0_2_0.efacet.FacetReference;
import org.eclipse.emf.facet.efacet.metamodel.v0_2_0.efacet.FacetSet;
import org.eclipse.emf.facet.efacet.ui.internal.exported.wizard.ICreateFacetInFacetSetWizard2;
import org.eclipse.emf.facet.efacet.ui.internal.exported.wizard.ICreateFacetSetWizard;
import org.eclipse.emf.facet.efacet.ui.internal.exported.wizard.IFacetChildrenWizard2;
import org.eclipse.jface.viewers.ISelection;

/**
 * This interface provides methods used to create wizards that create {@link Facet}s and Facet elements.
 * 
 * TODO: This interface has to be renamed to IFacetUIFactory before the release of 0.2
 * 
 * @since 0.2
 */
//TODO: This interface has to be renamed to IFacetUIFactory before the release of 0.2
public interface IFacetUIFactory2 {

	/**
	 * Returns an instance of a {@link FacetUIFactoryImpl}
	 */
	IFacetUIFactory2 INSTANCE = null; //TODO cf. https://bugs.eclipse.org/bugs/show_bug.cgi?id=364601

	/**
	 * Create a wizard dialog dedicated to the addition of a {@link Facet} in a {@link FacetSet}
	 * 
	 * @param selection
	 *            the current selection, should be a FacetSet
	 * @param editingDomain
	 *            the editing domain used to perform the EMF command
	 * @return the newly created wizard
	 */
	public ICreateFacetInFacetSetWizard2 createCreateFacetInFacetSetWizardDialog(ISelection selection, EditingDomain editingDomain);

	/**
	 * Create a wizard dialog dedicated to the creation of a {@link FacetSet}
	 * 
	 * @param selection
	 *            the current selection
	 * @return the newly created wizard
	 */
	public ICreateFacetSetWizard createCreateFacetSetWizardDialog(ISelection selection);

	/**
	 * Create a wizard dialog dedicated to the creation of a {@link FacetSet}
	 * 
	 * @param selection
	 *            the current selection
	 * @param openCreatedFacetSetInEditor
	 * @return the newly created wizard
	 */
	public ICreateFacetSetWizard createCreateFacetSetWizardDialog(ISelection selection, boolean openCreatedFacetSetInEditor);

	/**
	 * Create a wizard dialog dedicated to the addition of a {@link FacetAttribute} in a {@link Facet}
	 * 
	 * @param selection
	 *            the current selection, should be a Facet
	 * @param editingDomain
	 *            the editing domain used to perform the EMF command
	 * @return the newly created wizard
	 */
	public IFacetChildrenWizard2 createAddFacetAttributeWizardDialog(ISelection selection, EditingDomain editingDomain);

	/**
	 * Create a wizard dialog dedicated to the addition of a {@link FacetOperation} in a {@link Facet}
	 * 
	 * @param selection
	 *            the current selection, should be a Facet
	 * @param editingDomain
	 *            the editing domain used to perform the EMF command
	 * @return the newly created wizard
	 */
	public IFacetChildrenWizard2 createAddFacetOperationWizardDialog(ISelection selection, EditingDomain editingDomain);

	/**
	 * Create a wizard dialog dedicated to the addition of a {@link EParameter} to a {@link FacetOperation}
	 * 
	 * @param selection
	 *            the current selection, should be a FacetOperation
	 * @param editingDomain
	 *            the editing domain used to perform the EMF command
	 * @return the newly created wizard
	 */
	public IFacetChildrenWizard2 createAddFacetOperationParameterWizardDialog(ISelection selection, EditingDomain editingDomain);

	/**
	 * Create a wizard dialog dedicated to the addition of a {@link FacetReference} in a {@link Facet}
	 * 
	 * @param selection
	 *            the current selection, should be a Facet Reference
	 * @param editingDomain
	 *            the editing domain used to perform the EMF command
	 * @return the newly created wizard
	 */
	public IFacetChildrenWizard2 createAddFacetReferenceWizardDialog(ISelection selection, EditingDomain editingDomain);

}

Back to the top