Class: Nis::Struct::Transaction
- Inherits:
-
Object
- Object
- Nis::Struct::Transaction
- Includes:
- Util::Assignable
- Defined in:
- lib/nis/struct/transaction.rb
Overview
Constant Summary collapse
- TRANSFER =
257 (transfer transaction)
0x0101- IMPORTANCE_TRANSFER =
2049 (importance transfer transaction)
0x0801- MULTISIG_AGGREGATE_MODIFICATION_TRANSFER =
4097 (multisig aggregate modification transfer transaction)
0x1001- MULTISIG_SIGNATURE =
4098 (multisig signature transaction)
0x1002- MULTISIG =
4099 (multisig transaction)
0x1004- PROVISION_NAMESPACE =
8193 (provision namespace transaction)
0x2001- MOSAIC_DEFINITION_CREATION =
16385 (mosaic definition creation transaction)
0x4001- MOSAIC_SUPPLY_CHANGE =
16386 (mosaic supply change transaction)
0x4002- TESTNET =
-1744830464
0x98000000- MAINNET =
1744830464
0x68000000- VERSION_1 =
1
0x00000001- VERSION_2 =
2
0x00000002- TESTNET_VERSION_1 =
0x98000001 = -1744830463
TESTNET | VERSION_1
- TESTNET_VERSION_2 =
0x98000002 = -1744830462
TESTNET | VERSION_2
- MAINNET_VERSION_1 =
0x68000001 = 1744830465
MAINNET | VERSION_1
- MAINNET_VERSION_2 =
0x68000002 = 1744830466
MAINNET | VERSION_2
Instance Attribute Summary collapse
-
#amount ⇒ Integer
The current value of amount.
-
#deadline ⇒ Integer
The current value of deadline.
-
#fee ⇒ Integer
The current value of fee.
-
#message ⇒ String
The current value of message.
-
#mosaics ⇒ Array <Nis::Struct::MosaicId>
The current value of mosaics.
-
#recipient ⇒ String
The current value of recipient.
-
#signer ⇒ String
The current value of signer.
-
#timeStamp ⇒ Object
(also: #timestamp)
Returns the value of attribute timeStamp.
-
#type ⇒ Integer
The current value of type.
-
#version ⇒ Integer
The current value of version.
Class Method Summary collapse
Instance Method Summary collapse
Methods included from Util::Assignable
#[], #initialize, #to_hash, #to_json
Instance Attribute Details
#amount ⇒ Integer
Returns the current value of amount.
16 17 18 |
# File 'lib/nis/struct/transaction.rb', line 16 def amount @amount end |
#deadline ⇒ Integer
Returns the current value of deadline.
16 17 18 |
# File 'lib/nis/struct/transaction.rb', line 16 def deadline @deadline end |
#fee ⇒ Integer
Returns the current value of fee.
16 17 18 |
# File 'lib/nis/struct/transaction.rb', line 16 def fee @fee end |
#message ⇒ String
Returns the current value of message.
16 17 18 |
# File 'lib/nis/struct/transaction.rb', line 16 def end |
#mosaics ⇒ Array <Nis::Struct::MosaicId>
Returns the current value of mosaics.
16 17 18 |
# File 'lib/nis/struct/transaction.rb', line 16 def mosaics @mosaics end |
#recipient ⇒ String
Returns the current value of recipient.
16 17 18 |
# File 'lib/nis/struct/transaction.rb', line 16 def recipient @recipient end |
#signer ⇒ String
Returns the current value of signer.
16 17 18 |
# File 'lib/nis/struct/transaction.rb', line 16 def signer @signer end |
#timeStamp ⇒ Object Also known as: timestamp
Returns the value of attribute timeStamp.
18 19 20 |
# File 'lib/nis/struct/transaction.rb', line 18 def timeStamp @timeStamp end |
#type ⇒ Integer
Returns the current value of type.
16 17 18 |
# File 'lib/nis/struct/transaction.rb', line 16 def type @type end |
#version ⇒ Integer
Returns the current value of version.
16 17 18 |
# File 'lib/nis/struct/transaction.rb', line 16 def version @version end |
Class Method Details
.build(attrs) ⇒ Object
46 47 48 |
# File 'lib/nis/struct/transaction.rb', line 46 def self.build(attrs) new(attrs) end |
Instance Method Details
#_version ⇒ Integer
51 52 53 |
# File 'lib/nis/struct/transaction.rb', line 51 def _version (0xFFFFFFF0 & @version) end |
#mainnet? ⇒ Boolean
61 62 63 |
# File 'lib/nis/struct/transaction.rb', line 61 def mainnet? (0x0000000F & @version) == MAINNET end |
#testnet? ⇒ Boolean
56 57 58 |
# File 'lib/nis/struct/transaction.rb', line 56 def testnet? (0x0000000F & @version) == TESTNET end |