lib/libra/account_resource.rb in libra_client-0.1.5 vs lib/libra/account_resource.rb in libra_client-0.1.6
- old
+ new
@@ -2,10 +2,17 @@
module Libra
class AccountState < Canoser::Struct
define_field :blob, {}
end
+ EVENT_KEY_LENGTH = 32
+
+ class EventHandle < Canoser::Struct
+ define_field :count, Canoser::Uint64
+ define_field :key, [Canoser::Uint8] #EVENT_KEY_LENGTH
+ end
+
# pub struct AccountResource {
# balance: u64,
# sequence_number: u64,
# authentication_key: ByteArray,
# delegated_withdrawal_capability: bool,
@@ -29,10 +36,10 @@
# }
class AccountResource < Canoser::Struct
define_field :authentication_key, [Canoser::Uint8]
define_field :balance, Canoser::Uint64
define_field :delegated_withdrawal_capability, Canoser::Bool
- define_field :received_events_count, Canoser::Uint64
- define_field :sent_events_count, Canoser::Uint64
+ define_field :received_events, EventHandle
+ define_field :sent_events, EventHandle
define_field :sequence_number, Canoser::Uint64
end
end