sequence-sdk 2.pre.rc.1 → 2.rc.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/README.md +1 -1
- data/lib/sequence/account.rb +8 -9
- data/lib/sequence/flavor.rb +2 -3
- data/lib/sequence/page.rb +2 -2
- data/lib/sequence/query.rb +0 -4
- data/lib/sequence/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 80046724787cef42cc5cfe5b48be511642f5a172
|
4
|
+
data.tar.gz: a5adced85eb8e1b2b308b80d5f5503ac81a6f43f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fdf382e4fe52769f2bd41411b3b8d976f91be421cee167f1ae654ac47c0cdc9fdc8f8644566b1056e1abe9d8086f8dd92abea602c1d3e5968b971c87dbcbf616
|
7
|
+
data.tar.gz: 91bb7b0f99a1dd0a1e01e2ec0912e36638fceddedacb607d931df017da075ad7d921677181448b00a8d5d78d3f75e6b7654e607ed7c84d068eb03ff7118592c3
|
data/README.md
CHANGED
data/lib/sequence/account.rb
CHANGED
@@ -6,8 +6,7 @@ require_relative './query'
|
|
6
6
|
require_relative './response_object'
|
7
7
|
|
8
8
|
module Sequence
|
9
|
-
#
|
10
|
-
# blockchain by creating and tracking control programs.
|
9
|
+
# A container that holds tokens in a ledger.
|
11
10
|
class Account < ResponseObject
|
12
11
|
# @!attribute [r] id
|
13
12
|
# Unique identifier of the account.
|
@@ -15,14 +14,13 @@ module Sequence
|
|
15
14
|
attrib :id
|
16
15
|
|
17
16
|
# @!attribute [r] key_ids
|
18
|
-
# The
|
19
|
-
# account.
|
17
|
+
# The list of IDs for the keys that control the account.
|
20
18
|
# @return [Array<String>]
|
21
19
|
attrib(:key_ids)
|
22
20
|
|
23
21
|
# @!attribute [r] quorum
|
24
|
-
# The number of keys required to sign transactions that
|
25
|
-
# account.
|
22
|
+
# The number of keys required to sign transactions that transfer or retire
|
23
|
+
# tokens from the account.
|
26
24
|
# @return [Integer]
|
27
25
|
attrib :quorum
|
28
26
|
|
@@ -38,12 +36,13 @@ module Sequence
|
|
38
36
|
class ClientModule < Sequence::ClientModule
|
39
37
|
# Create a new account in the ledger.
|
40
38
|
# @param key_ids [Array<String>]
|
41
|
-
# The
|
39
|
+
# The list of IDs for the keys that control the account.
|
42
40
|
# @param id [String]
|
43
41
|
# Unique identifier. Auto-generated if not specified.
|
44
42
|
# @param quorum [Integer]
|
45
|
-
# The number of keys required to sign transactions that
|
46
|
-
# account. Defaults to the number of keys
|
43
|
+
# The number of keys required to sign transactions that transfer or
|
44
|
+
# retire tokens from the account. Defaults to the number of keys
|
45
|
+
# provided.
|
47
46
|
# @param tags [Hash]
|
48
47
|
# User-specified key-value data describing the account.
|
49
48
|
# @return [Account]
|
data/lib/sequence/flavor.rb
CHANGED
@@ -8,7 +8,7 @@ require_relative './query'
|
|
8
8
|
require_relative './response_object'
|
9
9
|
|
10
10
|
module Sequence
|
11
|
-
# A
|
11
|
+
# A taxonomy used to differentiate different types of tokens in a ledger.
|
12
12
|
class Flavor < ResponseObject
|
13
13
|
# @!attribute [r] id
|
14
14
|
# Unique identifier of the flavor.
|
@@ -16,8 +16,7 @@ module Sequence
|
|
16
16
|
attrib :id
|
17
17
|
|
18
18
|
# @!attribute [r] key_ids
|
19
|
-
# The
|
20
|
-
# flavor.
|
19
|
+
# The list of IDs for the keys that control the flavor.
|
21
20
|
# @return [Array<String>]
|
22
21
|
attrib(:key_ids)
|
23
22
|
|
data/lib/sequence/page.rb
CHANGED
@@ -24,11 +24,11 @@ module Sequence
|
|
24
24
|
|
25
25
|
def initialize(raw_attribs, translate)
|
26
26
|
super(raw_attribs)
|
27
|
-
@items = @items.map { |i| translate.call(i) }
|
27
|
+
@items = (@items || []).map { |i| translate.call(i) }
|
28
28
|
end
|
29
29
|
|
30
30
|
def each
|
31
|
-
@items.
|
31
|
+
@items.each do |item|
|
32
32
|
yield item
|
33
33
|
end
|
34
34
|
end
|
data/lib/sequence/query.rb
CHANGED
@@ -42,8 +42,6 @@ module Sequence
|
|
42
42
|
raise NotImplementedError
|
43
43
|
end
|
44
44
|
|
45
|
-
alias all to_a
|
46
|
-
|
47
45
|
# @private
|
48
46
|
def pages
|
49
47
|
PageQuery.new(client, query, method(:fetch), method(:translate))
|
@@ -88,8 +86,6 @@ module Sequence
|
|
88
86
|
def page
|
89
87
|
Page.new(@fetch.call(@query), @translate)
|
90
88
|
end
|
91
|
-
|
92
|
-
alias all to_a
|
93
89
|
end
|
94
90
|
end
|
95
91
|
end
|
data/lib/sequence/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sequence-sdk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.rc.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chain Engineering
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-04-
|
11
|
+
date: 2018-04-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -181,7 +181,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
181
181
|
version: 1.3.1
|
182
182
|
requirements: []
|
183
183
|
rubyforge_project:
|
184
|
-
rubygems_version: 2.
|
184
|
+
rubygems_version: 2.6.13
|
185
185
|
signing_key:
|
186
186
|
specification_version: 4
|
187
187
|
summary: SDK for Sequence
|