/** * Reconstitute the transaction ID from this serialized representation. * * @return the transaction ID object */ protected Object readResolve() { return createTransactionID(id); } }
/** * Determine whether this object is equal to another. Transaction IDs are equal if their encoded form is * equal and the class is equal. * * @param other the other object * @return {@code true} if they are equal, {@code false} otherwise */ @Override public final boolean equals(Object other) { return other.getClass() == getClass() && equals((TransactionID) other); }
os.writeByte(type); os.writeShort(invocation.getIndex()); final byte[] encoded = transactionID.getEncodedForm(); PackedInteger.writePackedInteger(os, encoded.length); os.write(encoded);
os.writeByte(type); os.writeShort(invocation.getIndex()); final byte[] encoded = transactionID.getEncodedForm(); PackedInteger.writePackedInteger(os, encoded.length); os.write(encoded);
target[4 + length] = (byte) (id >> 8); target[5 + length] = (byte) id; final UserTransactionID uti = (UserTransactionID) TransactionID.createTransactionID(target); if (userTxnIds.putIfAbsent(uti) == null) { return uti;
/** * Determine whether this object is equal to another. Transaction IDs are equal if their encoded form is * equal and the class is equal. * * @param other the other object * @return {@code true} if they are equal, {@code false} otherwise */ @Override public final boolean equals(Object other) { return other.getClass() == getClass() && equals((TransactionID) other); }
os.writeByte(type); os.writeShort(invocation.getIndex()); final byte[] encoded = transactionID.getEncodedForm(); PackedInteger.writePackedInteger(os, encoded.length); os.write(encoded);
private void handleTxnRequest(final int code, final int invId, final MessageInputStream message) throws IOException { final byte[] bytes = new byte[PackedInteger.readPackedInteger(message)]; message.readFully(bytes); final TransactionID transactionID = TransactionID.createTransactionID(bytes); if (transactionID instanceof XidTransactionID) try { final SubordinateTransactionControl control = transactionServer.getTransactionService().getTransactionContext().findOrImportTransaction(((XidTransactionID) transactionID).getXid(), 0).getControl();
/** * Determine whether this object is equal to another. Transaction IDs are equal if their encoded form is * equal and the class is equal. * * @param other the other object * @return {@code true} if they are equal, {@code false} otherwise */ @Override public final boolean equals(Object other) { return other.getClass() == getClass() && equals((TransactionID) other); }
/** * Reconstitute the transaction ID from this serialized representation. * * @return the transaction ID object */ protected Object readResolve() { return createTransactionID(id); } }
/** * Reconstitute the transaction ID from this serialized representation. * * @return the transaction ID object */ protected Object readResolve() { return createTransactionID(id); } }
target[4 + length] = (byte) (id >> 8); target[5 + length] = (byte) id; final UserTransactionID uti = (UserTransactionID) TransactionID.createTransactionID(target); if (userTxnIds.putIfAbsent(uti) == null) { return uti;
target[4 + length] = (byte) (id >> 8); target[5 + length] = (byte) id; final UserTransactionID uti = (UserTransactionID) TransactionID.createTransactionID(target); if (userTxnIds.putIfAbsent(uti) == null) { return uti;
final TransactionID transactionID = TransactionID.createTransactionID(transactionIDBytes);
private void handleTxnRequest(final int code, final int invId, final MessageInputStream message) throws IOException { final byte[] bytes = new byte[PackedInteger.readPackedInteger(message)]; message.readFully(bytes); final TransactionID transactionID = TransactionID.createTransactionID(bytes); if (transactionID instanceof XidTransactionID) try { final SubordinateTransactionControl control = transactionServer.getTransactionService().getTransactionContext().findOrImportTransaction(((XidTransactionID) transactionID).getXid(), 0).getControl();
private void handleTxnRequest(final int code, final int invId, final MessageInputStream message) throws IOException { final byte[] bytes = new byte[PackedInteger.readPackedInteger(message)]; message.readFully(bytes); final TransactionID transactionID = TransactionID.createTransactionID(bytes); if (transactionID instanceof XidTransactionID) try { final SubordinateTransactionControl control = transactionServer.getTransactionService().getTransactionContext().findOrImportTransaction(((XidTransactionID) transactionID).getXid(), 0).getControl();