expo_notifier 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.ruby-version +1 -0
- data/CHANGELOG.md +3 -0
- data/LICENSE.txt +21 -0
- data/README.md +172 -0
- data/Rakefile +17 -0
- data/lib/expo_notifier/mapper/base.rb +30 -0
- data/lib/expo_notifier/mapper/error.rb +24 -0
- data/lib/expo_notifier/mapper/push_message.rb +132 -0
- data/lib/expo_notifier/mapper/push_messages.rb +15 -0
- data/lib/expo_notifier/mapper/push_receipt.rb +23 -0
- data/lib/expo_notifier/mapper/push_receipt_error_details.rb +23 -0
- data/lib/expo_notifier/mapper/push_receipt_ids.rb +16 -0
- data/lib/expo_notifier/mapper/push_receipts.rb +38 -0
- data/lib/expo_notifier/mapper/push_ticket.rb +30 -0
- data/lib/expo_notifier/mapper/push_ticket_error_details.rb +19 -0
- data/lib/expo_notifier/mapper/push_tickets.rb +26 -0
- data/lib/expo_notifier/mapper/rich_content.rb +17 -0
- data/lib/expo_notifier/request/base.rb +162 -0
- data/lib/expo_notifier/request/get_push_notification_receipts.rb +18 -0
- data/lib/expo_notifier/request/send_push_notifications.rb +26 -0
- data/lib/expo_notifier/response.rb +93 -0
- data/lib/expo_notifier/sorbet_shim.rb +18 -0
- data/lib/expo_notifier/version.rb +6 -0
- data/lib/expo_notifier.rb +19 -0
- data/sorbet/config +6 -0
- data/sorbet/rbi/annotations/.gitattributes +1 -0
- data/sorbet/rbi/annotations/activesupport.rbi +495 -0
- data/sorbet/rbi/annotations/faraday.rbi +17 -0
- data/sorbet/rbi/annotations/minitest.rbi +119 -0
- data/sorbet/rbi/annotations/rainbow.rbi +269 -0
- data/sorbet/rbi/annotations/webmock.rbi +9 -0
- data/sorbet/rbi/dsl/.gitattributes +1 -0
- data/sorbet/rbi/dsl/active_support/callbacks.rbi +21 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/base.rbi +12 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/error.rbi +42 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/push_message.rbi +263 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/push_messages.rbi +29 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/push_receipt.rbi +45 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/push_receipt_error_details.rbi +38 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/push_receipt_ids.rbi +20 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/push_receipts.rbi +25 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/push_ticket.rbi +59 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/push_ticket_error_details.rbi +32 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/push_tickets.rbi +54 -0
- data/sorbet/rbi/dsl/expo_notifier/mapper/rich_content.rbi +26 -0
- data/sorbet/rbi/dsl/time.rbi +13 -0
- data/sorbet/rbi/gems/.gitattributes +1 -0
- data/sorbet/rbi/gems/activesupport@8.1.1.rbi +22456 -0
- data/sorbet/rbi/gems/addressable@2.8.8.rbi +2005 -0
- data/sorbet/rbi/gems/ast@2.4.3.rbi +586 -0
- data/sorbet/rbi/gems/base64@0.3.0.rbi +545 -0
- data/sorbet/rbi/gems/benchmark@0.5.0.rbi +637 -0
- data/sorbet/rbi/gems/bigdecimal@4.0.1.rbi +409 -0
- data/sorbet/rbi/gems/booleans@0.1.3.rbi +31 -0
- data/sorbet/rbi/gems/concurrent-ruby@1.3.6.rbi +11729 -0
- data/sorbet/rbi/gems/connection_pool@3.0.2.rbi +9 -0
- data/sorbet/rbi/gems/crack@1.0.1.rbi +145 -0
- data/sorbet/rbi/gems/date@3.5.1.rbi +403 -0
- data/sorbet/rbi/gems/drb@2.2.3.rbi +1661 -0
- data/sorbet/rbi/gems/erb@6.0.1.rbi +815 -0
- data/sorbet/rbi/gems/erubi@1.13.1.rbi +157 -0
- data/sorbet/rbi/gems/faraday-net_http@3.4.2.rbi +72 -0
- data/sorbet/rbi/gems/faraday@2.14.0.rbi +3301 -0
- data/sorbet/rbi/gems/hashdiff@1.2.1.rbi +355 -0
- data/sorbet/rbi/gems/i18n@1.14.8.rbi +2383 -0
- data/sorbet/rbi/gems/io-console@0.8.2.rbi +9 -0
- data/sorbet/rbi/gems/json@2.18.0.rbi +2278 -0
- data/sorbet/rbi/gems/lint_roller@1.1.0.rbi +323 -0
- data/sorbet/rbi/gems/logger@1.7.0.rbi +963 -0
- data/sorbet/rbi/gems/minitest@6.0.1.rbi +1524 -0
- data/sorbet/rbi/gems/net-http@0.9.1.rbi +4304 -0
- data/sorbet/rbi/gems/netrc@0.11.0.rbi +177 -0
- data/sorbet/rbi/gems/parallel@1.27.0.rbi +291 -0
- data/sorbet/rbi/gems/parser@3.3.10.0.rbi +5537 -0
- data/sorbet/rbi/gems/pp@0.6.3.rbi +390 -0
- data/sorbet/rbi/gems/prettyprint@0.2.0.rbi +477 -0
- data/sorbet/rbi/gems/prism@1.6.0.rbi +42126 -0
- data/sorbet/rbi/gems/psych@5.3.1.rbi +2556 -0
- data/sorbet/rbi/gems/public_suffix@7.0.2.rbi +957 -0
- data/sorbet/rbi/gems/racc@1.8.1.rbi +168 -0
- data/sorbet/rbi/gems/rainbow@3.1.1.rbi +404 -0
- data/sorbet/rbi/gems/rake@13.3.1.rbi +3038 -0
- data/sorbet/rbi/gems/rbi@0.3.8.rbi +5238 -0
- data/sorbet/rbi/gems/rbs@4.0.0.dev.4.rbi +7805 -0
- data/sorbet/rbi/gems/regexp_parser@2.11.3.rbi +3849 -0
- data/sorbet/rbi/gems/reline@0.6.3.rbi +2995 -0
- data/sorbet/rbi/gems/require-hooks@0.2.2.rbi +110 -0
- data/sorbet/rbi/gems/rexml@3.4.4.rbi +5258 -0
- data/sorbet/rbi/gems/rubocop-espago@1.2.0.rbi +9 -0
- data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +1318 -0
- data/sorbet/rbi/gems/securerandom@0.4.1.rbi +75 -0
- data/sorbet/rbi/gems/shale-builder@0.8.5.rbi +267 -0
- data/sorbet/rbi/gems/shale@1.2.2.rbi +2323 -0
- data/sorbet/rbi/gems/shoulda-context@2.0.0.rbi +563 -0
- data/sorbet/rbi/gems/spoom@1.7.11.rbi +5878 -0
- data/sorbet/rbi/gems/stringio@3.2.0.rbi +9 -0
- data/sorbet/rbi/gems/tapioca@0.17.4.rbi +3507 -0
- data/sorbet/rbi/gems/thor@1.4.0.rbi +4399 -0
- data/sorbet/rbi/gems/tsort@0.2.0.rbi +393 -0
- data/sorbet/rbi/gems/tzinfo@2.0.6.rbi +5919 -0
- data/sorbet/rbi/gems/unicode-display_width@3.2.0.rbi +132 -0
- data/sorbet/rbi/gems/unicode-emoji@4.2.0.rbi +254 -0
- data/sorbet/rbi/gems/uri@1.1.1.rbi +2407 -0
- data/sorbet/rbi/gems/vcr@6.4.0.rbi +3055 -0
- data/sorbet/rbi/gems/webmock@3.26.1.rbi +1816 -0
- data/sorbet/rbi/shims/gems/set.rbi +2 -0
- data/sorbet/rbi/shims/gems/shale.rbi +27 -0
- data/sorbet/rbi/shims/gems/shoulda-context.rbi +20 -0
- data/sorbet/tapioca/config.yml +21 -0
- data/sorbet/tapioca/extensions/load_gem.rb +1 -0
- data/sorbet/tapioca/require.rb +15 -0
- metadata +228 -0
|
@@ -0,0 +1,409 @@
|
|
|
1
|
+
# typed: false
|
|
2
|
+
|
|
3
|
+
# DO NOT EDIT MANUALLY
|
|
4
|
+
# This is an autogenerated file for types exported from the `bigdecimal` gem.
|
|
5
|
+
# Please instead update this file by running `bin/tapioca gem bigdecimal`.
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# source://bigdecimal//lib/bigdecimal.rb#13
|
|
9
|
+
class BigDecimal < ::Numeric
|
|
10
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
11
|
+
def %(_arg0); end
|
|
12
|
+
|
|
13
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
14
|
+
def *(_arg0); end
|
|
15
|
+
|
|
16
|
+
# call-seq:
|
|
17
|
+
# self ** other -> bigdecimal
|
|
18
|
+
#
|
|
19
|
+
# Returns the \BigDecimal value of +self+ raised to power +other+:
|
|
20
|
+
#
|
|
21
|
+
# b = BigDecimal('3.14')
|
|
22
|
+
# b ** 2 # => 0.98596e1
|
|
23
|
+
# b ** 2.0 # => 0.98596e1
|
|
24
|
+
# b ** Rational(2, 1) # => 0.98596e1
|
|
25
|
+
#
|
|
26
|
+
# Related: BigDecimal#power.
|
|
27
|
+
#
|
|
28
|
+
# source://bigdecimal//lib/bigdecimal.rb#77
|
|
29
|
+
def **(y); end
|
|
30
|
+
|
|
31
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
32
|
+
def +(_arg0); end
|
|
33
|
+
|
|
34
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
35
|
+
def +@; end
|
|
36
|
+
|
|
37
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
38
|
+
def -(_arg0); end
|
|
39
|
+
|
|
40
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
41
|
+
def -@; end
|
|
42
|
+
|
|
43
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
44
|
+
def /(_arg0); end
|
|
45
|
+
|
|
46
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
47
|
+
def <(_arg0); end
|
|
48
|
+
|
|
49
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
50
|
+
def <=(_arg0); end
|
|
51
|
+
|
|
52
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
53
|
+
def <=>(_arg0); end
|
|
54
|
+
|
|
55
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
56
|
+
def ==(_arg0); end
|
|
57
|
+
|
|
58
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
59
|
+
def ===(_arg0); end
|
|
60
|
+
|
|
61
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
62
|
+
def >(_arg0); end
|
|
63
|
+
|
|
64
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
65
|
+
def >=(_arg0); end
|
|
66
|
+
|
|
67
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
68
|
+
def _decimal_shift(_arg0); end
|
|
69
|
+
|
|
70
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
71
|
+
def _dump(*_arg0); end
|
|
72
|
+
|
|
73
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
74
|
+
def abs; end
|
|
75
|
+
|
|
76
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
77
|
+
def add(_arg0, _arg1); end
|
|
78
|
+
|
|
79
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
80
|
+
def ceil(*_arg0); end
|
|
81
|
+
|
|
82
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
83
|
+
def clone; end
|
|
84
|
+
|
|
85
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
86
|
+
def coerce(_arg0); end
|
|
87
|
+
|
|
88
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
89
|
+
def div(*_arg0); end
|
|
90
|
+
|
|
91
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
92
|
+
def divmod(_arg0); end
|
|
93
|
+
|
|
94
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
95
|
+
def dup; end
|
|
96
|
+
|
|
97
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
98
|
+
def eql?(_arg0); end
|
|
99
|
+
|
|
100
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
101
|
+
def exponent; end
|
|
102
|
+
|
|
103
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
104
|
+
def finite?; end
|
|
105
|
+
|
|
106
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
107
|
+
def fix; end
|
|
108
|
+
|
|
109
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
110
|
+
def floor(*_arg0); end
|
|
111
|
+
|
|
112
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
113
|
+
def frac; end
|
|
114
|
+
|
|
115
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
116
|
+
def hash; end
|
|
117
|
+
|
|
118
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
119
|
+
def infinite?; end
|
|
120
|
+
|
|
121
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
122
|
+
def inspect; end
|
|
123
|
+
|
|
124
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
125
|
+
def modulo(_arg0); end
|
|
126
|
+
|
|
127
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
128
|
+
def mult(_arg0, _arg1); end
|
|
129
|
+
|
|
130
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
131
|
+
def n_significant_digits; end
|
|
132
|
+
|
|
133
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
134
|
+
def nan?; end
|
|
135
|
+
|
|
136
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
137
|
+
def nonzero?; end
|
|
138
|
+
|
|
139
|
+
# call-seq:
|
|
140
|
+
# power(n)
|
|
141
|
+
# power(n, prec)
|
|
142
|
+
#
|
|
143
|
+
# Returns the value raised to the power of n.
|
|
144
|
+
#
|
|
145
|
+
# Also available as the operator **.
|
|
146
|
+
#
|
|
147
|
+
# source://bigdecimal//lib/bigdecimal.rb#97
|
|
148
|
+
def power(y, prec = T.unsafe(nil)); end
|
|
149
|
+
|
|
150
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
151
|
+
def precision; end
|
|
152
|
+
|
|
153
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
154
|
+
def precision_scale; end
|
|
155
|
+
|
|
156
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
157
|
+
def quo(*_arg0); end
|
|
158
|
+
|
|
159
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
160
|
+
def remainder(_arg0); end
|
|
161
|
+
|
|
162
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
163
|
+
def round(*_arg0); end
|
|
164
|
+
|
|
165
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
166
|
+
def scale; end
|
|
167
|
+
|
|
168
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
169
|
+
def sign; end
|
|
170
|
+
|
|
171
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
172
|
+
def split; end
|
|
173
|
+
|
|
174
|
+
# Returns the square root of the value.
|
|
175
|
+
#
|
|
176
|
+
# Result has at least prec significant digits.
|
|
177
|
+
#
|
|
178
|
+
# @raise [FloatDomainError]
|
|
179
|
+
#
|
|
180
|
+
# source://bigdecimal//lib/bigdecimal.rb#212
|
|
181
|
+
def sqrt(prec); end
|
|
182
|
+
|
|
183
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
184
|
+
def sub(_arg0, _arg1); end
|
|
185
|
+
|
|
186
|
+
# call-seq:
|
|
187
|
+
# a.to_d -> bigdecimal
|
|
188
|
+
#
|
|
189
|
+
# Returns self.
|
|
190
|
+
#
|
|
191
|
+
# require 'bigdecimal/util'
|
|
192
|
+
#
|
|
193
|
+
# d = BigDecimal("3.14")
|
|
194
|
+
# d.to_d # => 0.314e1
|
|
195
|
+
#
|
|
196
|
+
# source://bigdecimal//lib/bigdecimal/util.rb#110
|
|
197
|
+
def to_d; end
|
|
198
|
+
|
|
199
|
+
# call-seq:
|
|
200
|
+
# a.to_digits -> string
|
|
201
|
+
#
|
|
202
|
+
# Converts a BigDecimal to a String of the form "nnnnnn.mmm".
|
|
203
|
+
# This method is deprecated; use BigDecimal#to_s("F") instead.
|
|
204
|
+
#
|
|
205
|
+
# require 'bigdecimal/util'
|
|
206
|
+
#
|
|
207
|
+
# d = BigDecimal("3.14")
|
|
208
|
+
# d.to_digits # => "3.14"
|
|
209
|
+
#
|
|
210
|
+
# source://bigdecimal//lib/bigdecimal/util.rb#90
|
|
211
|
+
def to_digits; end
|
|
212
|
+
|
|
213
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
214
|
+
def to_f; end
|
|
215
|
+
|
|
216
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
217
|
+
def to_i; end
|
|
218
|
+
|
|
219
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
220
|
+
def to_int; end
|
|
221
|
+
|
|
222
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
223
|
+
def to_r; end
|
|
224
|
+
|
|
225
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
226
|
+
def to_s(format = T.unsafe(nil)); end
|
|
227
|
+
|
|
228
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
229
|
+
def truncate(*_arg0); end
|
|
230
|
+
|
|
231
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
232
|
+
def zero?; end
|
|
233
|
+
|
|
234
|
+
class << self
|
|
235
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
236
|
+
def _load(_arg0); end
|
|
237
|
+
|
|
238
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
239
|
+
def double_fig; end
|
|
240
|
+
|
|
241
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
242
|
+
def interpret_loosely(_arg0); end
|
|
243
|
+
|
|
244
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
245
|
+
def limit(*_arg0); end
|
|
246
|
+
|
|
247
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
248
|
+
def mode(*_arg0); end
|
|
249
|
+
|
|
250
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
251
|
+
def save_exception_mode; end
|
|
252
|
+
|
|
253
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
254
|
+
def save_limit; end
|
|
255
|
+
|
|
256
|
+
# source://bigdecimal//lib/bigdecimal.rb#10
|
|
257
|
+
def save_rounding_mode; end
|
|
258
|
+
end
|
|
259
|
+
end
|
|
260
|
+
|
|
261
|
+
# source://bigdecimal//lib/bigdecimal.rb#14
|
|
262
|
+
module BigDecimal::Internal
|
|
263
|
+
class << self
|
|
264
|
+
# Coerce x to BigDecimal with the specified precision.
|
|
265
|
+
# TODO: some methods (example: BigMath.exp) require more precision than specified to coerce.
|
|
266
|
+
#
|
|
267
|
+
# @raise [ArgumentError]
|
|
268
|
+
#
|
|
269
|
+
# source://bigdecimal//lib/bigdecimal.rb#18
|
|
270
|
+
def coerce_to_bigdecimal(x, prec, method_name); end
|
|
271
|
+
|
|
272
|
+
# source://bigdecimal//lib/bigdecimal.rb#30
|
|
273
|
+
def coerce_validate_prec(prec, method_name, accept_zero: T.unsafe(nil)); end
|
|
274
|
+
|
|
275
|
+
# source://bigdecimal//lib/bigdecimal.rb#50
|
|
276
|
+
def infinity_computation_result; end
|
|
277
|
+
|
|
278
|
+
# source://bigdecimal//lib/bigdecimal.rb#57
|
|
279
|
+
def nan_computation_result; end
|
|
280
|
+
end
|
|
281
|
+
end
|
|
282
|
+
|
|
283
|
+
# Core BigMath methods for BigDecimal (log, exp) are defined here.
|
|
284
|
+
# Other methods (sin, cos, atan) are defined in 'bigdecimal/math.rb'.
|
|
285
|
+
#
|
|
286
|
+
# source://bigdecimal//lib/bigdecimal.rb#240
|
|
287
|
+
module BigMath
|
|
288
|
+
private
|
|
289
|
+
|
|
290
|
+
# source://bigdecimal//lib/bigdecimal.rb#310
|
|
291
|
+
def _exp_taylor(x, prec); end
|
|
292
|
+
|
|
293
|
+
# call-seq:
|
|
294
|
+
# BigMath.exp(decimal, numeric) -> BigDecimal
|
|
295
|
+
#
|
|
296
|
+
# Computes the value of e (the base of natural logarithms) raised to the
|
|
297
|
+
# power of +decimal+, to the specified number of digits of precision.
|
|
298
|
+
#
|
|
299
|
+
# If +decimal+ is infinity, returns Infinity.
|
|
300
|
+
#
|
|
301
|
+
# If +decimal+ is NaN, returns NaN.
|
|
302
|
+
#
|
|
303
|
+
# source://bigdecimal//lib/bigdecimal.rb#332
|
|
304
|
+
def exp(x, prec); end
|
|
305
|
+
|
|
306
|
+
# call-seq:
|
|
307
|
+
# BigMath.log(decimal, numeric) -> BigDecimal
|
|
308
|
+
#
|
|
309
|
+
# Computes the natural logarithm of +decimal+ to the specified number of
|
|
310
|
+
# digits of precision, +numeric+.
|
|
311
|
+
#
|
|
312
|
+
# If +decimal+ is zero or negative, raises Math::DomainError.
|
|
313
|
+
#
|
|
314
|
+
# If +decimal+ is positive infinity, returns Infinity.
|
|
315
|
+
#
|
|
316
|
+
# If +decimal+ is NaN, returns NaN.
|
|
317
|
+
#
|
|
318
|
+
# source://bigdecimal//lib/bigdecimal.rb#255
|
|
319
|
+
def log(x, prec); end
|
|
320
|
+
|
|
321
|
+
class << self
|
|
322
|
+
# call-seq:
|
|
323
|
+
# BigMath.exp(decimal, numeric) -> BigDecimal
|
|
324
|
+
#
|
|
325
|
+
# Computes the value of e (the base of natural logarithms) raised to the
|
|
326
|
+
# power of +decimal+, to the specified number of digits of precision.
|
|
327
|
+
#
|
|
328
|
+
# If +decimal+ is infinity, returns Infinity.
|
|
329
|
+
#
|
|
330
|
+
# If +decimal+ is NaN, returns NaN.
|
|
331
|
+
#
|
|
332
|
+
# source://bigdecimal//lib/bigdecimal.rb#332
|
|
333
|
+
def exp(x, prec); end
|
|
334
|
+
|
|
335
|
+
# call-seq:
|
|
336
|
+
# BigMath.log(decimal, numeric) -> BigDecimal
|
|
337
|
+
#
|
|
338
|
+
# Computes the natural logarithm of +decimal+ to the specified number of
|
|
339
|
+
# digits of precision, +numeric+.
|
|
340
|
+
#
|
|
341
|
+
# If +decimal+ is zero or negative, raises Math::DomainError.
|
|
342
|
+
#
|
|
343
|
+
# If +decimal+ is positive infinity, returns Infinity.
|
|
344
|
+
#
|
|
345
|
+
# If +decimal+ is NaN, returns NaN.
|
|
346
|
+
#
|
|
347
|
+
# @raise [Math::DomainError]
|
|
348
|
+
#
|
|
349
|
+
# source://bigdecimal//lib/bigdecimal.rb#255
|
|
350
|
+
def log(x, prec); end
|
|
351
|
+
|
|
352
|
+
private
|
|
353
|
+
|
|
354
|
+
# source://bigdecimal//lib/bigdecimal.rb#310
|
|
355
|
+
def _exp_taylor(x, prec); end
|
|
356
|
+
end
|
|
357
|
+
end
|
|
358
|
+
|
|
359
|
+
# source://bigdecimal//lib/bigdecimal/util.rb#141
|
|
360
|
+
class Complex < ::Numeric
|
|
361
|
+
# call-seq:
|
|
362
|
+
# cmp.to_d -> bigdecimal
|
|
363
|
+
# cmp.to_d(precision) -> bigdecimal
|
|
364
|
+
#
|
|
365
|
+
# Returns the value as a BigDecimal.
|
|
366
|
+
# If the imaginary part is not +0+, an error is raised
|
|
367
|
+
#
|
|
368
|
+
# The +precision+ parameter is used to determine the number of
|
|
369
|
+
# significant digits for the result. When +precision+ is set to +0+,
|
|
370
|
+
# the number of digits to represent the float being converted is determined
|
|
371
|
+
# automatically.
|
|
372
|
+
# The default +precision+ is +0+.
|
|
373
|
+
#
|
|
374
|
+
# require 'bigdecimal'
|
|
375
|
+
# require 'bigdecimal/util'
|
|
376
|
+
#
|
|
377
|
+
# Complex(0.1234567, 0).to_d(4) # => 0.1235e0
|
|
378
|
+
# Complex(Rational(22, 7), 0).to_d(3) # => 0.314e1
|
|
379
|
+
# Complex(1, 1).to_d # raises ArgumentError
|
|
380
|
+
#
|
|
381
|
+
# See also Kernel.BigDecimal.
|
|
382
|
+
#
|
|
383
|
+
# source://bigdecimal//lib/bigdecimal/util.rb#164
|
|
384
|
+
def to_d(precision = T.unsafe(nil)); end
|
|
385
|
+
end
|
|
386
|
+
|
|
387
|
+
# source://bigdecimal//lib/bigdecimal/util.rb#116
|
|
388
|
+
class Rational < ::Numeric
|
|
389
|
+
# call-seq:
|
|
390
|
+
# rat.to_d(precision) -> bigdecimal
|
|
391
|
+
#
|
|
392
|
+
# Returns the value as a BigDecimal.
|
|
393
|
+
#
|
|
394
|
+
# The +precision+ parameter is used to determine the number of
|
|
395
|
+
# significant digits for the result. When +precision+ is set to +0+,
|
|
396
|
+
# the number of digits to represent the float being converted is determined
|
|
397
|
+
# automatically.
|
|
398
|
+
# The default +precision+ is +0+.
|
|
399
|
+
#
|
|
400
|
+
# require 'bigdecimal'
|
|
401
|
+
# require 'bigdecimal/util'
|
|
402
|
+
#
|
|
403
|
+
# Rational(22, 7).to_d(3) # => 0.314e1
|
|
404
|
+
#
|
|
405
|
+
# See also Kernel.BigDecimal.
|
|
406
|
+
#
|
|
407
|
+
# source://bigdecimal//lib/bigdecimal/util.rb#135
|
|
408
|
+
def to_d(precision = T.unsafe(nil)); end
|
|
409
|
+
end
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
|
|
3
|
+
# DO NOT EDIT MANUALLY
|
|
4
|
+
# This is an autogenerated file for types exported from the `booleans` gem.
|
|
5
|
+
# Please instead update this file by running `bin/tapioca gem booleans`.
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# source://booleans//lib/booleans/version.rb#3
|
|
9
|
+
module Booleans; end
|
|
10
|
+
|
|
11
|
+
# Add the Boolean method to Kernel
|
|
12
|
+
#
|
|
13
|
+
# source://booleans//lib/booleans/kernel_extension.rb#6
|
|
14
|
+
module Booleans::KernelExtension
|
|
15
|
+
# Convert a Ruby value to `true` or `false`
|
|
16
|
+
# according to the truthiness of the value.
|
|
17
|
+
#
|
|
18
|
+
# Most Ruby objects get converted to `true` with the
|
|
19
|
+
# exception of: `nil` and `false`.
|
|
20
|
+
#
|
|
21
|
+
# source://booleans//lib/booleans/kernel_extension.rb#15
|
|
22
|
+
sig { params(val: T.anything).returns(T::Boolean) }
|
|
23
|
+
def Boolean(val); end
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
# source://booleans//lib/booleans/version.rb#4
|
|
27
|
+
Booleans::VERSION = T.let(T.unsafe(nil), String)
|
|
28
|
+
|
|
29
|
+
module Kernel
|
|
30
|
+
include ::Booleans::KernelExtension
|
|
31
|
+
end
|