BUG-5280: eliminate ShardTransactionIdentifier
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / main / java / org / opendaylight / controller / cluster / datastore / identifiers / ShardTransactionIdentifier.java
diff --git a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/identifiers/ShardTransactionIdentifier.java b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/identifiers/ShardTransactionIdentifier.java
deleted file mode 100644 (file)
index fa1525c..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Copyright (c) 2014 Cisco Systems, Inc. and others.  All rights reserved.
- *
- * This program and the accompanying materials are made available under the
- * terms of the Eclipse Public License v1.0 which accompanies this distribution,
- * and is available at http://www.eclipse.org/legal/epl-v10.html
- */
-
-package org.opendaylight.controller.cluster.datastore.identifiers;
-
-import com.google.common.base.Preconditions;
-
-public class ShardTransactionIdentifier {
-    private final String remoteTransactionId;
-    private final String stringRepresentation;
-
-    public ShardTransactionIdentifier(String remoteTransactionId) {
-        this.remoteTransactionId = Preconditions.checkNotNull(remoteTransactionId,
-                "remoteTransactionId should not be null");
-
-        stringRepresentation = new StringBuilder(remoteTransactionId.length() + 6).append("shard-").
-                append(remoteTransactionId).toString();
-    }
-
-    public String getRemoteTransactionId() {
-        return remoteTransactionId;
-    }
-
-    @Override
-    public boolean equals(Object o) {
-        if (this == o) {
-            return true;
-        }
-        if (o == null || getClass() != o.getClass()) {
-            return false;
-        }
-
-        ShardTransactionIdentifier that = (ShardTransactionIdentifier) o;
-
-        if (!remoteTransactionId.equals(that.remoteTransactionId)) {
-            return false;
-        }
-
-        return true;
-    }
-
-    @Override
-    public int hashCode() {
-        return remoteTransactionId.hashCode();
-    }
-
-    @Override public String toString() {
-        return stringRepresentation;
-    }
-
-}