3
0
mirror of https://github.com/Qortal/altcoinj.git synced 2025-02-15 03:35:52 +00:00

Remove comments about sequence numbers being disabled.

As of Bitcoin Core 0.12, sequence numbers are used for the infamous opt-in full replace-by-fee feature.
This commit is contained in:
Andreas Schildbach 2016-01-25 12:28:21 +01:00
parent 1c6fa9ceb9
commit ee1aa05460
3 changed files with 12 additions and 16 deletions

View File

@ -46,9 +46,7 @@ public class TransactionInput extends ChildMessage {
// Magic outpoint index that indicates the input is in fact unconnected.
private static final long UNCONNECTED = 0xFFFFFFFFL;
// Allows for altering transactions after they were broadcast. Tx replacement is currently disabled in the C++
// client so this is always the UINT_MAX.
// TODO: Document this in more detail and build features that use it.
// Allows for altering transactions after they were broadcast.
private long sequence;
// Data needed to connect to the output of the transaction we're gathering coins from.
private TransactionOutPoint outpoint;
@ -193,8 +191,7 @@ public class TransactionInput extends ChildMessage {
* Sequence numbers allow participants in a multi-party transaction signing protocol to create new versions of the
* transaction independently of each other. Newer versions of a transaction can replace an existing version that's
* in nodes memory pools if the existing version is time locked. See the Contracts page on the Bitcoin wiki for
* examples of how you can use this feature to build contract protocols. Note that as of 2012 the tx replacement
* feature is disabled so sequence numbers are unusable.
* examples of how you can use this feature to build contract protocols.
*/
public long getSequenceNumber() {
return sequence;
@ -204,8 +201,7 @@ public class TransactionInput extends ChildMessage {
* Sequence numbers allow participants in a multi-party transaction signing protocol to create new versions of the
* transaction independently of each other. Newer versions of a transaction can replace an existing version that's
* in nodes memory pools if the existing version is time locked. See the Contracts page on the Bitcoin wiki for
* examples of how you can use this feature to build contract protocols. Note that as of 2012 the tx replacement
* feature is disabled so sequence numbers are unusable.
* examples of how you can use this feature to build contract protocols.
*/
public void setSequenceNumber(long sequence) {
unCache();

View File

@ -4879,7 +4879,7 @@ public final class Protos {
* <code>optional uint32 sequence = 4;</code>
*
* <pre>
* Sequence number. Currently unused, but intended for contracts in future.
* Sequence number.
* </pre>
*/
boolean hasSequence();
@ -4887,7 +4887,7 @@ public final class Protos {
* <code>optional uint32 sequence = 4;</code>
*
* <pre>
* Sequence number. Currently unused, but intended for contracts in future.
* Sequence number.
* </pre>
*/
int getSequence();
@ -5101,7 +5101,7 @@ public final class Protos {
* <code>optional uint32 sequence = 4;</code>
*
* <pre>
* Sequence number. Currently unused, but intended for contracts in future.
* Sequence number.
* </pre>
*/
public boolean hasSequence() {
@ -5111,7 +5111,7 @@ public final class Protos {
* <code>optional uint32 sequence = 4;</code>
*
* <pre>
* Sequence number. Currently unused, but intended for contracts in future.
* Sequence number.
* </pre>
*/
public int getSequence() {
@ -5617,7 +5617,7 @@ public final class Protos {
* <code>optional uint32 sequence = 4;</code>
*
* <pre>
* Sequence number. Currently unused, but intended for contracts in future.
* Sequence number.
* </pre>
*/
public boolean hasSequence() {
@ -5627,7 +5627,7 @@ public final class Protos {
* <code>optional uint32 sequence = 4;</code>
*
* <pre>
* Sequence number. Currently unused, but intended for contracts in future.
* Sequence number.
* </pre>
*/
public int getSequence() {
@ -5637,7 +5637,7 @@ public final class Protos {
* <code>optional uint32 sequence = 4;</code>
*
* <pre>
* Sequence number. Currently unused, but intended for contracts in future.
* Sequence number.
* </pre>
*/
public Builder setSequence(int value) {
@ -5650,7 +5650,7 @@ public final class Protos {
* <code>optional uint32 sequence = 4;</code>
*
* <pre>
* Sequence number. Currently unused, but intended for contracts in future.
* Sequence number.
* </pre>
*/
public Builder clearSequence() {

View File

@ -149,7 +149,7 @@ message TransactionInput {
required uint32 transaction_out_point_index = 2;
// Script that contains the signatures/pubkeys.
required bytes script_bytes = 3;
// Sequence number. Currently unused, but intended for contracts in future.
// Sequence number.
optional uint32 sequence = 4;
// Value of connected output, if known
optional int64 value = 5;