Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorInput.java4
-rw-r--r--plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ArtifactQueryTest.java8
-rw-r--r--plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ConflictDeletionTest.java59
-rw-r--r--plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/AccessControlService.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core.dsl.integration/src/org/eclipse/osee/framework/core/dsl/integration/internal/ArtifactMatchInterpreter.java9
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java12
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/commit/actions/CatchWordMlChanges.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java2
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/editor/ArtifactEditorInputFactory.java6
-rw-r--r--plugins/org.eclipse.osee.orcs.rest/src/org/eclipse/osee/orcs/rest/internal/OrcsRestUtil.java2
14 files changed, 61 insertions, 61 deletions
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorInput.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorInput.java
index 3b819525c92..31b03eb2c25 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorInput.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorInput.java
@@ -29,7 +29,7 @@ import org.eclipse.ui.IPersistableElement;
/**
* @author Donald G. Dunne
*/
-public class WorldEditorInput implements IEditorInput, IPersistableElement, Adaptable {
+public class WorldEditorInput implements IEditorInput, IPersistableElement, Adaptable {
IWorldEditorProvider iWorldEditorProvider;
WorldEditor editor;
@@ -134,7 +134,7 @@ public class WorldEditorInput implements IEditorInput, IPersistableElement, Adap
branchUuid = provider.getBranchUuid();
} else {
if (!editor.getLoadedArtifacts().isEmpty()) {
- branchUuid = editor.getLoadedArtifacts().iterator().next().getBranchId();
+ branchUuid = editor.getLoadedArtifacts().iterator().next().getBranch().getId();
}
}
return branchUuid;
diff --git a/plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ArtifactQueryTest.java b/plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ArtifactQueryTest.java
index 5784bf2f97c..47756be9f80 100644
--- a/plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ArtifactQueryTest.java
+++ b/plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ArtifactQueryTest.java
@@ -123,13 +123,13 @@ public class ArtifactQueryTest {
Assert.assertTrue("No artifacts found", searchedArtifacts.size() > 0);
//check to see if there are multiple branches found
- Long firstGuid = 0L;
+ BranchId firstId = BranchId.SENTINEL;
Boolean pass = false;
for (Artifact a : searchedArtifacts) {
- if (0L == firstGuid) {
- firstGuid = a.getBranchId();
+ if (firstId.isInvalid()) {
+ firstId = a.getBranch();
} else {
- if (firstGuid != a.getBranchId()) {
+ if (!firstId.equals(a.getBranch())) {
pass = true;
break;
}
diff --git a/plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ConflictDeletionTest.java b/plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ConflictDeletionTest.java
index 72770c1c64b..66205f59a44 100644
--- a/plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ConflictDeletionTest.java
+++ b/plugins/org.eclipse.osee.client.integration.tests/src/org/eclipse/osee/client/integration/tests/integration/skynet/core/ConflictDeletionTest.java
@@ -128,25 +128,25 @@ public class ConflictDeletionTest {
dumpArtifact(artifact);
} else {
try {
- chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT, artifact.getBranchId(), artifact.getTransaction(),
+ chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT, artifact.getBranch(), artifact.getTransaction(),
artifact.getArtId());
if (chStmt.next()) {
fail(
"Artifact " + artifact.getArtId() + " old Transaction < " + artifact.getTransaction() + " is set to " + chStmt.getInt(
- "tx_current") + " , should be 0 on branch " + artifact.getBranchId());
+ "tx_current") + " , should be 0 on branch " + artifact.getBranch());
}
} finally {
chStmt.close();
}
try {
- chStmt.runPreparedQuery(CHECK_FOR_DELETED_TX_CURRENT, artifact.getBranchId(), artifact.getArtId());
+ chStmt.runPreparedQuery(CHECK_FOR_DELETED_TX_CURRENT, artifact.getBranch(), artifact.getArtId());
if (chStmt.next()) {
assertTrue(
- "Artifact " + artifact.getArtId() + " Transaction: " + artifact.getTransaction() + " should be 3 on branch " + artifact.getBranchId(),
+ "Artifact " + artifact.getArtId() + " Transaction: " + artifact.getTransaction() + " should be 3 on branch " + artifact.getBranch(),
artifact.getTransaction().equals(chStmt.getLong("transaction_id")));
} else {
fail(
- "Artifact " + artifact.getArtId() + " was not given a tx_current value of 2 when it was deleted on branch " + artifact.getBranchId() + " on transaction " + artifact.getTransaction());
+ "Artifact " + artifact.getArtId() + " was not given a tx_current value of 2 when it was deleted on branch " + artifact.getBranch() + " on transaction " + artifact.getTransaction());
}
} finally {
chStmt.close();
@@ -185,19 +185,19 @@ public class ConflictDeletionTest {
dumpArtifact(artifact);
} else {
try {
- chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT, artifact.getBranchId(), deletionTransaction,
+ chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT, artifact.getBranch(), deletionTransaction,
artifact.getArtId());
if (chStmt.next()) {
if (deletionTransaction.equals(chStmt.getLong("transaction_id"))) {
fail("Artifact " + artifact.getArtId() + " tx_current set on " + chStmt.getInt(
- "transaction_id") + " when it should be < " + deletionTransaction + " on branch " + artifact.getBranchId());
+ "transaction_id") + " when it should be < " + deletionTransaction + " on branch " + artifact.getBranch());
}
if (chStmt.next()) {
fail(
- "Artifact " + artifact.getArtId() + " has multiple tx_current set on " + artifact.getBranchId());
+ "Artifact " + artifact.getArtId() + " has multiple tx_current set on " + artifact.getBranch());
}
} else {
- fail("Artifact " + artifact.getArtId() + " has no tx_current set on " + artifact.getBranchId());
+ fail("Artifact " + artifact.getArtId() + " has no tx_current set on " + artifact.getBranch());
}
} finally {
chStmt.close();
@@ -210,19 +210,19 @@ public class ConflictDeletionTest {
dumpAttribute(attribute);
} else {
try {
- chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT_ATTRIBUTE, artifact.getBranchId(),
+ chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT_ATTRIBUTE, artifact.getBranch(),
deletionTransaction, attribute.getId());
if (chStmt.next()) {
if (deletionTransaction.equals(chStmt.getLong("transaction_id"))) {
fail("Attribute " + attribute.getId() + " tx_current set on " + chStmt.getInt(
- "transaction_id") + " when it should be < " + deletionTransaction + " on branch " + artifact.getBranchId());
+ "transaction_id") + " when it should be < " + deletionTransaction + " on branch " + artifact.getBranch());
}
if (chStmt.next()) {
fail(
- "Attribute " + attribute.getId() + " has multiple tx_current set on " + artifact.getBranchId());
+ "Attribute " + attribute.getId() + " has multiple tx_current set on " + artifact.getBranch());
}
} else {
- fail("Attribute " + attribute.getId() + " has no tx_current set on " + artifact.getBranchId());
+ fail("Attribute " + attribute.getId() + " has no tx_current set on " + artifact.getBranch());
}
} finally {
chStmt.close();
@@ -234,19 +234,19 @@ public class ConflictDeletionTest {
dumpRelation(relation, artifact);
} else {
try {
- chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT_RELATION, artifact.getBranchId(),
+ chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT_RELATION, artifact.getBranch(),
deletionTransaction, relation.getId());
if (chStmt.next()) {
if (deletionTransaction.equals(chStmt.getLong("transaction_id"))) {
fail("Relation " + relation.getId() + " tx_current set on " + chStmt.getInt(
- "transaction_id") + " when it should be < " + deletionTransaction + " on branch " + artifact.getBranchId());
+ "transaction_id") + " when it should be < " + deletionTransaction + " on branch " + artifact.getBranch());
}
if (chStmt.next()) {
fail(
- "Relation " + relation.getId() + " has multiple tx_current set on " + artifact.getBranchId());
+ "Relation " + relation.getId() + " has multiple tx_current set on " + artifact.getBranch());
}
} else {
- fail("Relation " + relation.getId() + " has no tx_current set on " + artifact.getBranchId());
+ fail("Relation " + relation.getId() + " has no tx_current set on " + artifact.getBranch());
}
} finally {
chStmt.close();
@@ -310,18 +310,18 @@ public class ConflictDeletionTest {
private void checkAttribute(Artifact artifact, Attribute<?> attribute, int value) throws OseeCoreException {
JdbcStatement chStmt = ConnectionHandler.getStatement();
try {
- chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT_ATTRIBUTE, artifact.getBranchId(), artifact.getTransaction(),
+ chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT_ATTRIBUTE, artifact.getBranch(), artifact.getTransaction(),
attribute.getId());
if (chStmt.next()) {
fail(
"Attribute " + attribute.getId() + " old Transaction < : " + artifact.getTransaction() + " is set to " + chStmt.getInt(
- "tx_current") + " , should be 0 on branch " + artifact.getBranchId());
+ "tx_current") + " , should be 0 on branch " + artifact.getBranch());
}
} finally {
chStmt.close();
}
try {
- chStmt.runPreparedQuery(CHECK_FOR_DELETED_TX_CURRENT_ATTRIBUTE, artifact.getBranchId(), value,
+ chStmt.runPreparedQuery(CHECK_FOR_DELETED_TX_CURRENT_ATTRIBUTE, artifact.getBranch(), value,
attribute.getId());
if (chStmt.next()) {
assertTrue(
@@ -329,7 +329,7 @@ public class ConflictDeletionTest {
artifact.getTransaction().equals(chStmt.getLong("transaction_id")));
} else {
fail(
- "Attribute " + attribute.getId() + " was not given a tx_current value of 3 when it was deleted on branch " + artifact.getBranchId());
+ "Attribute " + attribute.getId() + " was not given a tx_current value of 3 when it was deleted on branch " + artifact.getBranch());
}
} finally {
chStmt.close();
@@ -342,30 +342,29 @@ public class ConflictDeletionTest {
"Relation should be deleted between Parent: " + relation.getAArtifactId() + " and child " + relation.getBArtifactId(),
relation.isDeleted());
try {
- chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT_RELATION, artifact.getBranchId(), artifact.getTransaction(),
+ chStmt.runPreparedQuery(CHECK_FOR_ZERO_TX_CURRENT_RELATION, artifact.getBranch(), artifact.getTransaction(),
relation.getId());
if (chStmt.next()) {
fail(
"Relation " + relation.getId() + " old Transaction < : " + artifact.getTransaction() + " is set to " + chStmt.getInt(
- "tx_current") + " , should be 0 on branch " + artifact.getBranchId());
+ "tx_current") + " , should be 0 on branch " + artifact.getBranch());
}
} finally {
chStmt.close();
}
try {
- chStmt.runPreparedQuery(CHECK_FOR_DELETED_TX_CURRENT_RELATION, artifact.getBranchId(), value,
- relation.getId());
+ chStmt.runPreparedQuery(CHECK_FOR_DELETED_TX_CURRENT_RELATION, artifact.getBranch(), value, relation.getId());
if (chStmt.next()) {
assertTrue(
"Relation " + relation.getId() + " Transaction: " + artifact.getTransaction() + " should be " + value + " on branch " + artifact.getBranch(),
artifact.getTransaction().isOlderThan(TransactionId.valueOf(chStmt.getLong("transaction_id"))));
if (chStmt.next()) {
fail(
- "Relation " + relation.getId() + " has multiple tx_current values of " + value + " when it was deleted on branch " + artifact.getBranchId() + " on transaction " + artifact.getTransaction());
+ "Relation " + relation.getId() + " has multiple tx_current values of " + value + " when it was deleted on branch " + artifact.getBranch() + " on transaction " + artifact.getTransaction());
}
} else {
fail(
- "Relation " + relation.getId() + " was not given a tx_current value of " + value + " when it was deleted on branch " + artifact.getBranchId() + " on transaction " + artifact.getTransaction());
+ "Relation " + relation.getId() + " was not given a tx_current value of " + value + " when it was deleted on branch " + artifact.getBranch() + " on transaction " + artifact.getTransaction());
}
} finally {
chStmt.close();
@@ -377,7 +376,7 @@ public class ConflictDeletionTest {
try {
if (DEBUG) {
System.out.println(" Artifact Dump : " + artifact.getName());
- chStmt.runPreparedQuery(GET_ARTIFACT_DEBUG, artifact.getBranchId(), artifact.getArtId());
+ chStmt.runPreparedQuery(GET_ARTIFACT_DEBUG, artifact.getBranch(), artifact.getArtId());
while (chStmt.next()) {
System.out.println(String.format(
" Art Id = %d Branch Uuid = %d TX_Current = %d mod_type = %d Transaction_id = %d Gamma_id = %d",
@@ -395,7 +394,7 @@ public class ConflictDeletionTest {
try {
if (DEBUG) {
System.out.println(" Attribute Dump");
- chStmt.runPreparedQuery(GET_ATTRIBUTE_DEBUG, attribute.getArtifact().getBranchId(), attribute.getId());
+ chStmt.runPreparedQuery(GET_ATTRIBUTE_DEBUG, attribute.getArtifact().getBranch(), attribute.getId());
while (chStmt.next()) {
System.out.println(String.format(
" Attribute Id = %d Art_id = %d Branch Uuid = %d TX_Current = %d mod_type = %d Transaction_id = %d Gamma_id = %d",
@@ -414,7 +413,7 @@ public class ConflictDeletionTest {
try {
if (DEBUG) {
System.out.println(" Relation Dump");
- chStmt.runPreparedQuery(GET_RELATION_DEBUG, artifact.getBranchId(), relation.getId());
+ chStmt.runPreparedQuery(GET_RELATION_DEBUG, artifact.getBranch(), relation.getId());
while (chStmt.next()) {
System.out.println(String.format(
" Relation Id = %d a_art_id = %d b_art_id = %d Branch Uuid = %d TX_Current = %d mod_type = %d Transaction_id = %d Gamma_id = %d",
diff --git a/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/AccessControlService.java b/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/AccessControlService.java
index d80677a47d5..26d48129c5d 100644
--- a/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/AccessControlService.java
+++ b/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/AccessControlService.java
@@ -440,8 +440,8 @@ public class AccessControlService implements IAccessControlService {
}
}
if (userPermission == null) {
- if (!CoreBranches.COMMON.getId().equals(accessObject.getBranchId()) && BranchManager.getType(
- BranchId.valueOf(accessObject.getBranchId())).isBaselineBranch()) {
+ if (!CoreBranches.COMMON.equals(accessObject.getBranch()) && BranchManager.getType(
+ accessObject.getBranch()).isBaselineBranch()) {
userPermission = PermissionEnum.READ;
} else {
userPermission = PermissionEnum.FULLACCESS;
diff --git a/plugins/org.eclipse.osee.framework.core.dsl.integration/src/org/eclipse/osee/framework/core/dsl/integration/internal/ArtifactMatchInterpreter.java b/plugins/org.eclipse.osee.framework.core.dsl.integration/src/org/eclipse/osee/framework/core/dsl/integration/internal/ArtifactMatchInterpreter.java
index b0c7836d213..f515151d11b 100644
--- a/plugins/org.eclipse.osee.framework.core.dsl.integration/src/org/eclipse/osee/framework/core/dsl/integration/internal/ArtifactMatchInterpreter.java
+++ b/plugins/org.eclipse.osee.framework.core.dsl.integration/src/org/eclipse/osee/framework/core/dsl/integration/internal/ArtifactMatchInterpreter.java
@@ -17,6 +17,7 @@ import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
+import org.eclipse.osee.framework.core.data.BranchId;
import org.eclipse.osee.framework.core.dsl.integration.ArtifactDataProvider.ArtifactProxy;
import org.eclipse.osee.framework.core.dsl.oseeDsl.CompareOp;
import org.eclipse.osee.framework.core.dsl.oseeDsl.CompoundCondition;
@@ -105,10 +106,10 @@ public class ArtifactMatchInterpreter {
Conditions.checkExpressionFailOnTrue(!GUID.isValid(input), "guid");
break;
case BRANCH_UUID:
- Long uuid = proxy.getBranchId();
- Conditions.checkExpressionFailOnTrue(uuid <= 0L,
- String.format("branchUuid should be > 0, but is [%d]", uuid));
- input = String.valueOf(uuid);
+ BranchId branch = proxy.getBranch();
+ Conditions.checkExpressionFailOnTrue(branch.isInvalid(),
+ String.format("branch id should be > 0, but is [%s]", branch.getIdString()));
+ input = branch.getIdString();
break;
case ARTIFACT_NAME:
input = proxy.getName();
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java
index eb5aea7ffe8..9c8b366330f 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java
@@ -642,7 +642,7 @@ public class Artifact extends FullyNamedIdentity<String> implements IArtifact, A
attributeType, getArtifactTypeName());
}
throw new AttributeDoesNotExist("Attribute of type [%s] could not be found on artifact [%s] on branch [%s]",
- attributeType, this, getBranchId());
+ attributeType, this, getBranch());
} else if (soleAttributes.size() > 1) {
throw new MultipleAttributesExist(
"Attribute [%s] must have exactly one instance. It currently has %d for artifact [%s]", attributeType,
@@ -674,7 +674,7 @@ public class Artifact extends FullyNamedIdentity<String> implements IArtifact, A
} else if (soleAttributes.size() > 1) {
throw new MultipleAttributesExist(
"Attribute [%s] must have exactly one instance. It currently has %d for artifact [%s] on branch [%d]",
- attributeType, soleAttributes.size(), getGuid(), getBranchId());
+ attributeType, soleAttributes.size(), getGuid(), getBranch());
} else {
return defaultReturnValue;
}
@@ -723,7 +723,7 @@ public class Artifact extends FullyNamedIdentity<String> implements IArtifact, A
} else if (soleAttributes.size() > 1) {
throw new MultipleAttributesExist(
"Attribute [%s] must have exactly one instance. It currently has %d for artifact [%s] on branch [%d]",
- attributeType, soleAttributes.size(), getGuid(), getBranchId());
+ attributeType, soleAttributes.size(), getGuid(), getBranch());
} else {
return defaultReturnValue;
}
@@ -1585,7 +1585,7 @@ public class Artifact extends FullyNamedIdentity<String> implements IArtifact, A
DefaultBasicGuidArtifact other = (DefaultBasicGuidArtifact) obj;
boolean result = getGuid().equals(other.getGuid());
if (result) {
- if (getBranchId() != null && other.getBranchId() != null) {
+ if (getBranch().isValid() && other.getBranch().isValid()) {
result = isOnSameBranch(other);
}
}
@@ -1595,10 +1595,10 @@ public class Artifact extends FullyNamedIdentity<String> implements IArtifact, A
IArtifact other = (IArtifact) obj;
boolean result = getGuid().equals(other.getGuid());
if (result) {
- if (getBranch() != null && other.getBranch() != null) {
+ if (getBranch().isValid() && other.getBranch().isValid()) {
result = isOnSameBranch(other);
} else {
- result = getBranch() == null && other.getBranch() == null;
+ result = getBranch().isInvalid() && other.getBranch().isInvalid();
}
}
return result;
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/commit/actions/CatchWordMlChanges.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/commit/actions/CatchWordMlChanges.java
index 181d93740e1..6bfb793c187 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/commit/actions/CatchWordMlChanges.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/commit/actions/CatchWordMlChanges.java
@@ -126,6 +126,6 @@ public class CatchWordMlChanges implements CommitAction {
private String getArtifactErrorMessage(Artifact artifact) {
return String.format("Error validating: [(%s)(%s) - %s] on branchUuid:[%s]", artifact.getArtId(),
- artifact.getGuid(), artifact.getName(), artifact.getBranchId());
+ artifact.getGuid(), artifact.getName(), artifact.getBranch());
}
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java
index 23562633d11..33227487ab2 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java
@@ -248,7 +248,7 @@ public class RelationManager {
JdbcStatement chStmt = ConnectionHandler.getStatement();
try {
String sql = String.format(GET_DELETED_ARTIFACT, formatArgs);
- chStmt.runPreparedQuery(sql, artifact.getBranchId(), relationType.getGuid(), artifact.getArtId());
+ chStmt.runPreparedQuery(sql, artifact.getBranch(), relationType.getGuid(), artifact.getArtId());
while (chStmt.next()) {
int artId = chStmt.getInt(formatArgs[0] + "_art_id");
artIds.add(artId);
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java
index a10bca43905..348cb1e76a5 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java
@@ -63,10 +63,10 @@ public class ArtifactChangeAcquirer extends ChangeAcquirer {
if (getSpecificArtifact() != null) {
chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ARTIFACT_FOR_SPECIFIC_ARTIFACT),
- toTransactionId.getBranchId(), toTransactionId.getId(), getSpecificArtifact().getArtId());
+ toTransactionId.getBranch(), toTransactionId.getId(), getSpecificArtifact().getArtId());
fromTransactionId = toTransactionId;
} else {
- chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ARTIFACT), toTransactionId.getBranchId(),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ARTIFACT), toTransactionId.getBranch(),
toTransactionId.getId());
fromTransactionId = TransactionManager.getPriorTransaction(toTransactionId);
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java
index b93a36aa661..2071ec22cdd 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java
@@ -81,10 +81,10 @@ public class AttributeChangeAcquirer extends ChangeAcquirer {
toTransaction = getTransaction();
if (hasSpecificArtifact) {
chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ATTRIBUTE_IS_FOR_SPECIFIC_ARTIFACT),
- toTransaction.getBranchId(), toTransaction.getId(), getSpecificArtifact().getArtId());
+ toTransaction.getBranch(), toTransaction.getId(), getSpecificArtifact().getArtId());
fromTransactionId = getTransaction();
} else {
- chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ATTRIBUTE_IS), toTransaction.getBranchId(),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ATTRIBUTE_IS), toTransaction.getBranch(),
toTransaction.getId());
fromTransactionId = TransactionManager.getPriorTransaction(toTransaction);
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java
index 05a0caf946a..5b287dbd161 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java
@@ -61,11 +61,11 @@ public class RelationChangeAcquirer extends ChangeAcquirer {
if (getSpecificArtifact() != null) {
chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_RELATION_FOR_SPECIFIC_ARTIFACT),
- toTransactionId.getBranchId(), toTransactionId.getId(), getSpecificArtifact().getArtId(),
+ toTransactionId.getBranch(), toTransactionId.getId(), getSpecificArtifact().getArtId(),
getSpecificArtifact().getArtId());
fromTransactionId = toTransactionId;
} else {
- chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_RELATION), toTransactionId.getBranchId(),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_RELATION), toTransactionId.getBranch(),
toTransactionId.getId());
fromTransactionId = TransactionManager.getPriorTransaction(toTransactionId);
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java
index 283a0bf9c1b..5b5832e4e2c 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java
@@ -192,7 +192,7 @@ public final class TransactionManager {
public static synchronized void internalPersist(JdbcConnection connection, TransactionRecord transactionRecord) throws OseeCoreException {
ConnectionHandler.runPreparedUpdate(connection, INSERT_INTO_TRANSACTION_DETAIL, transactionRecord.getId(),
transactionRecord.getComment(), transactionRecord.getTimeStamp(), transactionRecord.getAuthor(),
- transactionRecord.getBranchId(), transactionRecord.getTxType().getId());
+ transactionRecord.getBranch(), transactionRecord.getTxType().getId());
}
public static TransactionToken getTransactionAtDate(BranchId branch, Date maxDateExclusive) throws OseeCoreException {
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/editor/ArtifactEditorInputFactory.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/editor/ArtifactEditorInputFactory.java
index 570c76bc2d6..5ba032c187b 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/editor/ArtifactEditorInputFactory.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/editor/ArtifactEditorInputFactory.java
@@ -58,9 +58,9 @@ public class ArtifactEditorInputFactory implements IElementFactory {
Artifact artifact = input.getArtifact();
if (artifact != null) {
String artUuid = artifact.getIdString();
- long branchUuid = artifact.getBranchId();
- if (Strings.isValid(artUuid) && branchUuid > 0 && Strings.isValid(title)) {
- memento.putString(BRANCH_KEY, String.valueOf(branchUuid));
+ BranchId branchId = artifact.getBranch();
+ if (Strings.isValid(artUuid) && branchId.isValid() && Strings.isValid(title)) {
+ memento.putString(BRANCH_KEY, branchId.getIdString());
memento.putString(ART_KEY, artUuid);
memento.putString(TITLE, title);
}
diff --git a/plugins/org.eclipse.osee.orcs.rest/src/org/eclipse/osee/orcs/rest/internal/OrcsRestUtil.java b/plugins/org.eclipse.osee.orcs.rest/src/org/eclipse/osee/orcs/rest/internal/OrcsRestUtil.java
index d7fe5ea1d2b..a6972fba2de 100644
--- a/plugins/org.eclipse.osee.orcs.rest/src/org/eclipse/osee/orcs/rest/internal/OrcsRestUtil.java
+++ b/plugins/org.eclipse.osee.orcs.rest/src/org/eclipse/osee/orcs/rest/internal/OrcsRestUtil.java
@@ -86,7 +86,7 @@ public final class OrcsRestUtil {
Transaction data = new Transaction();
data.setTxId(tx);
data.setAuthor(tx.getAuthor());
- data.setBranchUuid(tx.getBranchId());
+ data.setBranchUuid(tx.getBranch().getId());
data.setComment(tx.getComment());
data.setCommitArt(tx.getCommitArt());
data.setTimeStamp(tx.getDate());

Back to the top