diff --git a/CHANGELOG.adoc b/CHANGELOG.adoc index 26689b11be..4d63cbb9fb 100644 --- a/CHANGELOG.adoc +++ b/CHANGELOG.adoc @@ -182,6 +182,7 @@ In other scenarios, the default creation position border remains the eastern one - https://github.com/eclipse-sirius/sirius-web/issues/2785[#2785] [gantt] Add cypress tests - https://github.com/eclipse-sirius/sirius-web/issues/3225[#3225] [sirius-web] The confirmation dialog on delete does not propose anymore the option allowing to "Disable this confirmation dialog" when the local storage is not available. - https://github.com/eclipse-sirius/sirius-web/issues/3246[#3246] [view] Make the `ViewRepresentationDescriptionSearchService` independent from specific representations +- https://github.com/eclipse-sirius/sirius-web/issues/3220[#3220] [deck] Add documentation == v2024.1.0 diff --git a/doc/specifier/images/deck-card.png b/doc/specifier/images/deck-card.png new file mode 100644 index 0000000000..648f61c6cd Binary files /dev/null and b/doc/specifier/images/deck-card.png differ diff --git a/doc/specifier/images/deck-description-overview.png b/doc/specifier/images/deck-description-overview.png new file mode 100644 index 0000000000..6d47787359 Binary files /dev/null and b/doc/specifier/images/deck-description-overview.png differ diff --git a/doc/specifier/images/deck-lane.png b/doc/specifier/images/deck-lane.png new file mode 100644 index 0000000000..6a563539cf Binary files /dev/null and b/doc/specifier/images/deck-lane.png differ diff --git a/doc/specifier/images/deck-overview.png b/doc/specifier/images/deck-overview.png new file mode 100644 index 0000000000..bef05620be Binary files /dev/null and b/doc/specifier/images/deck-overview.png differ diff --git a/doc/specifier/representation-deck.adoc b/doc/specifier/representation-deck.adoc new file mode 100644 index 0000000000..ad61cc773c --- /dev/null +++ b/doc/specifier/representation-deck.adoc @@ -0,0 +1,132 @@ +# Deck representation description + +This chapter explains how to configure a `Deck` representation in the `View` model. + +A `Deck` representation is composed with many `Lanes` containing many `Cards`. +Each `Lane` and `Card` is associated with a semantic element that is an object of the model represented by a `Deck` representation. + +image::images/deck-overview.png[Deck representation overview] + +## Deck description + +To define how your model is represented with a `Deck` representation, the specifier needs to create a `DeckDescription` in the `View` model. + +image::images/deck-description-overview.png[Deck description overview] + +* `Name` : A name that helps the specifier to know what the DeckDescription is about +* `Domain Type`: Type of the object on which it is possible to create the representation +* `Precondition Expression`: An expression that determine if it is possible to create the representation +* `Title Expression`: The initial name of the representation once created + +### Deck style + +It is possible to define the *background color* of the `Deck` representation by adding a `StyleDescription` in the `DeckDescription`. + +In addition, adding a `ConditionalStyleDescription` allows to override the style if the `Condition` expression returns `true`. +You may add multiple `ConditionalStyleDescription`. + +## Lane description + +The `LaneDescription` is used to define the lanes. + +image::images/deck-lane.png[Deck lane] + +* `Semantic Candidates Expression`: An expression that returns one or more semantic elements. +Each semantic element will be represented by a lane. +** `self` variable is the semantic element associated with the `Deck`. +* `Title Expression`: An expression that defines the title of the lane +** `self` variable is a semantic element among the list returned by the `Semantic Candidates Expression` +* `Label Expression`: An expression that defines the label of the lane +* `Is Collapsible Expression`: An boolean expression. +If true, it is possible to collapse the lane hence hiding all the contained cards. + +### Lane style + +It is possible to define the style of the lane by adding a `StyleDescription` in the `LaneDescription`. +The customizable attributes are + +* Font Size +* Italic, Bold, Underline and Strike Through +* The text color +* The background color of the lane + +In addition, adding a `ConditionalStyleDescription` allows to override the style if the `Condition` expression returns `true`. +You may add multiple `ConditionalStyleDescription` + +## Card description + +The `CardDescription` is used to define the card inside a lane. + +image::images/deck-card.png[Deck card] + +* `Semantic Candidates Expression`: An expression that returns one or more semantic elements. +Each semantic element will be represented by a `Card`. +** `self` variable is the semantic element associated with the `Lane` +* `Title Expression`: An expression that defines the title of the card +** `self` variable is a semantic element among the list returned by the `Semantic Candidates Expression`. +* `Label Expression`: An expression that defines the label of the card +* `Description Expression`: An expression that defines the description of the card + +### Card style + +As for `LaneDescription`, it is possible to define the style of the card by adding a `StyleDescription` or one or more `ConditionalStyleDescription` in the `CardDescription`. + +## Tools + +Many tools can be configured for `Lane` and `Card`. +By default, a tool does nothing. +A tool provides access to variables useful in the context of the tool and executes the operations associated with the tool. +Typical operation: + +* `Change Context`: It allows to change the `self` value. +But typically this operation is useful if you just want to call a java service that will implement the tool behavior. +* `Create Instance`: Creates a semantic object and add it in the defined feature of the `self` semantic element +* `Set Value`: Sets the value on a given feature on `self` semantic element +* `Delete Element` +* etc + +### Lane tools + +* `Lane Drop Tool`: +This tool defines the behavior when dragging and dropping a lane before or after another lane. +Available variables: +** `self`: The semantic element associated with the dropped lane +** `index`: The new index of the dropped lane. +First position corresponds to zero and last position corresponds to the number of lanes. + + +* `Edit Lane Tool`: This tool defines the behavior when the title of a lane is changed. +Available variables: +** `self`: The semantic element associated with the dropped lane +** `newTitle`: The new value of the title. + +### Card tools + +* `Create Card Tool`: This tool defines the behavior for the button to add a card. +Available variables: +** `self`: The semantic element associated with the lane +** `title`: The value of the title. +** `description`: The value of the description. +** `label`: The value of the label. + +* `Edit Card Tool`: This tool defines the behavior when the title, description or label of a card is changed. +Available variables: +** `self`: The semantic element associated with the dropped lane. +** `newTitle`: The new value of the title. +** `newDescription`: The new value of the description. +** `newLabel`: The new value of the label. + +* `Delete Card Tool`: This tool defines the behavior for the delete button on a card. +Available variables: +** `self`: The semantic element associated with the card + +* `Card Drop Tool`: This tool defines the behavior when dragging and dropping a card among cards of the same or other lane. +Available variables: +** `self`: The semantic object associated with the card +** `oldLane`: The initial lane from which the card is dragged +** `oldLaneTarget`: The semantic object associated with the initial lane +** `newLane`: The lane where the card is dropped +** `newLaneTarget`: The semantic object associated with the new lane +** `index`: Index of the card among the cards of the new lane. +First position corresponds to zero and last position corresponds to the number of cards in the lane. + diff --git a/doc/user/images/deck-overview.png b/doc/user/images/deck-overview.png new file mode 100644 index 0000000000..bef05620be Binary files /dev/null and b/doc/user/images/deck-overview.png differ diff --git a/doc/user/images/deck-show-hide.png b/doc/user/images/deck-show-hide.png new file mode 100644 index 0000000000..bff9e17626 Binary files /dev/null and b/doc/user/images/deck-show-hide.png differ diff --git a/doc/user/images/deck-toolbar.png b/doc/user/images/deck-toolbar.png new file mode 100644 index 0000000000..75774dd35f Binary files /dev/null and b/doc/user/images/deck-toolbar.png differ diff --git a/doc/user/representation-deck.adoc b/doc/user/representation-deck.adoc new file mode 100644 index 0000000000..fdc47c60c9 --- /dev/null +++ b/doc/user/representation-deck.adoc @@ -0,0 +1,46 @@ +# Deck representation + +A `Deck` representation is composed with many `Lanes` containing many `Cards` +Each `Lane` and `Card` is associated to a semantic element that is an object of the model represented by a `Deck` representation. + +image::images/deck-overview.png[Deck representation overview] + +## Deck Toolbar + +image::images/deck-toolbar.png[Deck Toolbar] + +* `Toggle full screen mode` : It allows to display the representation in full screen +* `Fit to screen`: Adjust the zoom level to the size of the editor +* `Zoom in` +* `Zoom out` +* `Reset zoom`: Set the zoom level to default +* `Share`: Provide an URL that reaches directly the current Deck representation + +## Selection + +When selecting a `Lane` or a `Card`, the associated semantic element is selected in the `Explorer` and its properties are displayed in `Details`. + +## Edition + +To edit text area of a `Lane` or a `Card` first select and then click in the text area. +You can also press `F2` to edit the title. Then you can press `Tab` key to edit next fields. + +The `Lane` editable attributes: + +* `Title` + +The `Card` editable attributes: + +* `Title` +* `Description` +* `Label` + +## Show/Hide cards + +image:images/deck-show-hide.png[Show/Hide Cards] + +You have the ability to show/hide individual cards or hide the whole cards of a lane using the expand button. + +## Moving lanes and cards + +According to how the `View` model has been configured, you can update the model by *dragging and dropping* Lane or Cards. diff --git a/integration-tests/cypress/workbench/Deck.ts b/integration-tests/cypress/workbench/Deck.ts index 0ec8194aab..3e6b7c5f76 100644 --- a/integration-tests/cypress/workbench/Deck.ts +++ b/integration-tests/cypress/workbench/Deck.ts @@ -140,7 +140,7 @@ export class Deck { { condition, backgroundColor, color, italic, bold, underline, strikeThrough, fontSize }: ElementStyleProps ) { const details = new Details(); - const objectName = `${condition ? 'Conditional Styles Conditional Deck' : 'Style'} Element Description Style`; + const objectName = `${condition ? 'Conditional Style' : 'Style'} Description`; cy.createChildObject(elementName, objectName); details.openReferenceWidgetOptions('Background Color'); details.selectReferenceWidgetOption(backgroundColor); @@ -162,7 +162,7 @@ export class Deck { public createDeckRepresentationtyle(elementName: string, backgroundColor: string, condition?: string) { const details = new Details(); - const objectName = `${condition ? 'Conditional Styles Conditional Deck' : 'Style'} Description Style`; + const objectName = `${condition ? 'Conditional Style' : 'Style'} Description`; cy.createChildObject(elementName, objectName); details.openReferenceWidgetOptions('Background Color'); details.selectReferenceWidgetOption(backgroundColor); diff --git a/integration-tests/cypress/workbench/Gantt.ts b/integration-tests/cypress/workbench/Gantt.ts index 80a98e2f38..bc70be17b5 100644 --- a/integration-tests/cypress/workbench/Gantt.ts +++ b/integration-tests/cypress/workbench/Gantt.ts @@ -80,7 +80,7 @@ export class GanttTestHelper { } /** - * Creates the Deck Task Sample view from the stereotype. + * Creates the Gantt Task Sample view from the stereotype. * @returns the created studio project id. */ public initGanttView(): Cypress.Chainable { diff --git a/packages/deck/backend/sirius-components-deck/src/main/java/org/eclipse/sirius/components/deck/renderer/component/CardComponent.java b/packages/deck/backend/sirius-components-deck/src/main/java/org/eclipse/sirius/components/deck/renderer/component/CardComponent.java index 8e12d06ea6..f2bcde29ea 100644 --- a/packages/deck/backend/sirius-components-deck/src/main/java/org/eclipse/sirius/components/deck/renderer/component/CardComponent.java +++ b/packages/deck/backend/sirius-components-deck/src/main/java/org/eclipse/sirius/components/deck/renderer/component/CardComponent.java @@ -71,7 +71,7 @@ private Element doRender(VariableManager childVariableManager) { DeckElementStyle style = cardDescription.styleProvider().apply(childVariableManager); Optional optionalPreviousCard = this.props.previousCards().stream() - .filter(card -> card.targetObjectId().equals(targetObjectId)) + .filter(card -> card.descriptionId().equals(cardDescription.id()) && card.targetObjectId().equals(targetObjectId)) .findFirst(); String cardId = optionalPreviousCard.map(Card::id).orElse(UUID.randomUUID().toString()); boolean visible = optionalPreviousCard.map(this::computeVisibility).orElse(true); diff --git a/packages/deck/backend/sirius-components-deck/src/main/java/org/eclipse/sirius/components/deck/renderer/component/LaneComponent.java b/packages/deck/backend/sirius-components-deck/src/main/java/org/eclipse/sirius/components/deck/renderer/component/LaneComponent.java index 5e16e82ac5..907199b0a4 100644 --- a/packages/deck/backend/sirius-components-deck/src/main/java/org/eclipse/sirius/components/deck/renderer/component/LaneComponent.java +++ b/packages/deck/backend/sirius-components-deck/src/main/java/org/eclipse/sirius/components/deck/renderer/component/LaneComponent.java @@ -71,7 +71,9 @@ private Element doRender(VariableManager childVariableManager) { String title = laneDescription.titleProvider().apply(childVariableManager); String label = laneDescription.labelProvider().apply(childVariableManager); - Optional optionalPreviousLane = this.props.previousLanes().stream().filter(lane -> lane.targetObjectId().equals(targetObjectId)).findFirst(); + Optional optionalPreviousLane = this.props.previousLanes().stream() + .filter(lane -> lane.descriptionId().equals(laneDescription.id()) && lane.targetObjectId().equals(targetObjectId)) + .findFirst(); String laneId = optionalPreviousLane.map(Lane::id).orElse(UUID.randomUUID().toString()); List previousCards = optionalPreviousLane.map(Lane::cards).orElse(List.of()); List childrenElements = this.getChildren(childVariableManager, laneDescription, laneId, previousCards); diff --git a/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/TaskExampleBuilder.java b/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/TaskExampleBuilder.java index bf35aef89c..06bda82ad0 100644 --- a/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/TaskExampleBuilder.java +++ b/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/TaskExampleBuilder.java @@ -21,6 +21,8 @@ import org.eclipse.emf.ecore.EObject; import org.eclipse.sirius.components.task.Company; +import org.eclipse.sirius.components.task.KeyResult; +import org.eclipse.sirius.components.task.Objective; import org.eclipse.sirius.components.task.Person; import org.eclipse.sirius.components.task.Project; import org.eclipse.sirius.components.task.Task; @@ -253,36 +255,36 @@ private Project createOKRProject(Person paul, Person peter) { Project okrProject = TaskFactory.eINSTANCE.createProject(); okrProject.setName("OKR Project Dev"); - List okrTags = this.createOKRTags(); - okrProject.getOwnedTags().addAll(okrTags); + Objective objectiveAppicationRunning = TaskFactory.eINSTANCE.createObjective(); + objectiveAppicationRunning.setName("Have the application running"); + + KeyResult keyResultDevCompleted = TaskFactory.eINSTANCE.createKeyResult(); + keyResultDevCompleted.setName("Dev completed"); + keyResultDevCompleted.setDescription("The development is completed"); Task idea = TaskFactory.eINSTANCE.createTask(); idea.setName(IDEA); idea.setStartTime(Instant.parse(DATE_2023_12_10T08_30_00Z)); idea.setEndTime(Instant.parse(DATE_2023_12_11T17_30_00Z)); idea.setProgress(50); - idea.getTags().add(okrTags.get(0)); Task spec = TaskFactory.eINSTANCE.createTask(); spec.setName(SPECIFICATION); spec.setStartTime(Instant.parse(DATE_2023_12_11T08_30_00Z)); spec.setEndTime(Instant.parse(DATE_2023_12_12T17_30_00Z)); spec.setProgress(50); spec.getDependencies().add(idea); - spec.getTags().add(okrTags.get(0)); Task development = TaskFactory.eINSTANCE.createTask(); development.setName(DEVELOPMENT); development.setStartTime(Instant.parse(DATE_2023_12_13T08_30_00Z)); development.setEndTime(Instant.parse(DATE_2023_12_16T17_30_00Z)); development.getDependencies().add(spec); - development.getTags().add(okrTags.get(1)); Task codeDev = TaskFactory.eINSTANCE.createTask(); codeDev.setName(CODE_DEVELOPMENT); codeDev.setStartTime(Instant.parse(DATE_2023_12_13T08_30_00Z)); codeDev.setEndTime(Instant.parse(DATE_2023_12_15T17_30_00Z)); codeDev.getAssignedPersons().add(peter); - codeDev.getTags().add(okrTags.get(2)); Task review = TaskFactory.eINSTANCE.createTask(); review.setName(REVIEW); @@ -290,16 +292,23 @@ private Project createOKRProject(Person paul, Person peter) { review.setEndTime(Instant.parse(DATE_2023_12_16T17_30_00Z)); development.getSubTasks().addAll(List.of(codeDev, review)); codeDev.getAssignedPersons().add(paul); - review.getTags().add(okrTags.get(3)); - Task release = TaskFactory.eINSTANCE.createTask(); - release.setName(RELEASE); - release.setStartTime(Instant.parse(DATE_2023_12_18T08_30_00Z)); - release.setEndTime(Instant.parse(DATE_2023_12_18T08_30_00Z)); - release.getTags().add(okrTags.get(3)); + keyResultDevCompleted.getSubTasks().addAll(List.of(idea, spec, development)); + + KeyResult keyResultTestsOK = TaskFactory.eINSTANCE.createKeyResult(); + keyResultTestsOK.setName("Tests passed"); + keyResultTestsOK.setDescription("The tests are all passed"); + + Task manualsTest = TaskFactory.eINSTANCE.createTask(); + manualsTest.setName("Manual Test Campaign"); + Task automaticTests = TaskFactory.eINSTANCE.createTask(); + manualsTest.setName("Automatic Test Checks"); + + keyResultTestsOK.getSubTasks().addAll(List.of(manualsTest, automaticTests)); + objectiveAppicationRunning.getOwnedKeyResults().addAll(List.of(keyResultDevCompleted, keyResultTestsOK)); + okrProject.getOwnedObjectives().addAll(List.of(objectiveAppicationRunning)); - okrProject.getOwnedTasks().addAll(List.of(idea, spec, development, release)); return okrProject; } @@ -314,17 +323,6 @@ private List createDailyTags() { return tags; } - private List createOKRTags() { - List tags = new ArrayList<>(); - for (int i = 0; i <= 4; i++) { - TaskTag tag = TaskFactory.eINSTANCE.createTaskTag(); - tag.setPrefix("OKR"); - tag.setSuffix(String.format("Objective #%s", i)); - tags.add(tag); - } - return tags; - } - private List createKanbanTags() { List tags = new ArrayList<>(); TaskTag tag = TaskFactory.eINSTANCE.createTaskTag(); diff --git a/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/TaskStereotypeDescriptionRegistryConfigurer.java b/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/TaskStereotypeDescriptionRegistryConfigurer.java index c4fce7ee44..c2f8fa36d0 100644 --- a/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/TaskStereotypeDescriptionRegistryConfigurer.java +++ b/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/TaskStereotypeDescriptionRegistryConfigurer.java @@ -33,7 +33,7 @@ public class TaskStereotypeDescriptionRegistryConfigurer implements IStereotypeD private static final UUID TASK_EXAMPLE_ID = UUID.nameUUIDFromBytes("task_example".getBytes()); - private static final String TASK_EXAMPLE_LABEL = "Task model example"; + private static final String TASK_EXAMPLE_LABEL = "Task Model Sample"; private static final String TIMER_NAME = "siriusweb_stereotype_load"; diff --git a/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewDeckDescriptionBuilder.java b/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewDeckDescriptionBuilder.java index 231e31cc5b..971dd69d5e 100644 --- a/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewDeckDescriptionBuilder.java +++ b/packages/starters/backend/sirius-components-task-starter/src/main/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewDeckDescriptionBuilder.java @@ -12,6 +12,8 @@ *******************************************************************************/ package org.eclipse.sirius.components.task.starter.configuration.view; +import java.util.Arrays; + import org.eclipse.sirius.components.view.ChangeContext; import org.eclipse.sirius.components.view.CreateInstance; import org.eclipse.sirius.components.view.DeleteElement; @@ -45,6 +47,12 @@ public class ViewDeckDescriptionBuilder { private static final String DESCRIPTION = "description"; + private static final String AQL_SELF = "aql:self"; + + private static final String AQL_SELF_NAME = "aql:self.name"; + + private static final String AQL_SELF_DESCRIPTION = "aql:self.description"; + private final DeckBuilders deckBuilders; private final ViewBuilders viewBuilders; @@ -69,15 +77,6 @@ private void createDailyDeckDescription(View view) { view.getDescriptions().add(deckDescription); } - private void createOKRDeckDescription(View view) { - DeckDescription deckDescription = this.createDeckDescription("OKR"); - LaneDescription laneDescription = this.createLaneDescription("OKR"); - CardDescription cardDescription = this.createCardDescription(); - deckDescription.getLaneDescriptions().add(laneDescription); - laneDescription.getOwnedCardDescriptions().add(cardDescription); - view.getDescriptions().add(deckDescription); - } - private void createKanbanDeckDescription(View view) { DeckDescription deckDescription = this.createDeckDescription("Kanban"); LaneDescription laneDescription = this.createLaneDescription("Kanban"); @@ -87,15 +86,29 @@ private void createKanbanDeckDescription(View view) { view.getDescriptions().add(deckDescription); } + private void createOKRDeckDescription(View view) { + DeckDescription deckDescription = this.deckBuilders.newDeckDescription() + .name("Deck OKR Representation") + .domainType("task::Project") + .titleExpression("New OKR Representation") + .build(); + + LaneDescription objectiveLaneDescription = this.createObjectiveLaneDescription(); + LaneDescription keyResultLaneDescription = this.createKeyResultLaneDescription(); + LaneDescription taskLaneDescription = this.createInitiativeLaneDescription(); + deckDescription.getLaneDescriptions().addAll(Arrays.asList(objectiveLaneDescription, keyResultLaneDescription, taskLaneDescription)); + view.getDescriptions().add(deckDescription); + } + private CardDescription createCardDescription() { EditCardTool editCardTool = this.createEditCardTool(); DeleteCardTool deleteCardTool = this.createDeleteCardTool(); return this.deckBuilders.newCardDescription() .name("Card Description") .semanticCandidatesExpression("aql:self.getTasksWithTag()") - .titleExpression("aql:self.name") + .titleExpression(AQL_SELF_NAME) .labelExpression("aql:self.computeTaskDurationDays()") - .descriptionExpression("aql:self.description") + .descriptionExpression(AQL_SELF_DESCRIPTION) .editTool(editCardTool) .deleteTool(deleteCardTool) .build(); @@ -118,6 +131,72 @@ private LaneDescription createLaneDescription(String prefix) { .build(); } + private LaneDescription createObjectiveLaneDescription() { + EditCardTool editCardTool = this.createEditCardTool(); + DeleteCardTool deleteCardTool = this.createDeleteCardTool(); + CardDescription cardDescription = this.deckBuilders.newCardDescription() + .name("Objectives Card") + .semanticCandidatesExpression("aql:self.ownedObjectives") + .titleExpression(AQL_SELF_NAME) + .labelExpression("") + .descriptionExpression(AQL_SELF_DESCRIPTION) + .editTool(editCardTool) + .deleteTool(deleteCardTool) + .build(); + + return this.deckBuilders.newLaneDescription() + .name("Objectives") + .semanticCandidatesExpression(AQL_SELF) + .labelExpression("") + .titleExpression("Objectives") + .ownedCardDescriptions(cardDescription) + .build(); + } + + private LaneDescription createKeyResultLaneDescription() { + EditCardTool editCardTool = this.createEditCardTool(); + DeleteCardTool deleteCardTool = this.createDeleteCardTool(); + CardDescription cardDescription = this.deckBuilders.newCardDescription() + .name("KeyResults Card") + .semanticCandidatesExpression("aql:self.eAllContents(task::KeyResult)") + .titleExpression(AQL_SELF_NAME) + .labelExpression("aql:self.eContainer().name") + .descriptionExpression(AQL_SELF_DESCRIPTION) + .editTool(editCardTool) + .deleteTool(deleteCardTool) + .build(); + + return this.deckBuilders.newLaneDescription() + .name("Key Results") + .semanticCandidatesExpression(AQL_SELF) + .labelExpression("") + .titleExpression("Key Results") + .ownedCardDescriptions(cardDescription) + .build(); + } + + private LaneDescription createInitiativeLaneDescription() { + EditCardTool editCardTool = this.createEditCardTool(); + DeleteCardTool deleteCardTool = this.createDeleteCardTool(); + CardDescription cardDescription = this.deckBuilders.newCardDescription() + .name("Initiatives Card") + .semanticCandidatesExpression("aql:self.eAllContents(task::Task)") + .titleExpression(AQL_SELF_NAME) + .labelExpression("aql:self.eContainer(task::KeyResult).name") + .descriptionExpression(AQL_SELF_DESCRIPTION) + .editTool(editCardTool) + .deleteTool(deleteCardTool) + .build(); + + return this.deckBuilders.newLaneDescription() + .name("Initiatives") + .semanticCandidatesExpression(AQL_SELF) + .labelExpression("") + .titleExpression("Initiatives") + .ownedCardDescriptions(cardDescription) + .build(); + } + private EditLaneTool createEditLaneTool() { SetValue setValue = this.viewBuilders.newSetValue() .featureName("suffix") @@ -187,7 +266,7 @@ private CreateCardTool createCardTool() { Let let = this.viewBuilders.newLet() .variableName("tag") - .valueExpression("aql:self") + .valueExpression(AQL_SELF) .children(projectChangeContext) .build(); diff --git a/packages/starters/backend/sirius-components-task-starter/src/test/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewDeckDescriptionBuilderTests.java b/packages/starters/backend/sirius-components-task-starter/src/test/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewDeckDescriptionBuilderTests.java new file mode 100644 index 0000000000..16dda667d0 --- /dev/null +++ b/packages/starters/backend/sirius-components-task-starter/src/test/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewDeckDescriptionBuilderTests.java @@ -0,0 +1,39 @@ +/******************************************************************************* + * Copyright (c) 2024 Obeo. + * This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v2.0 + * which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-2.0/ + * + * SPDX-License-Identifier: EPL-2.0 + * + * Contributors: + * Obeo - initial API and implementation + *******************************************************************************/ +package org.eclipse.sirius.components.task.starter.configuration.view; + +import static org.assertj.core.api.Assertions.assertThat; + +import org.eclipse.sirius.components.view.View; +import org.eclipse.sirius.components.view.ViewFactory; +import org.junit.jupiter.api.Test; + +/** + * Test used to validate the builder of the "Deck" view description. + * + * @author frouene + */ +class ViewDeckDescriptionBuilderTests { + + @Test + public void testRepresentationDescriptions() { + View view = ViewFactory.eINSTANCE.createView(); + new ViewDeckDescriptionBuilder().addRepresentationDescriptions(view); + + assertThat(view.getDescriptions()).hasSize(3); + assertThat(view.getDescriptions()).anySatisfy(desc -> assertThat(desc.getName()).isEqualTo("Deck Daily Representation")); + assertThat(view.getDescriptions()).anySatisfy(desc -> assertThat(desc.getName()).isEqualTo("Deck OKR Representation")); + assertThat(view.getDescriptions()).anySatisfy(desc -> assertThat(desc.getName()).isEqualTo("Deck Kanban Representation")); + } + +} diff --git a/packages/starters/backend/sirius-components-task-starter/src/test/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewGanttDescriptionBuilderTests.java b/packages/starters/backend/sirius-components-task-starter/src/test/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewGanttDescriptionBuilderTests.java new file mode 100644 index 0000000000..1f46670c04 --- /dev/null +++ b/packages/starters/backend/sirius-components-task-starter/src/test/java/org/eclipse/sirius/components/task/starter/configuration/view/ViewGanttDescriptionBuilderTests.java @@ -0,0 +1,36 @@ +/******************************************************************************* + * Copyright (c) 2024 Obeo. + * This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v2.0 + * which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-2.0/ + * + * SPDX-License-Identifier: EPL-2.0 + * + * Contributors: + * Obeo - initial API and implementation + *******************************************************************************/ +package org.eclipse.sirius.components.task.starter.configuration.view; + +import static org.assertj.core.api.Assertions.assertThat; + +import org.eclipse.sirius.components.view.View; +import org.eclipse.sirius.components.view.ViewFactory; +import org.junit.jupiter.api.Test; + +/** + * Test used to validate the builder of the "Gantt" view description. + * + * @author frouene + */ +class ViewGanttDescriptionBuilderTests { + + @Test + public void testRepresentationDescriptions() { + View view = ViewFactory.eINSTANCE.createView(); + new ViewGanttDescriptionBuilder().addRepresentationDescription(view); + assertThat(view.getDescriptions()).hasSize(1); + assertThat(view.getDescriptions()).anySatisfy(desc -> assertThat(desc.getName()).isEqualTo("Gantt Representation")); + } + +} diff --git a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/CardDropToolBuilder.java b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/CardDropToolBuilder.java index f4449d174d..f768ddbb6d 100644 --- a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/CardDropToolBuilder.java +++ b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/CardDropToolBuilder.java @@ -51,15 +51,6 @@ public CardDropToolBuilder name(java.lang.String value) { this.getCardDropTool().setName(value); return this; } - /** - * Setter for PreconditionExpression. - * - * @generated - */ - public CardDropToolBuilder preconditionExpression(java.lang.String value) { - this.getCardDropTool().setPreconditionExpression(value); - return this; - } /** * Setter for Body. * diff --git a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/CreateCardToolBuilder.java b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/CreateCardToolBuilder.java index 1cd9010cad..183fc0bfe9 100644 --- a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/CreateCardToolBuilder.java +++ b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/CreateCardToolBuilder.java @@ -51,15 +51,6 @@ public CreateCardToolBuilder name(java.lang.String value) { this.getCreateCardTool().setName(value); return this; } - /** - * Setter for PreconditionExpression. - * - * @generated - */ - public CreateCardToolBuilder preconditionExpression(java.lang.String value) { - this.getCreateCardTool().setPreconditionExpression(value); - return this; - } /** * Setter for Body. * diff --git a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckDescriptionBuilder.java b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckDescriptionBuilder.java index c0855e7669..1bcdd8c9a7 100644 --- a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckDescriptionBuilder.java +++ b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckDescriptionBuilder.java @@ -90,16 +90,6 @@ public DeckDescriptionBuilder laneDescriptions(org.eclipse.sirius.components.vie return this; } - /** - * Setter for BackgroundColor. - * - * @generated - */ - public DeckDescriptionBuilder backgroundColor(org.eclipse.sirius.components.view.UserColor value) { - this.getDeckDescription().setBackgroundColor(value); - return this; - } - /** * Setter for LaneDropTool. * diff --git a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckElementDescriptionBuilder.java b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckElementDescriptionBuilder.java index ae322580c3..12a46ad8d2 100644 --- a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckElementDescriptionBuilder.java +++ b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckElementDescriptionBuilder.java @@ -26,15 +26,6 @@ public abstract class DeckElementDescriptionBuilder { */ protected abstract org.eclipse.sirius.components.view.deck.DeckElementDescription getDeckElementDescription(); - /** - * Setter for Name. - * - * @generated - */ - public DeckElementDescriptionBuilder name(java.lang.String value) { - this.getDeckElementDescription().setName(value); - return this; - } /** * Setter for SemanticCandidatesExpression. * diff --git a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckToolBuilder.java b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckToolBuilder.java index 143773c4f4..6d8ccd784d 100644 --- a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckToolBuilder.java +++ b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeckToolBuilder.java @@ -35,15 +35,6 @@ public DeckToolBuilder name(java.lang.String value) { this.getDeckTool().setName(value); return this; } - /** - * Setter for PreconditionExpression. - * - * @generated - */ - public DeckToolBuilder preconditionExpression(java.lang.String value) { - this.getDeckTool().setPreconditionExpression(value); - return this; - } /** * Setter for Body. * diff --git a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeleteCardToolBuilder.java b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeleteCardToolBuilder.java index 4b712f4586..36e3cec269 100644 --- a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeleteCardToolBuilder.java +++ b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/DeleteCardToolBuilder.java @@ -51,15 +51,6 @@ public DeleteCardToolBuilder name(java.lang.String value) { this.getDeleteCardTool().setName(value); return this; } - /** - * Setter for PreconditionExpression. - * - * @generated - */ - public DeleteCardToolBuilder preconditionExpression(java.lang.String value) { - this.getDeleteCardTool().setPreconditionExpression(value); - return this; - } /** * Setter for Body. * diff --git a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/EditCardToolBuilder.java b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/EditCardToolBuilder.java index d1509e19e2..014acff0cf 100644 --- a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/EditCardToolBuilder.java +++ b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/EditCardToolBuilder.java @@ -51,15 +51,6 @@ public EditCardToolBuilder name(java.lang.String value) { this.getEditCardTool().setName(value); return this; } - /** - * Setter for PreconditionExpression. - * - * @generated - */ - public EditCardToolBuilder preconditionExpression(java.lang.String value) { - this.getEditCardTool().setPreconditionExpression(value); - return this; - } /** * Setter for Body. * diff --git a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/EditLaneToolBuilder.java b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/EditLaneToolBuilder.java index ba8d3e7698..936709e088 100644 --- a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/EditLaneToolBuilder.java +++ b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/EditLaneToolBuilder.java @@ -51,15 +51,6 @@ public EditLaneToolBuilder name(java.lang.String value) { this.getEditLaneTool().setName(value); return this; } - /** - * Setter for PreconditionExpression. - * - * @generated - */ - public EditLaneToolBuilder preconditionExpression(java.lang.String value) { - this.getEditLaneTool().setPreconditionExpression(value); - return this; - } /** * Setter for Body. * diff --git a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/LaneDropToolBuilder.java b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/LaneDropToolBuilder.java index 58046d85ca..4a49ad6c54 100644 --- a/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/LaneDropToolBuilder.java +++ b/packages/view/backend/sirius-components-view-builder/src/main/java/org/eclipse/sirius/components/view/builder/generated/LaneDropToolBuilder.java @@ -51,15 +51,6 @@ public LaneDropToolBuilder name(java.lang.String value) { this.getLaneDropTool().setName(value); return this; } - /** - * Setter for PreconditionExpression. - * - * @generated - */ - public LaneDropToolBuilder preconditionExpression(java.lang.String value) { - this.getLaneDropTool().setPreconditionExpression(value); - return this; - } /** * Setter for Body. * diff --git a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/CardDescriptionItemProvider.java b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/CardDescriptionItemProvider.java index c4c80c2556..7c3d44d808 100644 --- a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/CardDescriptionItemProvider.java +++ b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/CardDescriptionItemProvider.java @@ -52,11 +52,23 @@ public List getPropertyDescriptors(Object object) { if (this.itemPropertyDescriptors == null) { super.getPropertyDescriptors(object); + this.addNamePropertyDescriptor(object); this.addDescriptionExpressionPropertyDescriptor(object); } return this.itemPropertyDescriptors; } + /** + * This adds a property descriptor for the Name feature. + * + * @generated + */ + protected void addNamePropertyDescriptor(Object object) { + this.itemPropertyDescriptors.add(this.createItemPropertyDescriptor(((ComposeableAdapterFactory) this.adapterFactory).getRootAdapterFactory(), this.getResourceLocator(), + this.getString("_UI_CardDescription_name_feature"), this.getString("_UI_PropertyDescriptor_description", "_UI_CardDescription_name_feature", "_UI_CardDescription_type"), + DeckPackage.Literals.CARD_DESCRIPTION__NAME, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); + } + /** * This adds a property descriptor for the Description Expression feature. @@ -144,6 +156,7 @@ public void notifyChanged(Notification notification) { this.updateChildren(notification); switch (notification.getFeatureID(CardDescription.class)) { + case DeckPackage.CARD_DESCRIPTION__NAME: case DeckPackage.CARD_DESCRIPTION__DESCRIPTION_EXPRESSION: this.fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); return; @@ -174,18 +187,10 @@ protected void collectNewChildDescriptors(Collection newChildDescriptors * This returns the label text for {@link org.eclipse.emf.edit.command.CreateChildCommand}. * * - * @generated + * @generated NOT */ @Override public String getCreateChildText(Object owner, Object feature, Object child, Collection selection) { - Object childFeature = feature; - Object childObject = child; - - boolean qualify = childFeature == DeckPackage.Literals.DECK_ELEMENT_DESCRIPTION__STYLE || childFeature == DeckPackage.Literals.DECK_ELEMENT_DESCRIPTION__CONDITIONAL_STYLES; - - if (qualify) { - return this.getString("_UI_CreateChild_text2", new Object[] { this.getTypeText(childObject), this.getFeatureText(childFeature), this.getTypeText(owner) }); - } return super.getCreateChildText(owner, feature, child, selection); } diff --git a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckDescriptionItemProvider.java b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckDescriptionItemProvider.java index 8b9f036d0d..cd76ffab33 100644 --- a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckDescriptionItemProvider.java +++ b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckDescriptionItemProvider.java @@ -20,7 +20,6 @@ import org.eclipse.emf.ecore.EStructuralFeature; import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; import org.eclipse.emf.edit.provider.ViewerNotification; -import org.eclipse.sirius.components.view.ViewFactory; import org.eclipse.sirius.components.view.deck.DeckDescription; import org.eclipse.sirius.components.view.deck.DeckFactory; import org.eclipse.sirius.components.view.deck.DeckPackage; @@ -69,7 +68,6 @@ public Collection getChildrenFeatures(Object objec if (this.childrenFeatures == null) { super.getChildrenFeatures(object); this.childrenFeatures.add(DeckPackage.Literals.DECK_DESCRIPTION__LANE_DESCRIPTIONS); - this.childrenFeatures.add(DeckPackage.Literals.DECK_DESCRIPTION__BACKGROUND_COLOR); this.childrenFeatures.add(DeckPackage.Literals.DECK_DESCRIPTION__LANE_DROP_TOOL); this.childrenFeatures.add(DeckPackage.Literals.DECK_DESCRIPTION__STYLE); this.childrenFeatures.add(DeckPackage.Literals.DECK_DESCRIPTION__CONDITIONAL_STYLES); @@ -134,7 +132,6 @@ public void notifyChanged(Notification notification) { switch (notification.getFeatureID(DeckDescription.class)) { case DeckPackage.DECK_DESCRIPTION__LANE_DESCRIPTIONS: - case DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR: case DeckPackage.DECK_DESCRIPTION__LANE_DROP_TOOL: case DeckPackage.DECK_DESCRIPTION__STYLE: case DeckPackage.DECK_DESCRIPTION__CONDITIONAL_STYLES: @@ -156,8 +153,6 @@ protected void collectNewChildDescriptors(Collection newChildDescriptors newChildDescriptors.add(this.createChildParameter(DeckPackage.Literals.DECK_DESCRIPTION__LANE_DESCRIPTIONS, DeckFactory.eINSTANCE.createLaneDescription())); - newChildDescriptors.add(this.createChildParameter(DeckPackage.Literals.DECK_DESCRIPTION__BACKGROUND_COLOR, ViewFactory.eINSTANCE.createFixedColor())); - newChildDescriptors.add(this.createChildParameter(DeckPackage.Literals.DECK_DESCRIPTION__LANE_DROP_TOOL, DeckFactory.eINSTANCE.createLaneDropTool())); newChildDescriptors.add(this.createChildParameter(DeckPackage.Literals.DECK_DESCRIPTION__STYLE, DeckFactory.eINSTANCE.createDeckDescriptionStyle())); @@ -169,18 +164,10 @@ protected void collectNewChildDescriptors(Collection newChildDescriptors * This returns the label text for {@link org.eclipse.emf.edit.command.CreateChildCommand}. * * - * @generated + * @generated NOT */ @Override public String getCreateChildText(Object owner, Object feature, Object child, Collection selection) { - Object childFeature = feature; - Object childObject = child; - - boolean qualify = childFeature == DeckPackage.Literals.DECK_DESCRIPTION__STYLE || childFeature == DeckPackage.Literals.DECK_DESCRIPTION__CONDITIONAL_STYLES; - - if (qualify) { - return this.getString("_UI_CreateChild_text2", new Object[] { this.getTypeText(childObject), this.getFeatureText(childFeature), this.getTypeText(owner) }); - } return super.getCreateChildText(owner, feature, child, selection); } diff --git a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckElementDescriptionItemProvider.java b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckElementDescriptionItemProvider.java index 4406b5bead..eae7d9389a 100644 --- a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckElementDescriptionItemProvider.java +++ b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckElementDescriptionItemProvider.java @@ -61,7 +61,6 @@ public List getPropertyDescriptors(Object object) { if (this.itemPropertyDescriptors == null) { super.getPropertyDescriptors(object); - this.addNamePropertyDescriptor(object); this.addSemanticCandidatesExpressionPropertyDescriptor(object); this.addTitleExpressionPropertyDescriptor(object); this.addLabelExpressionPropertyDescriptor(object); @@ -69,18 +68,6 @@ public List getPropertyDescriptors(Object object) { return this.itemPropertyDescriptors; } - /** - * This adds a property descriptor for the Name feature. - * - * @generated - */ - protected void addNamePropertyDescriptor(Object object) { - this.itemPropertyDescriptors.add(this.createItemPropertyDescriptor(((ComposeableAdapterFactory) this.adapterFactory).getRootAdapterFactory(), this.getResourceLocator(), - this.getString("_UI_DeckElementDescription_name_feature"), - this.getString("_UI_PropertyDescriptor_description", "_UI_DeckElementDescription_name_feature", "_UI_DeckElementDescription_type"), DeckPackage.Literals.DECK_ELEMENT_DESCRIPTION__NAME, - true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - /** * This adds a property descriptor for the Semantic Candidates Expression feature. @@ -166,7 +153,7 @@ protected boolean shouldComposeCreationImage() { */ @Override public String getText(Object object) { - String label = ((DeckElementDescription) object).getName(); + String label = ((DeckElementDescription) object).getSemanticCandidatesExpression(); return label == null || label.length() == 0 ? this.getString("_UI_DeckElementDescription_type") : this.getString("_UI_DeckElementDescription_type") + " " + label; } @@ -182,7 +169,6 @@ public void notifyChanged(Notification notification) { this.updateChildren(notification); switch (notification.getFeatureID(DeckElementDescription.class)) { - case DeckPackage.DECK_ELEMENT_DESCRIPTION__NAME: case DeckPackage.DECK_ELEMENT_DESCRIPTION__SEMANTIC_CANDIDATES_EXPRESSION: case DeckPackage.DECK_ELEMENT_DESCRIPTION__TITLE_EXPRESSION: case DeckPackage.DECK_ELEMENT_DESCRIPTION__LABEL_EXPRESSION: @@ -215,18 +201,10 @@ protected void collectNewChildDescriptors(Collection newChildDescriptors * This returns the label text for {@link org.eclipse.emf.edit.command.CreateChildCommand}. * * - * @generated + * @generated NOT */ @Override public String getCreateChildText(Object owner, Object feature, Object child, Collection selection) { - Object childFeature = feature; - Object childObject = child; - - boolean qualify = childFeature == DeckPackage.Literals.DECK_ELEMENT_DESCRIPTION__STYLE || childFeature == DeckPackage.Literals.DECK_ELEMENT_DESCRIPTION__CONDITIONAL_STYLES; - - if (qualify) { - return this.getString("_UI_CreateChild_text2", new Object[] { this.getTypeText(childObject), this.getFeatureText(childFeature), this.getTypeText(owner) }); - } return super.getCreateChildText(owner, feature, child, selection); } diff --git a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckToolItemProvider.java b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckToolItemProvider.java index 6cb444ae6a..50f8c45715 100644 --- a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckToolItemProvider.java +++ b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/DeckToolItemProvider.java @@ -61,7 +61,6 @@ public List getPropertyDescriptors(Object object) { super.getPropertyDescriptors(object); this.addNamePropertyDescriptor(object); - this.addPreconditionExpressionPropertyDescriptor(object); } return this.itemPropertyDescriptors; } @@ -77,18 +76,6 @@ protected void addNamePropertyDescriptor(Object object) { DeckPackage.Literals.DECK_TOOL__NAME, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); } - /** - * This adds a property descriptor for the Precondition Expression feature. - * - * @generated - */ - protected void addPreconditionExpressionPropertyDescriptor(Object object) { - this.itemPropertyDescriptors.add(this.createItemPropertyDescriptor(((ComposeableAdapterFactory) this.adapterFactory).getRootAdapterFactory(), this.getResourceLocator(), - this.getString("_UI_DeckTool_preconditionExpression_feature"), this.getString("_UI_PropertyDescriptor_description", "_UI_DeckTool_preconditionExpression_feature", "_UI_DeckTool_type"), - DeckPackage.Literals.DECK_TOOL__PRECONDITION_EXPRESSION, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); - } - /** * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or @@ -153,7 +140,6 @@ public void notifyChanged(Notification notification) { switch (notification.getFeatureID(DeckTool.class)) { case DeckPackage.DECK_TOOL__NAME: - case DeckPackage.DECK_TOOL__PRECONDITION_EXPRESSION: this.fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); return; case DeckPackage.DECK_TOOL__BODY: diff --git a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/LaneDescriptionItemProvider.java b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/LaneDescriptionItemProvider.java index b28b3f3160..688c550efa 100644 --- a/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/LaneDescriptionItemProvider.java +++ b/packages/view/backend/sirius-components-view-deck-edit/src/main/java/org/eclipse/sirius/components/view/deck/provider/LaneDescriptionItemProvider.java @@ -52,11 +52,23 @@ public List getPropertyDescriptors(Object object) { if (this.itemPropertyDescriptors == null) { super.getPropertyDescriptors(object); + this.addNamePropertyDescriptor(object); this.addIsCollapsibleExpressionPropertyDescriptor(object); } return this.itemPropertyDescriptors; } + /** + * This adds a property descriptor for the Name feature. + * + * @generated + */ + protected void addNamePropertyDescriptor(Object object) { + this.itemPropertyDescriptors.add(this.createItemPropertyDescriptor(((ComposeableAdapterFactory) this.adapterFactory).getRootAdapterFactory(), this.getResourceLocator(), + this.getString("_UI_LaneDescription_name_feature"), this.getString("_UI_PropertyDescriptor_description", "_UI_LaneDescription_name_feature", "_UI_LaneDescription_type"), + DeckPackage.Literals.LANE_DESCRIPTION__NAME, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); + } + /** * This adds a property descriptor for the Is Collapsible Expression feature. @@ -146,6 +158,7 @@ public void notifyChanged(Notification notification) { this.updateChildren(notification); switch (notification.getFeatureID(LaneDescription.class)) { + case DeckPackage.LANE_DESCRIPTION__NAME: case DeckPackage.LANE_DESCRIPTION__IS_COLLAPSIBLE_EXPRESSION: this.fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); return; @@ -163,12 +176,10 @@ public void notifyChanged(Notification notification) { * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children that can be created * under this object. * - * @generated + * @generated NOT */ @Override protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - newChildDescriptors.add(this.createChildParameter(DeckPackage.Literals.LANE_DESCRIPTION__OWNED_CARD_DESCRIPTIONS, DeckFactory.eINSTANCE.createCardDescription())); newChildDescriptors.add(this.createChildParameter(DeckPackage.Literals.LANE_DESCRIPTION__EDIT_TOOL, DeckFactory.eINSTANCE.createEditLaneTool())); @@ -176,24 +187,18 @@ protected void collectNewChildDescriptors(Collection newChildDescriptors newChildDescriptors.add(this.createChildParameter(DeckPackage.Literals.LANE_DESCRIPTION__CREATE_TOOL, DeckFactory.eINSTANCE.createCreateCardTool())); newChildDescriptors.add(this.createChildParameter(DeckPackage.Literals.LANE_DESCRIPTION__CARD_DROP_TOOL, DeckFactory.eINSTANCE.createCardDropTool())); + + super.collectNewChildDescriptors(newChildDescriptors, object); } /** * This returns the label text for {@link org.eclipse.emf.edit.command.CreateChildCommand}. * * - * @generated + * @generated NOT */ @Override public String getCreateChildText(Object owner, Object feature, Object child, Collection selection) { - Object childFeature = feature; - Object childObject = child; - - boolean qualify = childFeature == DeckPackage.Literals.DECK_ELEMENT_DESCRIPTION__STYLE || childFeature == DeckPackage.Literals.DECK_ELEMENT_DESCRIPTION__CONDITIONAL_STYLES; - - if (qualify) { - return this.getString("_UI_CreateChild_text2", new Object[] { this.getTypeText(childObject), this.getFeatureText(childFeature), this.getTypeText(owner) }); - } return super.getCreateChildText(owner, feature, child, selection); } diff --git a/packages/view/backend/sirius-components-view-deck-edit/src/main/resources/plugin.properties b/packages/view/backend/sirius-components-view-deck-edit/src/main/resources/plugin.properties index bb2000fb20..c637e8d07f 100644 --- a/packages/view/backend/sirius-components-view-deck-edit/src/main/resources/plugin.properties +++ b/packages/view/backend/sirius-components-view-deck-edit/src/main/resources/plugin.properties @@ -32,10 +32,10 @@ _UI_EditLaneTool_type = Edit Lane Tool _UI_CardDropTool_type = Card Drop Tool _UI_LaneDropTool_type = Lane Drop Tool _UI_DeckElementDescription_type = Element Description -_UI_DeckDescriptionStyle_type = Description Style -_UI_ConditionalDeckDescriptionStyle_type = Conditional Deck Description Style -_UI_DeckElementDescriptionStyle_type = Element Description Style -_UI_ConditionalDeckElementDescriptionStyle_type = Conditional Deck Element Description Style +_UI_DeckDescriptionStyle_type = Style Description +_UI_ConditionalDeckDescriptionStyle_type = Conditional Style Description +_UI_DeckElementDescriptionStyle_type = Style Description +_UI_ConditionalDeckElementDescriptionStyle_type = Conditional Style Description _UI_Unknown_type = Object _UI_Unknown_datatype= Value @@ -45,18 +45,18 @@ _UI_DeckDescription_backgroundColor_feature = Background Color _UI_DeckDescription_laneDropTool_feature = Lane Drop Tool _UI_DeckDescription_style_feature = Style _UI_DeckDescription_conditionalStyles_feature = Conditional Styles +_UI_LaneDescription_name_feature = Name _UI_LaneDescription_ownedCardDescriptions_feature = Owned Card Descriptions _UI_LaneDescription_editTool_feature = Edit Tool _UI_LaneDescription_createTool_feature = Create Tool _UI_LaneDescription_cardDropTool_feature = Card Drop Tool _UI_LaneDescription_isCollapsibleExpression_feature = Is Collapsible Expression +_UI_CardDescription_name_feature = Name _UI_CardDescription_descriptionExpression_feature = Description Expression _UI_CardDescription_editTool_feature = Edit Tool _UI_CardDescription_deleteTool_feature = Delete Tool _UI_DeckTool_name_feature = Name -_UI_DeckTool_preconditionExpression_feature = Precondition Expression _UI_DeckTool_body_feature = Body -_UI_DeckElementDescription_name_feature = Name _UI_DeckElementDescription_semanticCandidatesExpression_feature = Semantic Candidates Expression _UI_DeckElementDescription_titleExpression_feature = Title Expression _UI_DeckElementDescription_labelExpression_feature = Label Expression diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/CardDescription.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/CardDescription.java index fdb53830a6..989c290645 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/CardDescription.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/CardDescription.java @@ -33,6 +33,29 @@ * @generated */ public interface CardDescription extends DeckElementDescription { + /** + * Returns the value of the 'Name' attribute. The default value is + * "New Card Description". + * + * @return the value of the 'Name' attribute. + * @see #setName(String) + * @see org.eclipse.sirius.components.view.deck.DeckPackage#getCardDescription_Name() + * @model default="New Card Description" dataType="org.eclipse.sirius.components.view.Identifier" + * @generated + */ + String getName(); + + /** + * Sets the value of the '{@link org.eclipse.sirius.components.view.deck.CardDescription#getName Name}' + * attribute. + * + * @param value + * the new value of the 'Name' attribute. + * @see #getName() + * @generated + */ + void setName(String value); + /** * Returns the value of the 'Description Expression' attribute. The default value is * "aql:self". diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckDescription.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckDescription.java index d701ad08c5..b7cc022f68 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckDescription.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckDescription.java @@ -14,7 +14,6 @@ import org.eclipse.emf.common.util.EList; import org.eclipse.sirius.components.view.RepresentationDescription; -import org.eclipse.sirius.components.view.UserColor; /** * A representation of the model object 'Description'. @@ -25,7 +24,6 @@ *
    *
  • {@link org.eclipse.sirius.components.view.deck.DeckDescription#getLaneDescriptions Lane * Descriptions}
  • - *
  • {@link org.eclipse.sirius.components.view.deck.DeckDescription#getBackgroundColor Background Color}
  • *
  • {@link org.eclipse.sirius.components.view.deck.DeckDescription#getLaneDropTool Lane Drop Tool}
  • *
  • {@link org.eclipse.sirius.components.view.deck.DeckDescription#getStyle Style}
  • *
  • {@link org.eclipse.sirius.components.view.deck.DeckDescription#getConditionalStyles Conditional @@ -49,29 +47,6 @@ public interface DeckDescription extends RepresentationDescription { */ EList getLaneDescriptions(); - /** - * Returns the value of the 'Background Color' containment reference. - * - * @return the value of the 'Background Color' containment reference. - * @see #setBackgroundColor(UserColor) - * @see org.eclipse.sirius.components.view.deck.DeckPackage#getDeckDescription_BackgroundColor() - * @model containment="true" - * @generated - */ - UserColor getBackgroundColor(); - - /** - * Sets the value of the '{@link org.eclipse.sirius.components.view.deck.DeckDescription#getBackgroundColor - * Background Color}' containment reference. - * - * @param value - * the new value of the 'Background Color' containment reference. - * @see #getBackgroundColor() - * @generated - */ - void setBackgroundColor(UserColor value); - /** * Returns the value of the 'Lane Drop Tool' containment reference. diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckElementDescription.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckElementDescription.java index 86b0bf314b..a6ee7c2328 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckElementDescription.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckElementDescription.java @@ -37,29 +37,6 @@ * @generated */ public interface DeckElementDescription extends EObject { - /** - * Returns the value of the 'Name' attribute. The default value is - * "newDeckElementDescription". - * - * @return the value of the 'Name' attribute. - * @see #setName(String) - * @see org.eclipse.sirius.components.view.deck.DeckPackage#getDeckElementDescription_Name() - * @model default="newDeckElementDescription" dataType="org.eclipse.sirius.components.view.Identifier" - * @generated - */ - String getName(); - - /** - * Sets the value of the '{@link org.eclipse.sirius.components.view.deck.DeckElementDescription#getName - * Name}' attribute. - * - * @param value - * the new value of the 'Name' attribute. - * @see #getName() - * @generated - */ - void setName(String value); - /** * Returns the value of the 'Semantic Candidates Expression' attribute. The default value is * "aql:self". diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckPackage.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckPackage.java index 3f86f16357..21d2c59e78 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckPackage.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckPackage.java @@ -115,15 +115,6 @@ public interface DeckPackage extends EPackage { */ int DECK_DESCRIPTION__LANE_DESCRIPTIONS = ViewPackage.REPRESENTATION_DESCRIPTION_FEATURE_COUNT + 0; - /** - * The feature id for the 'Background Color' containment reference. - * - * @generated - * @ordered - */ - int DECK_DESCRIPTION__BACKGROUND_COLOR = ViewPackage.REPRESENTATION_DESCRIPTION_FEATURE_COUNT + 1; - /** * The feature id for the 'Lane Drop Tool' containment reference. @@ -131,7 +122,7 @@ public interface DeckPackage extends EPackage { * @generated * @ordered */ - int DECK_DESCRIPTION__LANE_DROP_TOOL = ViewPackage.REPRESENTATION_DESCRIPTION_FEATURE_COUNT + 2; + int DECK_DESCRIPTION__LANE_DROP_TOOL = ViewPackage.REPRESENTATION_DESCRIPTION_FEATURE_COUNT + 1; /** * The feature id for the 'Style' containment reference. @@ -149,7 +140,7 @@ public interface DeckPackage extends EPackage { * @generated * @ordered */ - int DECK_DESCRIPTION__CONDITIONAL_STYLES = ViewPackage.REPRESENTATION_DESCRIPTION_FEATURE_COUNT + 4; + int DECK_DESCRIPTION__CONDITIONAL_STYLES = ViewPackage.REPRESENTATION_DESCRIPTION_FEATURE_COUNT + 3; /** * The number of structural features of the 'Description' class. @@ -178,14 +169,6 @@ public interface DeckPackage extends EPackage { */ int DECK_ELEMENT_DESCRIPTION = 10; - /** - * The feature id for the 'Name' attribute. - * - * @generated - * @ordered - */ - int DECK_ELEMENT_DESCRIPTION__NAME = 0; - /** * The feature id for the 'Semantic Candidates Expression' attribute. @@ -193,7 +176,7 @@ public interface DeckPackage extends EPackage { * @generated * @ordered */ - int DECK_ELEMENT_DESCRIPTION__SEMANTIC_CANDIDATES_EXPRESSION = 1; + int DECK_ELEMENT_DESCRIPTION__SEMANTIC_CANDIDATES_EXPRESSION = 0; /** * The feature id for the 'Title Expression' attribute. @@ -229,7 +212,7 @@ public interface DeckPackage extends EPackage { * @generated * @ordered */ - int DECK_ELEMENT_DESCRIPTION__CONDITIONAL_STYLES = 5; + int DECK_ELEMENT_DESCRIPTION__CONDITIONAL_STYLES = 4; /** * The number of structural features of the 'Element Description' class. - * - * @generated - * @ordered - */ - int LANE_DESCRIPTION__NAME = DECK_ELEMENT_DESCRIPTION__NAME; - /** * The feature id for the 'Semantic Candidates Expression' attribute. @@ -312,6 +287,14 @@ public interface DeckPackage extends EPackage { */ int LANE_DESCRIPTION__CONDITIONAL_STYLES = DECK_ELEMENT_DESCRIPTION__CONDITIONAL_STYLES; + /** + * The feature id for the 'Name' attribute. + * + * @generated + * @ordered + */ + int LANE_DESCRIPTION__NAME = DECK_ELEMENT_DESCRIPTION_FEATURE_COUNT + 0; + /** * The feature id for the 'Owned Card Descriptions' containment reference list. @@ -319,7 +302,7 @@ public interface DeckPackage extends EPackage { * @generated * @ordered */ - int LANE_DESCRIPTION__OWNED_CARD_DESCRIPTIONS = DECK_ELEMENT_DESCRIPTION_FEATURE_COUNT + 0; + int LANE_DESCRIPTION__OWNED_CARD_DESCRIPTIONS = DECK_ELEMENT_DESCRIPTION_FEATURE_COUNT + 1; /** * The feature id for the 'Edit Tool' containment reference. @@ -384,14 +367,6 @@ public interface DeckPackage extends EPackage { */ int CARD_DESCRIPTION = 2; - /** - * The feature id for the 'Name' attribute. - * - * @generated - * @ordered - */ - int CARD_DESCRIPTION__NAME = DECK_ELEMENT_DESCRIPTION__NAME; - /** * The feature id for the 'Semantic Candidates Expression' attribute. @@ -437,6 +412,14 @@ public interface DeckPackage extends EPackage { */ int CARD_DESCRIPTION__CONDITIONAL_STYLES = DECK_ELEMENT_DESCRIPTION__CONDITIONAL_STYLES; + /** + * The feature id for the 'Name' attribute. + * + * @generated + * @ordered + */ + int CARD_DESCRIPTION__NAME = DECK_ELEMENT_DESCRIPTION_FEATURE_COUNT + 0; + /** * The feature id for the 'Description Expression' attribute. @@ -444,7 +427,7 @@ public interface DeckPackage extends EPackage { * @generated * @ordered */ - int CARD_DESCRIPTION__DESCRIPTION_EXPRESSION = DECK_ELEMENT_DESCRIPTION_FEATURE_COUNT + 0; + int CARD_DESCRIPTION__DESCRIPTION_EXPRESSION = DECK_ELEMENT_DESCRIPTION_FEATURE_COUNT + 1; /** * The feature id for the 'Edit Tool' containment reference. @@ -499,15 +482,6 @@ public interface DeckPackage extends EPackage { */ int DECK_TOOL__NAME = 0; - /** - * The feature id for the 'Precondition Expression' attribute. - * - * @generated - * @ordered - */ - int DECK_TOOL__PRECONDITION_EXPRESSION = 1; - /** * The feature id for the 'Body' containment reference list. @@ -515,7 +489,7 @@ public interface DeckPackage extends EPackage { * @generated * @ordered */ - int DECK_TOOL__BODY = 2; + int DECK_TOOL__BODY = 1; /** * The number of structural features of the 'Tool' class. @@ -523,7 +497,7 @@ public interface DeckPackage extends EPackage { * @generated * @ordered */ - int DECK_TOOL_FEATURE_COUNT = 3; + int DECK_TOOL_FEATURE_COUNT = 2; /** * The number of operations of the 'Tool' class. @@ -551,15 +525,6 @@ public interface DeckPackage extends EPackage { */ int CREATE_CARD_TOOL__NAME = DECK_TOOL__NAME; - /** - * The feature id for the 'Precondition Expression' attribute. - * - * @generated - * @ordered - */ - int CREATE_CARD_TOOL__PRECONDITION_EXPRESSION = DECK_TOOL__PRECONDITION_EXPRESSION; - /** * The feature id for the 'Body' containment reference list. @@ -604,15 +569,6 @@ public interface DeckPackage extends EPackage { */ int EDIT_CARD_TOOL__NAME = DECK_TOOL__NAME; - /** - * The feature id for the 'Precondition Expression' attribute. - * - * @generated - * @ordered - */ - int EDIT_CARD_TOOL__PRECONDITION_EXPRESSION = DECK_TOOL__PRECONDITION_EXPRESSION; - /** * The feature id for the 'Body' containment reference list. @@ -657,15 +613,6 @@ public interface DeckPackage extends EPackage { */ int DELETE_CARD_TOOL__NAME = DECK_TOOL__NAME; - /** - * The feature id for the 'Precondition Expression' attribute. - * - * @generated - * @ordered - */ - int DELETE_CARD_TOOL__PRECONDITION_EXPRESSION = DECK_TOOL__PRECONDITION_EXPRESSION; - /** * The feature id for the 'Body' containment reference list. @@ -710,15 +657,6 @@ public interface DeckPackage extends EPackage { */ int EDIT_LANE_TOOL__NAME = DECK_TOOL__NAME; - /** - * The feature id for the 'Precondition Expression' attribute. - * - * @generated - * @ordered - */ - int EDIT_LANE_TOOL__PRECONDITION_EXPRESSION = DECK_TOOL__PRECONDITION_EXPRESSION; - /** * The feature id for the 'Body' containment reference list. @@ -763,15 +701,6 @@ public interface DeckPackage extends EPackage { */ int CARD_DROP_TOOL__NAME = DECK_TOOL__NAME; - /** - * The feature id for the 'Precondition Expression' attribute. - * - * @generated - * @ordered - */ - int CARD_DROP_TOOL__PRECONDITION_EXPRESSION = DECK_TOOL__PRECONDITION_EXPRESSION; - /** * The feature id for the 'Body' containment reference list. @@ -816,15 +745,6 @@ public interface DeckPackage extends EPackage { */ int LANE_DROP_TOOL__NAME = DECK_TOOL__NAME; - /** - * The feature id for the 'Precondition Expression' attribute. - * - * @generated - * @ordered - */ - int LANE_DROP_TOOL__PRECONDITION_EXPRESSION = DECK_TOOL__PRECONDITION_EXPRESSION; - /** * The feature id for the 'Body' containment reference list. @@ -1134,18 +1054,6 @@ public interface DeckPackage extends EPackage { */ EReference getDeckDescription_LaneDescriptions(); - /** - * Returns the meta object for the containment reference - * '{@link org.eclipse.sirius.components.view.deck.DeckDescription#getBackgroundColor Background Color}'. - * - * - * @return the meta object for the containment reference 'Background Color'. - * @see org.eclipse.sirius.components.view.deck.DeckDescription#getBackgroundColor() - * @see #getDeckDescription() - * @generated - */ - EReference getDeckDescription_BackgroundColor(); - /** * Returns the meta object for the containment reference * '{@link org.eclipse.sirius.components.view.deck.DeckDescription#getLaneDropTool Lane Drop Tool}'. + * + * @return the meta object for the attribute 'Name'. + * @see org.eclipse.sirius.components.view.deck.LaneDescription#getName() + * @see #getLaneDescription() + * @generated + */ + EAttribute getLaneDescription_Name(); + /** * Returns the meta object for the containment reference list * '{@link org.eclipse.sirius.components.view.deck.LaneDescription#getOwnedCardDescriptions Owned Card @@ -1262,6 +1181,17 @@ public interface DeckPackage extends EPackage { */ EClass getCardDescription(); + /** + * Returns the meta object for the attribute '{@link org.eclipse.sirius.components.view.deck.CardDescription#getName + * Name}'. + * + * @return the meta object for the attribute 'Name'. + * @see org.eclipse.sirius.components.view.deck.CardDescription#getName() + * @see #getCardDescription() + * @generated + */ + EAttribute getCardDescription_Name(); + /** * Returns the meta object for the attribute * '{@link org.eclipse.sirius.components.view.deck.CardDescription#getDescriptionExpression Description @@ -1319,18 +1249,6 @@ public interface DeckPackage extends EPackage { */ EAttribute getDeckTool_Name(); - /** - * Returns the meta object for the attribute - * '{@link org.eclipse.sirius.components.view.deck.DeckTool#getPreconditionExpression Precondition - * Expression}'. - * - * @return the meta object for the attribute 'Precondition Expression'. - * @see org.eclipse.sirius.components.view.deck.DeckTool#getPreconditionExpression() - * @see #getDeckTool() - * @generated - */ - EAttribute getDeckTool_PreconditionExpression(); - /** * Returns the meta object for the containment reference list * '{@link org.eclipse.sirius.components.view.deck.DeckTool#getBody Body}'. - * - * @return the meta object for the attribute 'Name'. - * @see org.eclipse.sirius.components.view.deck.DeckElementDescription#getName() - * @see #getDeckElementDescription() - * @generated - */ - EAttribute getDeckElementDescription_Name(); - /** * Returns the meta object for the attribute * '{@link org.eclipse.sirius.components.view.deck.DeckElementDescription#getSemanticCandidatesExpression @@ -1602,14 +1508,6 @@ interface Literals { */ EReference DECK_DESCRIPTION__LANE_DESCRIPTIONS = eINSTANCE.getDeckDescription_LaneDescriptions(); - /** - * The meta object literal for the 'Background Color' containment reference feature. - * - * @generated - */ - EReference DECK_DESCRIPTION__BACKGROUND_COLOR = eINSTANCE.getDeckDescription_BackgroundColor(); - /** * The meta object literal for the 'Lane Drop Tool' containment reference feature. @@ -1644,6 +1542,14 @@ interface Literals { */ EClass LANE_DESCRIPTION = eINSTANCE.getLaneDescription(); + /** + * The meta object literal for the 'Name' attribute feature. + * + * @generated + */ + EAttribute LANE_DESCRIPTION__NAME = eINSTANCE.getLaneDescription_Name(); + /** * The meta object literal for the 'Owned Card Descriptions' containment reference list feature. * @@ -1694,6 +1600,14 @@ interface Literals { */ EClass CARD_DESCRIPTION = eINSTANCE.getCardDescription(); + /** + * The meta object literal for the 'Name' attribute feature. + * + * @generated + */ + EAttribute CARD_DESCRIPTION__NAME = eINSTANCE.getCardDescription_Name(); + /** * The meta object literal for the 'Description Expression' attribute feature. @@ -1736,14 +1650,6 @@ interface Literals { */ EAttribute DECK_TOOL__NAME = eINSTANCE.getDeckTool_Name(); - /** - * The meta object literal for the 'Precondition Expression' attribute feature. - * - * @generated - */ - EAttribute DECK_TOOL__PRECONDITION_EXPRESSION = eINSTANCE.getDeckTool_PreconditionExpression(); - /** * The meta object literal for the 'Body' containment reference list feature. @@ -1823,14 +1729,6 @@ interface Literals { */ EClass DECK_ELEMENT_DESCRIPTION = eINSTANCE.getDeckElementDescription(); - /** - * The meta object literal for the 'Name' attribute feature. - * - * @generated - */ - EAttribute DECK_ELEMENT_DESCRIPTION__NAME = eINSTANCE.getDeckElementDescription_Name(); - /** * The meta object literal for the 'Semantic Candidates Expression' attribute feature. diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckTool.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckTool.java index 9893a3fba3..b5cfb564f1 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckTool.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/DeckTool.java @@ -24,8 +24,6 @@ *

    *
      *
    • {@link org.eclipse.sirius.components.view.deck.DeckTool#getName Name}
    • - *
    • {@link org.eclipse.sirius.components.view.deck.DeckTool#getPreconditionExpression Precondition - * Expression}
    • *
    • {@link org.eclipse.sirius.components.view.deck.DeckTool#getBody Body}
    • *
    * @@ -56,29 +54,6 @@ public interface DeckTool extends EObject { */ void setName(String value); - /** - * Returns the value of the 'Precondition Expression' attribute. - * - * @return the value of the 'Precondition Expression' attribute. - * @see #setPreconditionExpression(String) - * @see org.eclipse.sirius.components.view.deck.DeckPackage#getDeckTool_PreconditionExpression() - * @model dataType="org.eclipse.sirius.components.view.InterpretedExpression" - * @generated - */ - String getPreconditionExpression(); - - /** - * Sets the value of the '{@link org.eclipse.sirius.components.view.deck.DeckTool#getPreconditionExpression - * Precondition Expression}' attribute. - * - * @param value - * the new value of the 'Precondition Expression' attribute. - * @see #getPreconditionExpression() - * @generated - */ - void setPreconditionExpression(String value); - /** * Returns the value of the 'Body' containment reference list. The list contents are of type * {@link org.eclipse.sirius.components.view.Operation}. diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/LaneDescription.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/LaneDescription.java index 65b2ea5d95..19c0ed9a7c 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/LaneDescription.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/LaneDescription.java @@ -37,6 +37,29 @@ * @generated */ public interface LaneDescription extends DeckElementDescription { + /** + * Returns the value of the 'Name' attribute. The default value is + * "New Lane Description". + * + * @return the value of the 'Name' attribute. + * @see #setName(String) + * @see org.eclipse.sirius.components.view.deck.DeckPackage#getLaneDescription_Name() + * @model default="New Lane Description" dataType="org.eclipse.sirius.components.view.Identifier" + * @generated + */ + String getName(); + + /** + * Sets the value of the '{@link org.eclipse.sirius.components.view.deck.LaneDescription#getName Name}' + * attribute. + * + * @param value + * the new value of the 'Name' attribute. + * @see #getName() + * @generated + */ + void setName(String value); + /** * Returns the value of the 'Owned Card Descriptions' containment reference list. The list contents * are of type {@link org.eclipse.sirius.components.view.deck.CardDescription}. + * + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = "New Card Description"; + + /** + * The cached value of the '{@link #getName() Name}' attribute. + * + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + /** * The default value of the '{@link #getDescriptionExpression() Description Expression}' attribute. @@ -100,6 +120,29 @@ protected EClass eStaticClass() { return DeckPackage.Literals.CARD_DESCRIPTION; } + /** + * + * + * @generated + */ + @Override + public String getName() { + return this.name; + } + + /** + * + * + * @generated + */ + @Override + public void setName(String newName) { + String oldName = this.name; + this.name = newName; + if (this.eNotificationRequired()) + this.eNotify(new ENotificationImpl(this, Notification.SET, DeckPackage.CARD_DESCRIPTION__NAME, oldName, this.name)); + } + /** * * @@ -243,6 +286,8 @@ public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { + case DeckPackage.CARD_DESCRIPTION__NAME: + return this.getName(); case DeckPackage.CARD_DESCRIPTION__DESCRIPTION_EXPRESSION: return this.getDescriptionExpression(); case DeckPackage.CARD_DESCRIPTION__EDIT_TOOL: @@ -262,6 +307,9 @@ public Object eGet(int featureID, boolean resolve, boolean coreType) { @Override public void eSet(int featureID, Object newValue) { switch (featureID) { + case DeckPackage.CARD_DESCRIPTION__NAME: + this.setName((String) newValue); + return; case DeckPackage.CARD_DESCRIPTION__DESCRIPTION_EXPRESSION: this.setDescriptionExpression((String) newValue); return; @@ -283,6 +331,9 @@ public void eSet(int featureID, Object newValue) { @Override public void eUnset(int featureID) { switch (featureID) { + case DeckPackage.CARD_DESCRIPTION__NAME: + this.setName(NAME_EDEFAULT); + return; case DeckPackage.CARD_DESCRIPTION__DESCRIPTION_EXPRESSION: this.setDescriptionExpression(DESCRIPTION_EXPRESSION_EDEFAULT); return; @@ -304,6 +355,8 @@ public void eUnset(int featureID) { @Override public boolean eIsSet(int featureID) { switch (featureID) { + case DeckPackage.CARD_DESCRIPTION__NAME: + return NAME_EDEFAULT == null ? this.name != null : !NAME_EDEFAULT.equals(this.name); case DeckPackage.CARD_DESCRIPTION__DESCRIPTION_EXPRESSION: return DESCRIPTION_EXPRESSION_EDEFAULT == null ? this.descriptionExpression != null : !DESCRIPTION_EXPRESSION_EDEFAULT.equals(this.descriptionExpression); case DeckPackage.CARD_DESCRIPTION__EDIT_TOOL: @@ -325,7 +378,9 @@ public String toString() { return super.toString(); StringBuilder result = new StringBuilder(super.toString()); - result.append(" (descriptionExpression: "); + result.append(" (name: "); + result.append(this.name); + result.append(", descriptionExpression: "); result.append(this.descriptionExpression); result.append(')'); return result.toString(); diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckDescriptionImpl.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckDescriptionImpl.java index bb180d2133..8d1b26ae77 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckDescriptionImpl.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckDescriptionImpl.java @@ -22,7 +22,6 @@ import org.eclipse.emf.ecore.impl.ENotificationImpl; import org.eclipse.emf.ecore.util.EObjectContainmentEList; import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.sirius.components.view.UserColor; import org.eclipse.sirius.components.view.deck.ConditionalDeckDescriptionStyle; import org.eclipse.sirius.components.view.deck.DeckDescription; import org.eclipse.sirius.components.view.deck.DeckDescriptionStyle; @@ -39,8 +38,6 @@ *
      *
    • {@link org.eclipse.sirius.components.view.deck.impl.DeckDescriptionImpl#getLaneDescriptions Lane * Descriptions}
    • - *
    • {@link org.eclipse.sirius.components.view.deck.impl.DeckDescriptionImpl#getBackgroundColor Background - * Color}
    • *
    • {@link org.eclipse.sirius.components.view.deck.impl.DeckDescriptionImpl#getLaneDropTool Lane Drop * Tool}
    • *
    • {@link org.eclipse.sirius.components.view.deck.impl.DeckDescriptionImpl#getStyle Style}
    • @@ -61,16 +58,6 @@ public class DeckDescriptionImpl extends RepresentationDescriptionImpl implement */ protected EList laneDescriptions; - /** - * The cached value of the '{@link #getBackgroundColor() Background Color}' containment reference. - * - * @see #getBackgroundColor() - * @generated - * @ordered - */ - protected UserColor backgroundColor; - /** * The cached value of the '{@link #getLaneDropTool() Lane Drop Tool}' containment reference. @@ -133,54 +120,6 @@ public EList getLaneDescriptions() { return this.laneDescriptions; } - /** - * - * - * @generated - */ - @Override - public UserColor getBackgroundColor() { - return this.backgroundColor; - } - - /** - * - * - * @generated - */ - public NotificationChain basicSetBackgroundColor(UserColor newBackgroundColor, NotificationChain msgs) { - UserColor oldBackgroundColor = this.backgroundColor; - this.backgroundColor = newBackgroundColor; - if (this.eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR, oldBackgroundColor, newBackgroundColor); - if (msgs == null) - msgs = notification; - else - msgs.add(notification); - } - return msgs; - } - - /** - * - * - * @generated - */ - @Override - public void setBackgroundColor(UserColor newBackgroundColor) { - if (newBackgroundColor != this.backgroundColor) { - NotificationChain msgs = null; - if (this.backgroundColor != null) - msgs = ((InternalEObject) this.backgroundColor).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR, null, msgs); - if (newBackgroundColor != null) - msgs = ((InternalEObject) newBackgroundColor).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR, null, msgs); - msgs = this.basicSetBackgroundColor(newBackgroundColor, msgs); - if (msgs != null) - msgs.dispatch(); - } else if (this.eNotificationRequired()) - this.eNotify(new ENotificationImpl(this, Notification.SET, DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR, newBackgroundColor, newBackgroundColor)); - } - /** * * @@ -300,8 +239,6 @@ public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, switch (featureID) { case DeckPackage.DECK_DESCRIPTION__LANE_DESCRIPTIONS: return ((InternalEList) this.getLaneDescriptions()).basicRemove(otherEnd, msgs); - case DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR: - return this.basicSetBackgroundColor(null, msgs); case DeckPackage.DECK_DESCRIPTION__LANE_DROP_TOOL: return this.basicSetLaneDropTool(null, msgs); case DeckPackage.DECK_DESCRIPTION__STYLE: @@ -322,8 +259,6 @@ public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case DeckPackage.DECK_DESCRIPTION__LANE_DESCRIPTIONS: return this.getLaneDescriptions(); - case DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR: - return this.getBackgroundColor(); case DeckPackage.DECK_DESCRIPTION__LANE_DROP_TOOL: return this.getLaneDropTool(); case DeckPackage.DECK_DESCRIPTION__STYLE: @@ -347,9 +282,6 @@ public void eSet(int featureID, Object newValue) { this.getLaneDescriptions().clear(); this.getLaneDescriptions().addAll((Collection) newValue); return; - case DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR: - this.setBackgroundColor((UserColor) newValue); - return; case DeckPackage.DECK_DESCRIPTION__LANE_DROP_TOOL: this.setLaneDropTool((LaneDropTool) newValue); return; @@ -375,9 +307,6 @@ public void eUnset(int featureID) { case DeckPackage.DECK_DESCRIPTION__LANE_DESCRIPTIONS: this.getLaneDescriptions().clear(); return; - case DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR: - this.setBackgroundColor((UserColor) null); - return; case DeckPackage.DECK_DESCRIPTION__LANE_DROP_TOOL: this.setLaneDropTool((LaneDropTool) null); return; @@ -401,8 +330,6 @@ public boolean eIsSet(int featureID) { switch (featureID) { case DeckPackage.DECK_DESCRIPTION__LANE_DESCRIPTIONS: return this.laneDescriptions != null && !this.laneDescriptions.isEmpty(); - case DeckPackage.DECK_DESCRIPTION__BACKGROUND_COLOR: - return this.backgroundColor != null; case DeckPackage.DECK_DESCRIPTION__LANE_DROP_TOOL: return this.laneDropTool != null; case DeckPackage.DECK_DESCRIPTION__STYLE: diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckElementDescriptionImpl.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckElementDescriptionImpl.java index 5d9b9de5a4..5507ffe2fc 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckElementDescriptionImpl.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckElementDescriptionImpl.java @@ -35,7 +35,6 @@ * The following features are implemented: *

      *
        - *
      • {@link org.eclipse.sirius.components.view.deck.impl.DeckElementDescriptionImpl#getName Name}
      • *
      • {@link org.eclipse.sirius.components.view.deck.impl.DeckElementDescriptionImpl#getSemanticCandidatesExpression * Semantic Candidates Expression}
      • *
      • {@link org.eclipse.sirius.components.view.deck.impl.DeckElementDescriptionImpl#getTitleExpression Title @@ -50,26 +49,6 @@ * @generated */ public abstract class DeckElementDescriptionImpl extends MinimalEObjectImpl.Container implements DeckElementDescription { - /** - * The default value of the '{@link #getName() Name}' attribute. - * - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = "newDeckElementDescription"; - - /** - * The cached value of the '{@link #getName() Name}' attribute. - * - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - /** * The default value of the '{@link #getSemanticCandidatesExpression() Semantic Candidates Expression}' * attribute. @@ -169,29 +148,6 @@ protected EClass eStaticClass() { return DeckPackage.Literals.DECK_ELEMENT_DESCRIPTION; } - /** - * - * - * @generated - */ - @Override - public String getName() { - return this.name; - } - - /** - * - * - * @generated - */ - @Override - public void setName(String newName) { - String oldName = this.name; - this.name = newName; - if (this.eNotificationRequired()) - this.eNotify(new ENotificationImpl(this, Notification.SET, DeckPackage.DECK_ELEMENT_DESCRIPTION__NAME, oldName, this.name)); - } - /** * * @@ -318,7 +274,8 @@ public void setStyle(DeckElementDescriptionStyle newStyle) { @Override public EList getConditionalStyles() { if (this.conditionalStyles == null) { - this.conditionalStyles = new EObjectContainmentEList<>(ConditionalDeckElementDescriptionStyle.class, this, DeckPackage.DECK_ELEMENT_DESCRIPTION__CONDITIONAL_STYLES); + this.conditionalStyles = new EObjectContainmentEList<>(ConditionalDeckElementDescriptionStyle.class, this, + DeckPackage.DECK_ELEMENT_DESCRIPTION__CONDITIONAL_STYLES); } return this.conditionalStyles; } @@ -347,8 +304,6 @@ public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { - case DeckPackage.DECK_ELEMENT_DESCRIPTION__NAME: - return this.getName(); case DeckPackage.DECK_ELEMENT_DESCRIPTION__SEMANTIC_CANDIDATES_EXPRESSION: return this.getSemanticCandidatesExpression(); case DeckPackage.DECK_ELEMENT_DESCRIPTION__TITLE_EXPRESSION: @@ -372,9 +327,6 @@ public Object eGet(int featureID, boolean resolve, boolean coreType) { @Override public void eSet(int featureID, Object newValue) { switch (featureID) { - case DeckPackage.DECK_ELEMENT_DESCRIPTION__NAME: - this.setName((String) newValue); - return; case DeckPackage.DECK_ELEMENT_DESCRIPTION__SEMANTIC_CANDIDATES_EXPRESSION: this.setSemanticCandidatesExpression((String) newValue); return; @@ -403,9 +355,6 @@ public void eSet(int featureID, Object newValue) { @Override public void eUnset(int featureID) { switch (featureID) { - case DeckPackage.DECK_ELEMENT_DESCRIPTION__NAME: - this.setName(NAME_EDEFAULT); - return; case DeckPackage.DECK_ELEMENT_DESCRIPTION__SEMANTIC_CANDIDATES_EXPRESSION: this.setSemanticCandidatesExpression(SEMANTIC_CANDIDATES_EXPRESSION_EDEFAULT); return; @@ -433,8 +382,6 @@ public void eUnset(int featureID) { @Override public boolean eIsSet(int featureID) { switch (featureID) { - case DeckPackage.DECK_ELEMENT_DESCRIPTION__NAME: - return NAME_EDEFAULT == null ? this.name != null : !NAME_EDEFAULT.equals(this.name); case DeckPackage.DECK_ELEMENT_DESCRIPTION__SEMANTIC_CANDIDATES_EXPRESSION: return SEMANTIC_CANDIDATES_EXPRESSION_EDEFAULT == null ? this.semanticCandidatesExpression != null : !SEMANTIC_CANDIDATES_EXPRESSION_EDEFAULT.equals(this.semanticCandidatesExpression); case DeckPackage.DECK_ELEMENT_DESCRIPTION__TITLE_EXPRESSION: @@ -460,9 +407,7 @@ public String toString() { return super.toString(); StringBuilder result = new StringBuilder(super.toString()); - result.append(" (name: "); - result.append(this.name); - result.append(", semanticCandidatesExpression: "); + result.append(" (semanticCandidatesExpression: "); result.append(this.semanticCandidatesExpression); result.append(", titleExpression: "); result.append(this.titleExpression); diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckPackageImpl.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckPackageImpl.java index 1c9287b914..4ad6baedcc 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckPackageImpl.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckPackageImpl.java @@ -237,7 +237,7 @@ public EReference getDeckDescription_LaneDescriptions() { * @generated */ @Override - public EReference getDeckDescription_BackgroundColor() { + public EReference getDeckDescription_LaneDropTool() { return (EReference) this.deckDescriptionEClass.getEStructuralFeatures().get(1); } @@ -247,7 +247,7 @@ public EReference getDeckDescription_BackgroundColor() { * @generated */ @Override - public EReference getDeckDescription_LaneDropTool() { + public EReference getDeckDescription_Style() { return (EReference) this.deckDescriptionEClass.getEStructuralFeatures().get(2); } @@ -257,7 +257,7 @@ public EReference getDeckDescription_LaneDropTool() { * @generated */ @Override - public EReference getDeckDescription_Style() { + public EReference getDeckDescription_ConditionalStyles() { return (EReference) this.deckDescriptionEClass.getEStructuralFeatures().get(3); } @@ -267,8 +267,8 @@ public EReference getDeckDescription_Style() { * @generated */ @Override - public EReference getDeckDescription_ConditionalStyles() { - return (EReference) this.deckDescriptionEClass.getEStructuralFeatures().get(4); + public EClass getLaneDescription() { + return this.laneDescriptionEClass; } /** @@ -277,8 +277,8 @@ public EReference getDeckDescription_ConditionalStyles() { * @generated */ @Override - public EClass getLaneDescription() { - return this.laneDescriptionEClass; + public EAttribute getLaneDescription_Name() { + return (EAttribute) this.laneDescriptionEClass.getEStructuralFeatures().get(0); } /** @@ -288,7 +288,7 @@ public EClass getLaneDescription() { */ @Override public EReference getLaneDescription_OwnedCardDescriptions() { - return (EReference) this.laneDescriptionEClass.getEStructuralFeatures().get(0); + return (EReference) this.laneDescriptionEClass.getEStructuralFeatures().get(1); } /** @@ -298,7 +298,7 @@ public EReference getLaneDescription_OwnedCardDescriptions() { */ @Override public EReference getLaneDescription_EditTool() { - return (EReference) this.laneDescriptionEClass.getEStructuralFeatures().get(1); + return (EReference) this.laneDescriptionEClass.getEStructuralFeatures().get(2); } /** @@ -308,7 +308,7 @@ public EReference getLaneDescription_EditTool() { */ @Override public EReference getLaneDescription_CreateTool() { - return (EReference) this.laneDescriptionEClass.getEStructuralFeatures().get(2); + return (EReference) this.laneDescriptionEClass.getEStructuralFeatures().get(3); } /** @@ -318,7 +318,7 @@ public EReference getLaneDescription_CreateTool() { */ @Override public EReference getLaneDescription_CardDropTool() { - return (EReference) this.laneDescriptionEClass.getEStructuralFeatures().get(3); + return (EReference) this.laneDescriptionEClass.getEStructuralFeatures().get(4); } /** @@ -328,7 +328,7 @@ public EReference getLaneDescription_CardDropTool() { */ @Override public EAttribute getLaneDescription_IsCollapsibleExpression() { - return (EAttribute) this.laneDescriptionEClass.getEStructuralFeatures().get(4); + return (EAttribute) this.laneDescriptionEClass.getEStructuralFeatures().get(5); } /** @@ -347,7 +347,7 @@ public EClass getCardDescription() { * @generated */ @Override - public EAttribute getCardDescription_DescriptionExpression() { + public EAttribute getCardDescription_Name() { return (EAttribute) this.cardDescriptionEClass.getEStructuralFeatures().get(0); } @@ -357,8 +357,8 @@ public EAttribute getCardDescription_DescriptionExpression() { * @generated */ @Override - public EReference getCardDescription_EditTool() { - return (EReference) this.cardDescriptionEClass.getEStructuralFeatures().get(1); + public EAttribute getCardDescription_DescriptionExpression() { + return (EAttribute) this.cardDescriptionEClass.getEStructuralFeatures().get(1); } /** @@ -367,7 +367,7 @@ public EReference getCardDescription_EditTool() { * @generated */ @Override - public EReference getCardDescription_DeleteTool() { + public EReference getCardDescription_EditTool() { return (EReference) this.cardDescriptionEClass.getEStructuralFeatures().get(2); } @@ -377,8 +377,8 @@ public EReference getCardDescription_DeleteTool() { * @generated */ @Override - public EClass getDeckTool() { - return this.deckToolEClass; + public EReference getCardDescription_DeleteTool() { + return (EReference) this.cardDescriptionEClass.getEStructuralFeatures().get(3); } /** @@ -387,8 +387,8 @@ public EClass getDeckTool() { * @generated */ @Override - public EAttribute getDeckTool_Name() { - return (EAttribute) this.deckToolEClass.getEStructuralFeatures().get(0); + public EClass getDeckTool() { + return this.deckToolEClass; } /** @@ -397,8 +397,8 @@ public EAttribute getDeckTool_Name() { * @generated */ @Override - public EAttribute getDeckTool_PreconditionExpression() { - return (EAttribute) this.deckToolEClass.getEStructuralFeatures().get(1); + public EAttribute getDeckTool_Name() { + return (EAttribute) this.deckToolEClass.getEStructuralFeatures().get(0); } /** @@ -408,7 +408,7 @@ public EAttribute getDeckTool_PreconditionExpression() { */ @Override public EReference getDeckTool_Body() { - return (EReference) this.deckToolEClass.getEStructuralFeatures().get(2); + return (EReference) this.deckToolEClass.getEStructuralFeatures().get(1); } /** @@ -481,16 +481,6 @@ public EClass getDeckElementDescription() { return this.deckElementDescriptionEClass; } - /** - * - * - * @generated - */ - @Override - public EAttribute getDeckElementDescription_Name() { - return (EAttribute) this.deckElementDescriptionEClass.getEStructuralFeatures().get(0); - } - /** * * @@ -498,7 +488,7 @@ public EAttribute getDeckElementDescription_Name() { */ @Override public EAttribute getDeckElementDescription_SemanticCandidatesExpression() { - return (EAttribute) this.deckElementDescriptionEClass.getEStructuralFeatures().get(1); + return (EAttribute) this.deckElementDescriptionEClass.getEStructuralFeatures().get(0); } /** @@ -508,7 +498,7 @@ public EAttribute getDeckElementDescription_SemanticCandidatesExpression() { */ @Override public EAttribute getDeckElementDescription_TitleExpression() { - return (EAttribute) this.deckElementDescriptionEClass.getEStructuralFeatures().get(2); + return (EAttribute) this.deckElementDescriptionEClass.getEStructuralFeatures().get(1); } /** @@ -518,7 +508,7 @@ public EAttribute getDeckElementDescription_TitleExpression() { */ @Override public EAttribute getDeckElementDescription_LabelExpression() { - return (EAttribute) this.deckElementDescriptionEClass.getEStructuralFeatures().get(3); + return (EAttribute) this.deckElementDescriptionEClass.getEStructuralFeatures().get(2); } /** @@ -528,7 +518,7 @@ public EAttribute getDeckElementDescription_LabelExpression() { */ @Override public EReference getDeckElementDescription_Style() { - return (EReference) this.deckElementDescriptionEClass.getEStructuralFeatures().get(4); + return (EReference) this.deckElementDescriptionEClass.getEStructuralFeatures().get(3); } /** @@ -538,7 +528,7 @@ public EReference getDeckElementDescription_Style() { */ @Override public EReference getDeckElementDescription_ConditionalStyles() { - return (EReference) this.deckElementDescriptionEClass.getEStructuralFeatures().get(5); + return (EReference) this.deckElementDescriptionEClass.getEStructuralFeatures().get(4); } /** @@ -642,12 +632,12 @@ public void createPackageContents() { // Create classes and their features this.deckDescriptionEClass = this.createEClass(DECK_DESCRIPTION); this.createEReference(this.deckDescriptionEClass, DECK_DESCRIPTION__LANE_DESCRIPTIONS); - this.createEReference(this.deckDescriptionEClass, DECK_DESCRIPTION__BACKGROUND_COLOR); this.createEReference(this.deckDescriptionEClass, DECK_DESCRIPTION__LANE_DROP_TOOL); this.createEReference(this.deckDescriptionEClass, DECK_DESCRIPTION__STYLE); this.createEReference(this.deckDescriptionEClass, DECK_DESCRIPTION__CONDITIONAL_STYLES); this.laneDescriptionEClass = this.createEClass(LANE_DESCRIPTION); + this.createEAttribute(this.laneDescriptionEClass, LANE_DESCRIPTION__NAME); this.createEReference(this.laneDescriptionEClass, LANE_DESCRIPTION__OWNED_CARD_DESCRIPTIONS); this.createEReference(this.laneDescriptionEClass, LANE_DESCRIPTION__EDIT_TOOL); this.createEReference(this.laneDescriptionEClass, LANE_DESCRIPTION__CREATE_TOOL); @@ -655,13 +645,13 @@ public void createPackageContents() { this.createEAttribute(this.laneDescriptionEClass, LANE_DESCRIPTION__IS_COLLAPSIBLE_EXPRESSION); this.cardDescriptionEClass = this.createEClass(CARD_DESCRIPTION); + this.createEAttribute(this.cardDescriptionEClass, CARD_DESCRIPTION__NAME); this.createEAttribute(this.cardDescriptionEClass, CARD_DESCRIPTION__DESCRIPTION_EXPRESSION); this.createEReference(this.cardDescriptionEClass, CARD_DESCRIPTION__EDIT_TOOL); this.createEReference(this.cardDescriptionEClass, CARD_DESCRIPTION__DELETE_TOOL); this.deckToolEClass = this.createEClass(DECK_TOOL); this.createEAttribute(this.deckToolEClass, DECK_TOOL__NAME); - this.createEAttribute(this.deckToolEClass, DECK_TOOL__PRECONDITION_EXPRESSION); this.createEReference(this.deckToolEClass, DECK_TOOL__BODY); this.createCardToolEClass = this.createEClass(CREATE_CARD_TOOL); @@ -677,7 +667,6 @@ public void createPackageContents() { this.laneDropToolEClass = this.createEClass(LANE_DROP_TOOL); this.deckElementDescriptionEClass = this.createEClass(DECK_ELEMENT_DESCRIPTION); - this.createEAttribute(this.deckElementDescriptionEClass, DECK_ELEMENT_DESCRIPTION__NAME); this.createEAttribute(this.deckElementDescriptionEClass, DECK_ELEMENT_DESCRIPTION__SEMANTIC_CANDIDATES_EXPRESSION); this.createEAttribute(this.deckElementDescriptionEClass, DECK_ELEMENT_DESCRIPTION__TITLE_EXPRESSION); this.createEAttribute(this.deckElementDescriptionEClass, DECK_ELEMENT_DESCRIPTION__LABEL_EXPRESSION); @@ -746,8 +735,6 @@ public void initializePackageContents() { this.initEClass(this.deckDescriptionEClass, DeckDescription.class, "DeckDescription", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); this.initEReference(this.getDeckDescription_LaneDescriptions(), this.getLaneDescription(), null, "laneDescriptions", null, 0, -1, DeckDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - this.initEReference(this.getDeckDescription_BackgroundColor(), theViewPackage.getUserColor(), null, "backgroundColor", null, 0, 1, DeckDescription.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEReference(this.getDeckDescription_LaneDropTool(), this.getLaneDropTool(), null, "laneDropTool", null, 0, 1, DeckDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEReference(this.getDeckDescription_Style(), this.getDeckDescriptionStyle(), null, "style", null, 0, 1, DeckDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, @@ -756,6 +743,8 @@ public void initializePackageContents() { !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEClass(this.laneDescriptionEClass, LaneDescription.class, "LaneDescription", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + this.initEAttribute(this.getLaneDescription_Name(), theViewPackage.getIdentifier(), "name", "New Lane Description", 0, 1, LaneDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, + !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEReference(this.getLaneDescription_OwnedCardDescriptions(), this.getCardDescription(), null, "ownedCardDescriptions", null, 0, -1, LaneDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEReference(this.getLaneDescription_EditTool(), this.getEditLaneTool(), null, "editTool", null, 0, 1, LaneDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, @@ -768,6 +757,8 @@ public void initializePackageContents() { !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEClass(this.cardDescriptionEClass, CardDescription.class, "CardDescription", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + this.initEAttribute(this.getCardDescription_Name(), theViewPackage.getIdentifier(), "name", "New Card Description", 0, 1, CardDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, + !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEAttribute(this.getCardDescription_DescriptionExpression(), theViewPackage.getInterpretedExpression(), "descriptionExpression", "aql:self", 0, 1, CardDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEReference(this.getCardDescription_EditTool(), this.getEditCardTool(), null, "editTool", null, 0, 1, CardDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, @@ -778,8 +769,6 @@ public void initializePackageContents() { this.initEClass(this.deckToolEClass, DeckTool.class, "DeckTool", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); this.initEAttribute(this.getDeckTool_Name(), theViewPackage.getIdentifier(), "name", null, 1, 1, DeckTool.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - this.initEAttribute(this.getDeckTool_PreconditionExpression(), theViewPackage.getInterpretedExpression(), "preconditionExpression", null, 0, 1, DeckTool.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEReference(this.getDeckTool_Body(), theViewPackage.getOperation(), null, "body", null, 0, -1, DeckTool.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); @@ -796,8 +785,6 @@ public void initializePackageContents() { this.initEClass(this.laneDropToolEClass, LaneDropTool.class, "LaneDropTool", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); this.initEClass(this.deckElementDescriptionEClass, DeckElementDescription.class, "DeckElementDescription", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - this.initEAttribute(this.getDeckElementDescription_Name(), theViewPackage.getIdentifier(), "name", "newDeckElementDescription", 0, 1, DeckElementDescription.class, !IS_TRANSIENT, !IS_VOLATILE, - IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEAttribute(this.getDeckElementDescription_SemanticCandidatesExpression(), theViewPackage.getInterpretedExpression(), "semanticCandidatesExpression", "aql:self", 1, 1, DeckElementDescription.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); this.initEAttribute(this.getDeckElementDescription_TitleExpression(), theViewPackage.getInterpretedExpression(), "titleExpression", "aql:self", 0, 1, DeckElementDescription.class, diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckToolImpl.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckToolImpl.java index 3c8551caf2..08142f3ba0 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckToolImpl.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/DeckToolImpl.java @@ -34,8 +34,6 @@ *

        *
          *
        • {@link org.eclipse.sirius.components.view.deck.impl.DeckToolImpl#getName Name}
        • - *
        • {@link org.eclipse.sirius.components.view.deck.impl.DeckToolImpl#getPreconditionExpression Precondition - * Expression}
        • *
        • {@link org.eclipse.sirius.components.view.deck.impl.DeckToolImpl#getBody Body}
        • *
        * @@ -62,26 +60,6 @@ public abstract class DeckToolImpl extends MinimalEObjectImpl.Container implemen */ protected String name = NAME_EDEFAULT; - /** - * The default value of the '{@link #getPreconditionExpression() Precondition Expression}' attribute. - * - * @see #getPreconditionExpression() - * @generated - * @ordered - */ - protected static final String PRECONDITION_EXPRESSION_EDEFAULT = null; - - /** - * The cached value of the '{@link #getPreconditionExpression() Precondition Expression}' attribute. - * - * @see #getPreconditionExpression() - * @generated - * @ordered - */ - protected String preconditionExpression = PRECONDITION_EXPRESSION_EDEFAULT; - /** * The cached value of the '{@link #getBody() Body}' containment reference list. * @@ -134,29 +112,6 @@ public void setName(String newName) { this.eNotify(new ENotificationImpl(this, Notification.SET, DeckPackage.DECK_TOOL__NAME, oldName, this.name)); } - /** - * - * - * @generated - */ - @Override - public String getPreconditionExpression() { - return this.preconditionExpression; - } - - /** - * - * - * @generated - */ - @Override - public void setPreconditionExpression(String newPreconditionExpression) { - String oldPreconditionExpression = this.preconditionExpression; - this.preconditionExpression = newPreconditionExpression; - if (this.eNotificationRequired()) - this.eNotify(new ENotificationImpl(this, Notification.SET, DeckPackage.DECK_TOOL__PRECONDITION_EXPRESSION, oldPreconditionExpression, this.preconditionExpression)); - } - /** * * @@ -194,8 +149,6 @@ public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case DeckPackage.DECK_TOOL__NAME: return this.getName(); - case DeckPackage.DECK_TOOL__PRECONDITION_EXPRESSION: - return this.getPreconditionExpression(); case DeckPackage.DECK_TOOL__BODY: return this.getBody(); } @@ -214,9 +167,6 @@ public void eSet(int featureID, Object newValue) { case DeckPackage.DECK_TOOL__NAME: this.setName((String) newValue); return; - case DeckPackage.DECK_TOOL__PRECONDITION_EXPRESSION: - this.setPreconditionExpression((String) newValue); - return; case DeckPackage.DECK_TOOL__BODY: this.getBody().clear(); this.getBody().addAll((Collection) newValue); @@ -236,9 +186,6 @@ public void eUnset(int featureID) { case DeckPackage.DECK_TOOL__NAME: this.setName(NAME_EDEFAULT); return; - case DeckPackage.DECK_TOOL__PRECONDITION_EXPRESSION: - this.setPreconditionExpression(PRECONDITION_EXPRESSION_EDEFAULT); - return; case DeckPackage.DECK_TOOL__BODY: this.getBody().clear(); return; @@ -256,8 +203,6 @@ public boolean eIsSet(int featureID) { switch (featureID) { case DeckPackage.DECK_TOOL__NAME: return NAME_EDEFAULT == null ? this.name != null : !NAME_EDEFAULT.equals(this.name); - case DeckPackage.DECK_TOOL__PRECONDITION_EXPRESSION: - return PRECONDITION_EXPRESSION_EDEFAULT == null ? this.preconditionExpression != null : !PRECONDITION_EXPRESSION_EDEFAULT.equals(this.preconditionExpression); case DeckPackage.DECK_TOOL__BODY: return this.body != null && !this.body.isEmpty(); } @@ -277,8 +222,6 @@ public String toString() { StringBuilder result = new StringBuilder(super.toString()); result.append(" (name: "); result.append(this.name); - result.append(", preconditionExpression: "); - result.append(this.preconditionExpression); result.append(')'); return result.toString(); } diff --git a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/LaneDescriptionImpl.java b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/LaneDescriptionImpl.java index e69abd914b..01663e81ea 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/LaneDescriptionImpl.java +++ b/packages/view/backend/sirius-components-view-deck/src/main/java/org/eclipse/sirius/components/view/deck/impl/LaneDescriptionImpl.java @@ -49,6 +49,26 @@ * @generated */ public class LaneDescriptionImpl extends DeckElementDescriptionImpl implements LaneDescription { + /** + * The default value of the '{@link #getName() Name}' attribute. + * + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = "New Lane Description"; + + /** + * The cached value of the '{@link #getName() Name}' attribute. + * + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + /** * The cached value of the '{@link #getOwnedCardDescriptions() Owned Card Descriptions}' containment * reference list. @@ -128,6 +148,29 @@ protected EClass eStaticClass() { return DeckPackage.Literals.LANE_DESCRIPTION; } + /** + * + * + * @generated + */ + @Override + public String getName() { + return this.name; + } + + /** + * + * + * @generated + */ + @Override + public void setName(String newName) { + String oldName = this.name; + this.name = newName; + if (this.eNotificationRequired()) + this.eNotify(new ENotificationImpl(this, Notification.SET, DeckPackage.LANE_DESCRIPTION__NAME, oldName, this.name)); + } + /** * * @@ -336,6 +379,8 @@ public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { + case DeckPackage.LANE_DESCRIPTION__NAME: + return this.getName(); case DeckPackage.LANE_DESCRIPTION__OWNED_CARD_DESCRIPTIONS: return this.getOwnedCardDescriptions(); case DeckPackage.LANE_DESCRIPTION__EDIT_TOOL: @@ -359,6 +404,9 @@ public Object eGet(int featureID, boolean resolve, boolean coreType) { @Override public void eSet(int featureID, Object newValue) { switch (featureID) { + case DeckPackage.LANE_DESCRIPTION__NAME: + this.setName((String) newValue); + return; case DeckPackage.LANE_DESCRIPTION__OWNED_CARD_DESCRIPTIONS: this.getOwnedCardDescriptions().clear(); this.getOwnedCardDescriptions().addAll((Collection) newValue); @@ -387,6 +435,9 @@ public void eSet(int featureID, Object newValue) { @Override public void eUnset(int featureID) { switch (featureID) { + case DeckPackage.LANE_DESCRIPTION__NAME: + this.setName(NAME_EDEFAULT); + return; case DeckPackage.LANE_DESCRIPTION__OWNED_CARD_DESCRIPTIONS: this.getOwnedCardDescriptions().clear(); return; @@ -414,6 +465,8 @@ public void eUnset(int featureID) { @Override public boolean eIsSet(int featureID) { switch (featureID) { + case DeckPackage.LANE_DESCRIPTION__NAME: + return NAME_EDEFAULT == null ? this.name != null : !NAME_EDEFAULT.equals(this.name); case DeckPackage.LANE_DESCRIPTION__OWNED_CARD_DESCRIPTIONS: return this.ownedCardDescriptions != null && !this.ownedCardDescriptions.isEmpty(); case DeckPackage.LANE_DESCRIPTION__EDIT_TOOL: @@ -439,7 +492,9 @@ public String toString() { return super.toString(); StringBuilder result = new StringBuilder(super.toString()); - result.append(" (isCollapsibleExpression: "); + result.append(" (name: "); + result.append(this.name); + result.append(", isCollapsibleExpression: "); result.append(this.isCollapsibleExpression); result.append(')'); return result.toString(); diff --git a/packages/view/backend/sirius-components-view-deck/src/main/resources/model/deck.ecore b/packages/view/backend/sirius-components-view-deck/src/main/resources/model/deck.ecore index 21c174ca7b..afe1902d8a 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/resources/model/deck.ecore +++ b/packages/view/backend/sirius-components-view-deck/src/main/resources/model/deck.ecore @@ -4,8 +4,6 @@ - + + @@ -37,8 +39,6 @@ - @@ -49,8 +49,6 @@ - diff --git a/packages/view/backend/sirius-components-view-deck/src/main/resources/model/deck.genmodel b/packages/view/backend/sirius-components-view-deck/src/main/resources/model/deck.genmodel index 844e1d40d2..2665eb2b83 100644 --- a/packages/view/backend/sirius-components-view-deck/src/main/resources/model/deck.genmodel +++ b/packages/view/backend/sirius-components-view-deck/src/main/resources/model/deck.genmodel @@ -16,12 +16,12 @@ extensibleProviderFactory="true" childCreationExtenders="true" ecorePackage="deck.ecore#/"> - + @@ -29,13 +29,13 @@ + - @@ -45,7 +45,6 @@ -