summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkwilk2012-04-24 19:28:31 (EDT)
committerRoberto E. Escobar2012-04-24 19:28:31 (EDT)
commit0fd724d62684411122aa4e85601b9d614af7b4fc (patch)
treee3f847a81fc81654f573ea228d2a9b32919f7e0c
parent2d7d09a0bd4911652522d3955fab453b0118dbe4 (diff)
downloadorg.eclipse.osee-0fd724d62684411122aa4e85601b9d614af7b4fc.zip
org.eclipse.osee-0fd724d62684411122aa4e85601b9d614af7b4fc.tar.gz
org.eclipse.osee-0fd724d62684411122aa4e85601b9d614af7b4fc.tar.bz2
feature: More storage changes
-rw-r--r--plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/branch/AtsBranchManagerCore.java10
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/OpenTeamDefinitionAction.java10
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldXNavigateItemAction.java8
-rw-r--r--plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/Collections.java15
4 files changed, 11 insertions, 32 deletions
diff --git a/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/branch/AtsBranchManagerCore.java b/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/branch/AtsBranchManagerCore.java
index a8847b8..a59133e 100644
--- a/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/branch/AtsBranchManagerCore.java
+++ b/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/branch/AtsBranchManagerCore.java
@@ -38,6 +38,7 @@ import org.eclipse.osee.ats.core.model.IAtsUser;
import org.eclipse.osee.ats.core.users.AtsUsers;
import org.eclipse.osee.ats.core.workdef.DecisionReviewDefinition;
import org.eclipse.osee.ats.core.workdef.PeerReviewDefinition;
+import org.eclipse.osee.ats.core.workdef.StateDefinition;
import org.eclipse.osee.ats.core.workdef.StateEventType;
import org.eclipse.osee.framework.core.data.IOseeBranch;
import org.eclipse.osee.framework.core.enums.BranchState;
@@ -640,8 +641,9 @@ public class AtsBranchManagerCore {
throw new OseeStateException("Invalid stateEventType [%s]", stateEventType);
}
// Create any decision and peerToPeer reviews for createBranch and commitBranch
- for (DecisionReviewDefinition decRevDef : teamArt.getStateDefinition().getDecisionReviews()) {
- if (decRevDef.getStateEventType() != null && decRevDef.getStateEventType().equals(stateEventType)) {
+ StateDefinition stateDefinition = teamArt.getStateDefinition();
+ for (DecisionReviewDefinition decRevDef : stateDefinition.getDecisionReviews()) {
+ if (stateEventType.equals(decRevDef.getStateEventType())) {
DecisionReviewArtifact decArt =
DecisionReviewDefinitionManager.createNewDecisionReview(decRevDef, transaction, teamArt, createdDate,
createdBy);
@@ -650,8 +652,8 @@ public class AtsBranchManagerCore {
}
}
}
- for (PeerReviewDefinition peerRevDef : teamArt.getStateDefinition().getPeerReviews()) {
- if (peerRevDef.getStateEventType() != null && peerRevDef.getStateEventType().equals(stateEventType)) {
+ for (PeerReviewDefinition peerRevDef : stateDefinition.getPeerReviews()) {
+ if (stateEventType.equals(peerRevDef.getStateEventType())) {
PeerToPeerReviewArtifact peerArt =
PeerReviewDefinitionManager.createNewPeerToPeerReview(peerRevDef, transaction, teamArt, createdDate,
createdBy);
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/OpenTeamDefinitionAction.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/OpenTeamDefinitionAction.java
index 6183cb5..901de2d 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/OpenTeamDefinitionAction.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/OpenTeamDefinitionAction.java
@@ -11,7 +11,6 @@
package org.eclipse.osee.ats.actions;
-import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.osee.ats.AtsImage;
import org.eclipse.osee.ats.AtsOpenOption;
import org.eclipse.osee.ats.core.client.team.TeamWorkFlowArtifact;
@@ -27,9 +26,8 @@ public class OpenTeamDefinitionAction extends AbstractAtsAction {
private final TeamWorkFlowArtifact teamArt;
public OpenTeamDefinitionAction(TeamWorkFlowArtifact teamArt) {
- super();
+ super("Open Team Definition", ImageManager.getImageDescriptor(AtsImage.TEAM_DEFINITION));
this.teamArt = teamArt;
- setText("Open Team Definition");
setToolTipText(getText());
}
@@ -39,10 +37,4 @@ public class OpenTeamDefinitionAction extends AbstractAtsAction {
AtsUtil.openATSAction(teamArt.getTeamDefinition(), AtsOpenOption.OpenOneOrPopupSelect);
}
}
-
- @Override
- public ImageDescriptor getImageDescriptor() {
- return ImageManager.getImageDescriptor(AtsImage.TEAM_DEFINITION);
- }
-
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldXNavigateItemAction.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldXNavigateItemAction.java
index 15b0e5d..af090f3 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldXNavigateItemAction.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldXNavigateItemAction.java
@@ -21,12 +21,12 @@ import org.eclipse.osee.framework.ui.swt.KeyedImage;
*/
public class WorldXNavigateItemAction extends XNavigateItemAction {
- public WorldXNavigateItemAction(XNavigateItem parent, String name, KeyedImage oseeImage) {
- super(parent, name, (oseeImage == null ? determineImage(name) : oseeImage));
+ public WorldXNavigateItemAction(XNavigateItem parent, String name) {
+ this(parent, name, determineImage(name));
}
- public WorldXNavigateItemAction(XNavigateItem parent, String name) {
- super(parent, name, determineImage(name));
+ public WorldXNavigateItemAction(XNavigateItem parent, String name, KeyedImage oseeImage) {
+ super(parent, name, (oseeImage == null ? determineImage(name) : oseeImage));
}
private static KeyedImage determineImage(String name) {
diff --git a/plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/Collections.java b/plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/Collections.java
index 6ccb686..6a68ce3 100644
--- a/plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/Collections.java
+++ b/plugins/org.eclipse.osee.framework.jdk.core/src/org/eclipse/osee/framework/jdk/core/util/Collections.java
@@ -116,21 +116,6 @@ public class Collections {
* Noted:<br/>
* A - B
* </p>
- * <p>
- * <br/>
- * Examples:<br/>
- * { 1, 2, 3 } - { 1, 4, 3 } = { 2 } <br/>
- * <br/>
- * { 1, 4, 3 } - { 1, 2, 3 } = { 4 }
- * </p>
- * Meaning:
- * <ul>
- * <li>elements outside of B</li>
- * <li>all elements unique to A</li>
- * </ul>
- * </p>
- *
- * @return relative set complement of B in A.
*/
public static <T> List<T> setComplement(Collection<T> set_A, Collection<T> set_B) {
ArrayList<T> complement = new ArrayList<T>(set_A.size());