radar-api 0.11.1 → 0.11.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/gen/radar/api/transaction_types.rb +76 -14
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b0dcdbbab56b1dc0d52ab97fd15fb1833e91842c
|
4
|
+
data.tar.gz: 45fd2b733a4d65fa3d489a4e42f649060546f6eb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f87c4bd3b9170f151900765c8e2aa512d2716714b1ea0f0a2da620869354b7f204a9b394c6f922a7b87699ae78cb769303fab4bb094362cdf60de474f1fb9bb6
|
7
|
+
data.tar.gz: '08c4c4bec459330945fd031e54e4dcae97b9143b70dd495cb20634680077743ef25530da12c30e84c4b9669eca11a6b0c667980201047e5d6b943f3da1c229dd'
|
@@ -38,11 +38,11 @@ module Radar
|
|
38
38
|
VALID_VALUES = Set.new([IN, OUT]).freeze
|
39
39
|
end
|
40
40
|
|
41
|
-
module
|
42
|
-
|
43
|
-
|
44
|
-
VALUE_MAP = {1 => "
|
45
|
-
VALID_VALUES = Set.new([
|
41
|
+
module OptionExerciseType
|
42
|
+
BUY = 1
|
43
|
+
SELL = 2
|
44
|
+
VALUE_MAP = {1 => "BUY", 2 => "SELL"}
|
45
|
+
VALID_VALUES = Set.new([BUY, SELL]).freeze
|
46
46
|
end
|
47
47
|
|
48
48
|
class StockSell; end
|
@@ -61,7 +61,11 @@ module Radar
|
|
61
61
|
|
62
62
|
class Transfer; end
|
63
63
|
|
64
|
-
class
|
64
|
+
class StockPositionSnapshot; end
|
65
|
+
|
66
|
+
class OptionPositionSnapshot; end
|
67
|
+
|
68
|
+
class OptionExercisePositionSnapshot; end
|
65
69
|
|
66
70
|
class Transaction < ::Thrift::Union; end
|
67
71
|
|
@@ -271,14 +275,60 @@ module Radar
|
|
271
275
|
::Thrift::Struct.generate_accessors self
|
272
276
|
end
|
273
277
|
|
274
|
-
class
|
278
|
+
class StockPositionSnapshot
|
279
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
280
|
+
DATE = 1
|
281
|
+
STOCK = 2
|
282
|
+
SHARES = 3
|
283
|
+
PRICE = 4
|
284
|
+
|
285
|
+
FIELDS = {
|
286
|
+
DATE => {:type => ::Thrift::Types::I64, :name => 'date'},
|
287
|
+
STOCK => {:type => ::Thrift::Types::STRUCT, :name => 'stock', :class => ::Radar::Api::StockId},
|
288
|
+
SHARES => {:type => ::Thrift::Types::I32, :name => 'shares'},
|
289
|
+
PRICE => {:type => ::Thrift::Types::DOUBLE, :name => 'price'}
|
290
|
+
}
|
291
|
+
|
292
|
+
def struct_fields; FIELDS; end
|
293
|
+
|
294
|
+
def validate
|
295
|
+
end
|
296
|
+
|
297
|
+
::Thrift::Struct.generate_accessors self
|
298
|
+
end
|
299
|
+
|
300
|
+
class OptionPositionSnapshot
|
275
301
|
include ::Thrift::Struct, ::Thrift::Struct_Union
|
276
302
|
DATE = 1
|
277
303
|
STOCK = 2
|
278
304
|
SHARES = 3
|
279
305
|
PRICE = 4
|
280
306
|
MATURITY = 5
|
281
|
-
|
307
|
+
|
308
|
+
FIELDS = {
|
309
|
+
DATE => {:type => ::Thrift::Types::I64, :name => 'date'},
|
310
|
+
STOCK => {:type => ::Thrift::Types::STRUCT, :name => 'stock', :class => ::Radar::Api::StockId},
|
311
|
+
SHARES => {:type => ::Thrift::Types::I32, :name => 'shares'},
|
312
|
+
PRICE => {:type => ::Thrift::Types::DOUBLE, :name => 'price'},
|
313
|
+
MATURITY => {:type => ::Thrift::Types::I64, :name => 'maturity'}
|
314
|
+
}
|
315
|
+
|
316
|
+
def struct_fields; FIELDS; end
|
317
|
+
|
318
|
+
def validate
|
319
|
+
end
|
320
|
+
|
321
|
+
::Thrift::Struct.generate_accessors self
|
322
|
+
end
|
323
|
+
|
324
|
+
class OptionExercisePositionSnapshot
|
325
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
326
|
+
DATE = 1
|
327
|
+
STOCK = 2
|
328
|
+
SHARES = 3
|
329
|
+
PRICE = 4
|
330
|
+
MATURITY = 5
|
331
|
+
TYPE = 7
|
282
332
|
|
283
333
|
FIELDS = {
|
284
334
|
DATE => {:type => ::Thrift::Types::I64, :name => 'date'},
|
@@ -286,13 +336,13 @@ module Radar
|
|
286
336
|
SHARES => {:type => ::Thrift::Types::I32, :name => 'shares'},
|
287
337
|
PRICE => {:type => ::Thrift::Types::DOUBLE, :name => 'price'},
|
288
338
|
MATURITY => {:type => ::Thrift::Types::I64, :name => 'maturity'},
|
289
|
-
TYPE => {:type => ::Thrift::Types::I32, :name => 'type', :enum_class => ::Radar::Api::
|
339
|
+
TYPE => {:type => ::Thrift::Types::I32, :name => 'type', :enum_class => ::Radar::Api::OptionExerciseType}
|
290
340
|
}
|
291
341
|
|
292
342
|
def struct_fields; FIELDS; end
|
293
343
|
|
294
344
|
def validate
|
295
|
-
unless @type.nil? || ::Radar::Api::
|
345
|
+
unless @type.nil? || ::Radar::Api::OptionExerciseType::VALID_VALUES.include?(@type)
|
296
346
|
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field type!')
|
297
347
|
end
|
298
348
|
end
|
@@ -335,8 +385,16 @@ module Radar
|
|
335
385
|
Transaction.new(:transfer, val)
|
336
386
|
end
|
337
387
|
|
338
|
-
def
|
339
|
-
Transaction.new(:
|
388
|
+
def stock_position_snapshot(val)
|
389
|
+
Transaction.new(:stock_position_snapshot, val)
|
390
|
+
end
|
391
|
+
|
392
|
+
def option_position_snapshot(val)
|
393
|
+
Transaction.new(:option_position_snapshot, val)
|
394
|
+
end
|
395
|
+
|
396
|
+
def option_exercise_position_snapshot(val)
|
397
|
+
Transaction.new(:option_exercise_position_snapshot, val)
|
340
398
|
end
|
341
399
|
end
|
342
400
|
|
@@ -348,7 +406,9 @@ module Radar
|
|
348
406
|
STOCK_OPTION = 6
|
349
407
|
SUBSCRIPTION = 7
|
350
408
|
TRANSFER = 8
|
351
|
-
|
409
|
+
STOCK_POSITION_SNAPSHOT = 9
|
410
|
+
OPTION_POSITION_SNAPSHOT = 10
|
411
|
+
OPTION_EXERCISE_POSITION_SNAPSHOT = 11
|
352
412
|
|
353
413
|
FIELDS = {
|
354
414
|
STOCK_BUY => {:type => ::Thrift::Types::STRUCT, :name => 'stock_buy', :class => ::Radar::Api::StockBuy, :optional => true},
|
@@ -359,7 +419,9 @@ module Radar
|
|
359
419
|
STOCK_OPTION => {:type => ::Thrift::Types::STRUCT, :name => 'stock_option', :class => ::Radar::Api::StockOption, :optional => true},
|
360
420
|
SUBSCRIPTION => {:type => ::Thrift::Types::STRUCT, :name => 'subscription', :class => ::Radar::Api::Subscription, :optional => true},
|
361
421
|
TRANSFER => {:type => ::Thrift::Types::STRUCT, :name => 'transfer', :class => ::Radar::Api::Transfer, :optional => true},
|
362
|
-
|
422
|
+
STOCK_POSITION_SNAPSHOT => {:type => ::Thrift::Types::STRUCT, :name => 'stock_position_snapshot', :class => ::Radar::Api::StockPositionSnapshot, :optional => true},
|
423
|
+
OPTION_POSITION_SNAPSHOT => {:type => ::Thrift::Types::STRUCT, :name => 'option_position_snapshot', :class => ::Radar::Api::OptionPositionSnapshot, :optional => true},
|
424
|
+
OPTION_EXERCISE_POSITION_SNAPSHOT => {:type => ::Thrift::Types::STRUCT, :name => 'option_exercise_position_snapshot', :class => ::Radar::Api::OptionExercisePositionSnapshot, :optional => true}
|
363
425
|
}
|
364
426
|
|
365
427
|
def struct_fields; FIELDS; end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: radar-api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.11.
|
4
|
+
version: 0.11.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- André Aizim Kelmanson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-10-
|
11
|
+
date: 2019-10-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|