e15c2dc7c40f8b5fb6c7680d0c513a9271aec4b3
[controller.git] / opendaylight / md-sal / cds-access-api / src / main / java / org / opendaylight / controller / cluster / access / commands / TransactionSuccess.java
1 /*
2  * Copyright (c) 2016 Cisco Systems, Inc. and others.  All rights reserved.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  */
8 package org.opendaylight.controller.cluster.access.commands;
9
10 import com.google.common.annotations.Beta;
11 import org.opendaylight.controller.cluster.access.ABIVersion;
12 import org.opendaylight.controller.cluster.access.concepts.RequestSuccess;
13 import org.opendaylight.controller.cluster.access.concepts.TransactionIdentifier;
14
15 /**
16  * Abstract base class for {@link RequestSuccess}es involving specific transaction. This class is visible outside of
17  * this package solely for the ability to perform a unified instanceof check.
18  *
19  * @author Robert Varga
20  *
21  * @param <T> Message type
22  */
23 @Beta
24 public abstract class TransactionSuccess<T extends TransactionSuccess<T>>
25         extends RequestSuccess<TransactionIdentifier, T> {
26     private static final long serialVersionUID = 1L;
27
28     TransactionSuccess(final TransactionIdentifier identifier, final long sequence) {
29         super(identifier, sequence);
30     }
31
32     @Override
33     protected abstract AbstractTransactionSuccessProxy<T> externalizableProxy(ABIVersion version);
34 }