比特币(BSV)知识库:交易-VOUT

BSV知识库 专栏收录该内容
73 篇文章 3 订阅

特别提示:

比特币(BSV)知识库-Bitcoin wiki-目前为全英文内容,暂无中文译文,并且仍在持续编写和补充中。欢迎中国的开发者在文章底部评论,进行阐述和探讨。

VOUT

transaction outpoint or transaction output number is (most often used to refer to) a 4-bye index indicating the position of a transaction output.

Technical Details

In the technical specification of Bitcoin SV "vout" has two interpretations. When it appears in an input of a transaction, it is a 4 byte index value. This index is concatenated with a transaction ID (TxID || vout) to form an outpoint, uniquely identifying an output of the (previous) transaction output being spent. As the index is a 4-byte integer, this gives users the ability to include up to 232 outputs in a single Bitcoin transaction.

When it is not part of the input, it refers to a vector of outputs in a transaction. That is, "vout" is the keyword identifying the list of all outputs of a transaction [1], where each output contains output value (the amount of BSV) and scriptPubKey (a script that locks the output value). Note that the order within the set matters.

Unspent Transaction Outputs

If an outpoint has not been spent, it is referred to as an Unspent Transaction Output or UTXO and can be used in the creation of a new transaction by a user that is able to satisfy the spending conditions defined by the output script. Once an outpoint has been used as an input to a transaction that has been validated by the mining network it is considered spent and can no longer be used in a new transaction (see Double-spending).

Zero value outputs

Outputs that do not contain a value in Satoshis are often used to hold scripts that carry large data items or tokens. Provably unspendable zero-value False Return outputs have been predominantly used as a means to attach data to bitcoin transactions. False return transaction outputs are not stored in the UTXO set derived by miners. It should be noted that this is not the only mechanism for data storage, it is just the one that was easiest to use prior to the Genesis protocol restoration.

Non-false return zero value outputs are still valid UTXOs and can be used as inputs in a transaction, with locking conditions being applied as normal.

See Also

References

[1] - https://github.com/bitcoin-sv/bitcoin-sv/blob/7fd177c7c443ff7723d88c5465fbf39285388e30/src/primitives/transaction.h

 声明:

比特币(BSV)知识库项目由比特币协会(Bitcoin Association)发起并支持,更多信息请参见知识库官网:https://wiki.bitcoinsv.io/


  • 对比特币区块链开发感兴趣的朋友可以通过CSDN站内私信联系我们,申请加入BSV开发者交流群。
  • 同时,您也可以扫描下方二维码,关注比特币协会官方微信公众号——BA资讯,了解更多区块链领域的实时资讯。

 

  • 0
    点赞
  • 0
    评论
  • 0
    收藏
  • 扫一扫,分享海报

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、C币套餐、付费专栏及课程。

余额充值