line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Finance::GDAX::API::TypeConstraints; |
2
|
|
|
|
|
|
|
our $VERSION = '0.01'; |
3
|
7
|
|
|
7
|
|
118
|
use 5.20.0; |
|
7
|
|
|
|
|
25
|
|
4
|
7
|
|
|
7
|
|
44
|
use warnings; |
|
7
|
|
|
|
|
15
|
|
|
7
|
|
|
|
|
260
|
|
5
|
7
|
|
|
7
|
|
38
|
use Moose; |
|
7
|
|
|
|
|
14
|
|
|
7
|
|
|
|
|
48
|
|
6
|
7
|
|
|
7
|
|
51065
|
use Moose::Util::TypeConstraints; |
|
7
|
|
|
|
|
19
|
|
|
7
|
|
|
|
|
67
|
|
7
|
7
|
|
|
7
|
|
23051
|
use namespace::autoclean; |
|
7
|
|
|
|
|
45604
|
|
|
7
|
|
|
|
|
40
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
subtype 'PositiveInt', |
10
|
|
|
|
|
|
|
as 'Int', |
11
|
|
|
|
|
|
|
where { $_ > 0 }, |
12
|
|
|
|
|
|
|
message { "$_ is not a positive number" }; |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
subtype 'PositiveNum', |
15
|
|
|
|
|
|
|
as 'Num', |
16
|
|
|
|
|
|
|
where { $_ > 0 }, |
17
|
|
|
|
|
|
|
message { "$_ is not a positive number" }; |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
subtype 'PositiveNumOrZero', |
20
|
|
|
|
|
|
|
as 'Num', |
21
|
|
|
|
|
|
|
where { $_ >= 0 }, |
22
|
|
|
|
|
|
|
message { "$_ is not a positive number or zero" }; |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
subtype 'ProductLevel', |
25
|
|
|
|
|
|
|
as 'Int', |
26
|
|
|
|
|
|
|
where { $_ >= 1 and $_ <= 3 }, |
27
|
|
|
|
|
|
|
message { "Product level must be 1, 2 or 3" }; |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
enum 'FundingStatus', [qw(outstanding settled rejected)]; |
30
|
|
|
|
|
|
|
enum 'MarginTransferType', [qw(deposit withdraw)]; |
31
|
|
|
|
|
|
|
enum 'OrderSelfTradePreventionFlag', [qw(dc co cn cb)]; |
32
|
|
|
|
|
|
|
enum 'OrderSide', [qw(buy sell)]; |
33
|
|
|
|
|
|
|
enum 'OrderTimeInForce', [qw(GTC GTT IOC FOK)]; |
34
|
|
|
|
|
|
|
enum 'OrderType', [qw(limit market stop)]; |
35
|
|
|
|
|
|
|
enum 'ReportFormat', [qw(pdf csv)]; |
36
|
|
|
|
|
|
|
enum 'ReportType', [qw(fills account)]; |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable; |
39
|
|
|
|
|
|
|
1; |
40
|
|
|
|
|
|
|
|