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.
Files changed (113) hide show
  1. checksums.yaml +7 -0
  2. data/.ruby-version +1 -0
  3. data/CHANGELOG.md +3 -0
  4. data/LICENSE.txt +21 -0
  5. data/README.md +172 -0
  6. data/Rakefile +17 -0
  7. data/lib/expo_notifier/mapper/base.rb +30 -0
  8. data/lib/expo_notifier/mapper/error.rb +24 -0
  9. data/lib/expo_notifier/mapper/push_message.rb +132 -0
  10. data/lib/expo_notifier/mapper/push_messages.rb +15 -0
  11. data/lib/expo_notifier/mapper/push_receipt.rb +23 -0
  12. data/lib/expo_notifier/mapper/push_receipt_error_details.rb +23 -0
  13. data/lib/expo_notifier/mapper/push_receipt_ids.rb +16 -0
  14. data/lib/expo_notifier/mapper/push_receipts.rb +38 -0
  15. data/lib/expo_notifier/mapper/push_ticket.rb +30 -0
  16. data/lib/expo_notifier/mapper/push_ticket_error_details.rb +19 -0
  17. data/lib/expo_notifier/mapper/push_tickets.rb +26 -0
  18. data/lib/expo_notifier/mapper/rich_content.rb +17 -0
  19. data/lib/expo_notifier/request/base.rb +162 -0
  20. data/lib/expo_notifier/request/get_push_notification_receipts.rb +18 -0
  21. data/lib/expo_notifier/request/send_push_notifications.rb +26 -0
  22. data/lib/expo_notifier/response.rb +93 -0
  23. data/lib/expo_notifier/sorbet_shim.rb +18 -0
  24. data/lib/expo_notifier/version.rb +6 -0
  25. data/lib/expo_notifier.rb +19 -0
  26. data/sorbet/config +6 -0
  27. data/sorbet/rbi/annotations/.gitattributes +1 -0
  28. data/sorbet/rbi/annotations/activesupport.rbi +495 -0
  29. data/sorbet/rbi/annotations/faraday.rbi +17 -0
  30. data/sorbet/rbi/annotations/minitest.rbi +119 -0
  31. data/sorbet/rbi/annotations/rainbow.rbi +269 -0
  32. data/sorbet/rbi/annotations/webmock.rbi +9 -0
  33. data/sorbet/rbi/dsl/.gitattributes +1 -0
  34. data/sorbet/rbi/dsl/active_support/callbacks.rbi +21 -0
  35. data/sorbet/rbi/dsl/expo_notifier/mapper/base.rbi +12 -0
  36. data/sorbet/rbi/dsl/expo_notifier/mapper/error.rbi +42 -0
  37. data/sorbet/rbi/dsl/expo_notifier/mapper/push_message.rbi +263 -0
  38. data/sorbet/rbi/dsl/expo_notifier/mapper/push_messages.rbi +29 -0
  39. data/sorbet/rbi/dsl/expo_notifier/mapper/push_receipt.rbi +45 -0
  40. data/sorbet/rbi/dsl/expo_notifier/mapper/push_receipt_error_details.rbi +38 -0
  41. data/sorbet/rbi/dsl/expo_notifier/mapper/push_receipt_ids.rbi +20 -0
  42. data/sorbet/rbi/dsl/expo_notifier/mapper/push_receipts.rbi +25 -0
  43. data/sorbet/rbi/dsl/expo_notifier/mapper/push_ticket.rbi +59 -0
  44. data/sorbet/rbi/dsl/expo_notifier/mapper/push_ticket_error_details.rbi +32 -0
  45. data/sorbet/rbi/dsl/expo_notifier/mapper/push_tickets.rbi +54 -0
  46. data/sorbet/rbi/dsl/expo_notifier/mapper/rich_content.rbi +26 -0
  47. data/sorbet/rbi/dsl/time.rbi +13 -0
  48. data/sorbet/rbi/gems/.gitattributes +1 -0
  49. data/sorbet/rbi/gems/activesupport@8.1.1.rbi +22456 -0
  50. data/sorbet/rbi/gems/addressable@2.8.8.rbi +2005 -0
  51. data/sorbet/rbi/gems/ast@2.4.3.rbi +586 -0
  52. data/sorbet/rbi/gems/base64@0.3.0.rbi +545 -0
  53. data/sorbet/rbi/gems/benchmark@0.5.0.rbi +637 -0
  54. data/sorbet/rbi/gems/bigdecimal@4.0.1.rbi +409 -0
  55. data/sorbet/rbi/gems/booleans@0.1.3.rbi +31 -0
  56. data/sorbet/rbi/gems/concurrent-ruby@1.3.6.rbi +11729 -0
  57. data/sorbet/rbi/gems/connection_pool@3.0.2.rbi +9 -0
  58. data/sorbet/rbi/gems/crack@1.0.1.rbi +145 -0
  59. data/sorbet/rbi/gems/date@3.5.1.rbi +403 -0
  60. data/sorbet/rbi/gems/drb@2.2.3.rbi +1661 -0
  61. data/sorbet/rbi/gems/erb@6.0.1.rbi +815 -0
  62. data/sorbet/rbi/gems/erubi@1.13.1.rbi +157 -0
  63. data/sorbet/rbi/gems/faraday-net_http@3.4.2.rbi +72 -0
  64. data/sorbet/rbi/gems/faraday@2.14.0.rbi +3301 -0
  65. data/sorbet/rbi/gems/hashdiff@1.2.1.rbi +355 -0
  66. data/sorbet/rbi/gems/i18n@1.14.8.rbi +2383 -0
  67. data/sorbet/rbi/gems/io-console@0.8.2.rbi +9 -0
  68. data/sorbet/rbi/gems/json@2.18.0.rbi +2278 -0
  69. data/sorbet/rbi/gems/lint_roller@1.1.0.rbi +323 -0
  70. data/sorbet/rbi/gems/logger@1.7.0.rbi +963 -0
  71. data/sorbet/rbi/gems/minitest@6.0.1.rbi +1524 -0
  72. data/sorbet/rbi/gems/net-http@0.9.1.rbi +4304 -0
  73. data/sorbet/rbi/gems/netrc@0.11.0.rbi +177 -0
  74. data/sorbet/rbi/gems/parallel@1.27.0.rbi +291 -0
  75. data/sorbet/rbi/gems/parser@3.3.10.0.rbi +5537 -0
  76. data/sorbet/rbi/gems/pp@0.6.3.rbi +390 -0
  77. data/sorbet/rbi/gems/prettyprint@0.2.0.rbi +477 -0
  78. data/sorbet/rbi/gems/prism@1.6.0.rbi +42126 -0
  79. data/sorbet/rbi/gems/psych@5.3.1.rbi +2556 -0
  80. data/sorbet/rbi/gems/public_suffix@7.0.2.rbi +957 -0
  81. data/sorbet/rbi/gems/racc@1.8.1.rbi +168 -0
  82. data/sorbet/rbi/gems/rainbow@3.1.1.rbi +404 -0
  83. data/sorbet/rbi/gems/rake@13.3.1.rbi +3038 -0
  84. data/sorbet/rbi/gems/rbi@0.3.8.rbi +5238 -0
  85. data/sorbet/rbi/gems/rbs@4.0.0.dev.4.rbi +7805 -0
  86. data/sorbet/rbi/gems/regexp_parser@2.11.3.rbi +3849 -0
  87. data/sorbet/rbi/gems/reline@0.6.3.rbi +2995 -0
  88. data/sorbet/rbi/gems/require-hooks@0.2.2.rbi +110 -0
  89. data/sorbet/rbi/gems/rexml@3.4.4.rbi +5258 -0
  90. data/sorbet/rbi/gems/rubocop-espago@1.2.0.rbi +9 -0
  91. data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +1318 -0
  92. data/sorbet/rbi/gems/securerandom@0.4.1.rbi +75 -0
  93. data/sorbet/rbi/gems/shale-builder@0.8.5.rbi +267 -0
  94. data/sorbet/rbi/gems/shale@1.2.2.rbi +2323 -0
  95. data/sorbet/rbi/gems/shoulda-context@2.0.0.rbi +563 -0
  96. data/sorbet/rbi/gems/spoom@1.7.11.rbi +5878 -0
  97. data/sorbet/rbi/gems/stringio@3.2.0.rbi +9 -0
  98. data/sorbet/rbi/gems/tapioca@0.17.4.rbi +3507 -0
  99. data/sorbet/rbi/gems/thor@1.4.0.rbi +4399 -0
  100. data/sorbet/rbi/gems/tsort@0.2.0.rbi +393 -0
  101. data/sorbet/rbi/gems/tzinfo@2.0.6.rbi +5919 -0
  102. data/sorbet/rbi/gems/unicode-display_width@3.2.0.rbi +132 -0
  103. data/sorbet/rbi/gems/unicode-emoji@4.2.0.rbi +254 -0
  104. data/sorbet/rbi/gems/uri@1.1.1.rbi +2407 -0
  105. data/sorbet/rbi/gems/vcr@6.4.0.rbi +3055 -0
  106. data/sorbet/rbi/gems/webmock@3.26.1.rbi +1816 -0
  107. data/sorbet/rbi/shims/gems/set.rbi +2 -0
  108. data/sorbet/rbi/shims/gems/shale.rbi +27 -0
  109. data/sorbet/rbi/shims/gems/shoulda-context.rbi +20 -0
  110. data/sorbet/tapioca/config.yml +21 -0
  111. data/sorbet/tapioca/extensions/load_gem.rb +1 -0
  112. data/sorbet/tapioca/require.rb +15 -0
  113. metadata +228 -0
@@ -0,0 +1,390 @@
1
+ # typed: false
2
+
3
+ # DO NOT EDIT MANUALLY
4
+ # This is an autogenerated file for types exported from the `pp` gem.
5
+ # Please instead update this file by running `bin/tapioca gem pp`.
6
+
7
+
8
+ class Array
9
+ include ::Enumerable
10
+
11
+ # source://pp//lib/pp.rb#412
12
+ def pretty_print(q); end
13
+
14
+ # source://pp//lib/pp.rb#420
15
+ def pretty_print_cycle(q); end
16
+ end
17
+
18
+ class Data
19
+ # source://pp//lib/pp.rb#495
20
+ def pretty_print(q); end
21
+
22
+ # source://pp//lib/pp.rb#523
23
+ def pretty_print_cycle(q); end
24
+ end
25
+
26
+ class File::Stat
27
+ include ::Comparable
28
+
29
+ # source://pp//lib/pp.rb#557
30
+ def pretty_print(q); end
31
+ end
32
+
33
+ class Hash
34
+ include ::Enumerable
35
+
36
+ # source://pp//lib/pp.rb#426
37
+ def pretty_print(q); end
38
+
39
+ # source://pp//lib/pp.rb#430
40
+ def pretty_print_cycle(q); end
41
+ end
42
+
43
+ module Kernel
44
+ include ::Booleans::KernelExtension
45
+
46
+ # Returns a pretty printed object as a string.
47
+ #
48
+ # See the PP module for more information.
49
+ #
50
+ # source://pp//lib/pp.rb#724
51
+ def pretty_inspect; end
52
+
53
+ private
54
+
55
+ # prints arguments in pretty form.
56
+ #
57
+ # +#pp+ returns argument(s).
58
+ #
59
+ # source://pp//lib/pp.rb#731
60
+ def pp(*objs); end
61
+
62
+ class << self
63
+ # prints arguments in pretty form.
64
+ #
65
+ # +#pp+ returns argument(s).
66
+ #
67
+ # source://pp//lib/pp.rb#731
68
+ def pp(*objs); end
69
+ end
70
+ end
71
+
72
+ class MatchData
73
+ # source://pp//lib/pp.rb#640
74
+ def pretty_print(q); end
75
+ end
76
+
77
+ # A pretty-printer for Ruby objects.
78
+ #
79
+ #
80
+ # == What PP Does
81
+ #
82
+ # Standard output by #p returns this:
83
+ # #<PP:0x81fedf0 @genspace=#<Proc:0x81feda0>, @group_queue=#<PrettyPrint::GroupQueue:0x81fed3c @queue=[[#<PrettyPrint::Group:0x81fed78 @breakables=[], @depth=0, @break=false>], []]>, @buffer=[], @newline="\n", @group_stack=[#<PrettyPrint::Group:0x81fed78 @breakables=[], @depth=0, @break=false>], @buffer_width=0, @indent=0, @maxwidth=79, @output_width=2, @output=#<IO:0x8114ee4>>
84
+ #
85
+ # Pretty-printed output returns this:
86
+ # #<PP:0x81fedf0
87
+ # @buffer=[],
88
+ # @buffer_width=0,
89
+ # @genspace=#<Proc:0x81feda0>,
90
+ # @group_queue=
91
+ # #<PrettyPrint::GroupQueue:0x81fed3c
92
+ # @queue=
93
+ # [[#<PrettyPrint::Group:0x81fed78 @break=false, @breakables=[], @depth=0>],
94
+ # []]>,
95
+ # @group_stack=
96
+ # [#<PrettyPrint::Group:0x81fed78 @break=false, @breakables=[], @depth=0>],
97
+ # @indent=0,
98
+ # @maxwidth=79,
99
+ # @newline="\n",
100
+ # @output=#<IO:0x8114ee4>,
101
+ # @output_width=2>
102
+ #
103
+ #
104
+ # == Usage
105
+ #
106
+ # pp(obj) #=> obj
107
+ # pp obj #=> obj
108
+ # pp(obj1, obj2, ...) #=> [obj1, obj2, ...]
109
+ # pp() #=> nil
110
+ #
111
+ # Output <tt>obj(s)</tt> to <tt>$></tt> in pretty printed format.
112
+ #
113
+ # It returns <tt>obj(s)</tt>.
114
+ #
115
+ #
116
+ # == Output Customization
117
+ #
118
+ # To define a customized pretty printing function for your classes,
119
+ # redefine method <code>#pretty_print(pp)</code> in the class.
120
+ # Note that <code>require 'pp'</code> is needed before redefining <code>#pretty_print(pp)</code>.
121
+ #
122
+ # <code>#pretty_print</code> takes the +pp+ argument, which is an instance of the PP class.
123
+ # The method uses #text, #breakable, #nest, #group and #pp to print the
124
+ # object.
125
+ #
126
+ #
127
+ # == Pretty-Print JSON
128
+ #
129
+ # To pretty-print JSON refer to JSON#pretty_generate.
130
+ #
131
+ #
132
+ # == Author
133
+ # Tanaka Akira <akr@fsij.org>
134
+ class PP < ::PrettyPrint
135
+ include ::PP::PPMethods
136
+
137
+ class << self
138
+ # :stopdoc:
139
+ #
140
+ # source://pp//lib/pp.rb#116
141
+ def mcall(obj, mod, meth, *args, &block); end
142
+
143
+ # Outputs +obj+ to +out+ in pretty printed format of
144
+ # +width+ columns in width.
145
+ #
146
+ # If +out+ is omitted, <code>$></code> is assumed.
147
+ # If +width+ is omitted, the width of +out+ is assumed (see
148
+ # width_for).
149
+ #
150
+ # PP.pp returns +out+.
151
+ #
152
+ # source://pp//lib/pp.rb#96
153
+ def pp(obj, out = T.unsafe(nil), width = T.unsafe(nil)); end
154
+
155
+ # Returns the sharing detection flag as a boolean value.
156
+ # It is false by default.
157
+ #
158
+ # source://pp//lib/pp.rb#125
159
+ def sharing_detection; end
160
+
161
+ # Returns the sharing detection flag as a boolean value.
162
+ # It is false by default.
163
+ #
164
+ # source://pp//lib/pp.rb#129
165
+ def sharing_detection=(b); end
166
+
167
+ # Outputs +obj+ to +out+ like PP.pp but with no indent and
168
+ # newline.
169
+ #
170
+ # PP.singleline_pp returns +out+.
171
+ #
172
+ # source://pp//lib/pp.rb#108
173
+ def singleline_pp(obj, out = T.unsafe(nil)); end
174
+
175
+ # Returns the usable width for +out+.
176
+ # As the width of +out+:
177
+ # 1. If +out+ is assigned to a tty device, its width is used.
178
+ # 2. Otherwise, or it could not get the value, the +COLUMN+
179
+ # environment variable is assumed to be set to the width.
180
+ # 3. If +COLUMN+ is not set to a non-zero number, 80 is assumed.
181
+ #
182
+ # And finally, returns the above width value - 1.
183
+ # * This -1 is for Windows command prompt, which moves the cursor to
184
+ # the next line if it reaches the last column.
185
+ #
186
+ # source://pp//lib/pp.rb#79
187
+ def width_for(out); end
188
+ end
189
+ end
190
+
191
+ module PP::ObjectMixin
192
+ # A default pretty printing method for general objects.
193
+ # It calls #pretty_print_instance_variables to list instance variables.
194
+ #
195
+ # If +self+ has a customized (redefined) #inspect method,
196
+ # the result of self.inspect is used but it obviously has no
197
+ # line break hints.
198
+ #
199
+ # This module provides predefined #pretty_print methods for some of
200
+ # the most commonly used built-in classes for convenience.
201
+ #
202
+ # source://pp//lib/pp.rb#362
203
+ def pretty_print(q); end
204
+
205
+ # A default pretty printing method for general objects that are
206
+ # detected as part of a cycle.
207
+ #
208
+ # source://pp//lib/pp.rb#379
209
+ def pretty_print_cycle(q); end
210
+
211
+ # Is #inspect implementation using #pretty_print.
212
+ # If you implement #pretty_print, it can be used as follows.
213
+ #
214
+ # alias inspect pretty_print_inspect
215
+ #
216
+ # However, doing this requires that every class that #inspect is called on
217
+ # implement #pretty_print, or a RuntimeError will be raised.
218
+ #
219
+ # source://pp//lib/pp.rb#402
220
+ def pretty_print_inspect; end
221
+
222
+ # Returns a sorted array of instance variable names.
223
+ #
224
+ # This method should return an array of names of instance variables as symbols or strings as:
225
+ # +[:@a, :@b]+.
226
+ #
227
+ # source://pp//lib/pp.rb#390
228
+ def pretty_print_instance_variables; end
229
+ end
230
+
231
+ # Module that defines helper methods for pretty_print.
232
+ module PP::PPMethods
233
+ # Check whether the object_id +id+ is in the current buffer of objects
234
+ # to be pretty printed. Used to break cycles in chains of objects to be
235
+ # pretty printed.
236
+ #
237
+ # source://pp//lib/pp.rb#161
238
+ def check_inspect_key(id); end
239
+
240
+ # A convenience method which is same as follows:
241
+ #
242
+ # text ','
243
+ # breakable
244
+ #
245
+ # source://pp//lib/pp.rb#238
246
+ def comma_breakable; end
247
+
248
+ # Yields to a block
249
+ # and preserves the previous set of objects being printed.
250
+ #
251
+ # source://pp//lib/pp.rb#147
252
+ def guard_inspect_key; end
253
+
254
+ # A convenience method, like object_group, but also reformats the Object's
255
+ # object_id.
256
+ #
257
+ # source://pp//lib/pp.rb#228
258
+ def object_address_group(obj, &block); end
259
+
260
+ # A convenience method which is same as follows:
261
+ #
262
+ # group(1, '#<' + obj.class.name, '>') { ... }
263
+ #
264
+ # source://pp//lib/pp.rb#222
265
+ def object_group(obj, &block); end
266
+
267
+ # Removes an object from the set of objects being pretty printed.
268
+ #
269
+ # source://pp//lib/pp.rb#173
270
+ def pop_inspect_key(id); end
271
+
272
+ # Adds +obj+ to the pretty printing buffer
273
+ # using Object#pretty_print or Object#pretty_print_cycle.
274
+ #
275
+ # Object#pretty_print_cycle is used when +obj+ is already
276
+ # printed, a.k.a the object reference chain has a cycle.
277
+ #
278
+ # source://pp//lib/pp.rb#200
279
+ def pp(obj); end
280
+
281
+ # A pretty print for a Hash
282
+ #
283
+ # source://pp//lib/pp.rb#302
284
+ def pp_hash(obj); end
285
+
286
+ # A pretty print for a pair of Hash
287
+ #
288
+ # source://pp//lib/pp.rb#314
289
+ def pp_hash_pair(k, v); end
290
+
291
+ # A present standard failsafe for pretty printing any given Object
292
+ #
293
+ # source://pp//lib/pp.rb#286
294
+ def pp_object(obj); end
295
+
296
+ # Adds the object_id +id+ to the set of objects being pretty printed, so
297
+ # as to not repeat objects.
298
+ #
299
+ # source://pp//lib/pp.rb#168
300
+ def push_inspect_key(id); end
301
+
302
+ # Adds a separated list.
303
+ # The list is separated by comma with breakable space, by default.
304
+ #
305
+ # #seplist iterates the +list+ using +iter_method+.
306
+ # It yields each object to the block given for #seplist.
307
+ # The procedure +separator_proc+ is called between each yields.
308
+ #
309
+ # If the iteration is zero times, +separator_proc+ is not called at all.
310
+ #
311
+ # If +separator_proc+ is nil or not given,
312
+ # +lambda { comma_breakable }+ is used.
313
+ # If +iter_method+ is not given, :each is used.
314
+ #
315
+ # For example, following 3 code fragments has similar effect.
316
+ #
317
+ # q.seplist([1,2,3]) {|v| xxx v }
318
+ #
319
+ # q.seplist([1,2,3], lambda { q.comma_breakable }, :each) {|v| xxx v }
320
+ #
321
+ # xxx 1
322
+ # q.comma_breakable
323
+ # xxx 2
324
+ # q.comma_breakable
325
+ # xxx 3
326
+ #
327
+ # source://pp//lib/pp.rb#267
328
+ def seplist(list, sep = T.unsafe(nil), iter_method = T.unsafe(nil)); end
329
+
330
+ private
331
+
332
+ # source://pp//lib/pp.rb#177
333
+ def guard_inspect(object); end
334
+ end
335
+
336
+ # source://pp//lib/pp.rb#280
337
+ PP::PPMethods::EMPTY_KWHASH = T.let(T.unsafe(nil), Hash)
338
+
339
+ class PP::SingleLine < ::PrettyPrint::SingleLine
340
+ include ::PP::PPMethods
341
+ end
342
+
343
+ # The version string
344
+ #
345
+ # source://pp//lib/pp.rb#67
346
+ PP::VERSION = T.let(T.unsafe(nil), String)
347
+
348
+ class Range
349
+ include ::Enumerable
350
+
351
+ # source://pp//lib/pp.rb#529
352
+ def pretty_print(q); end
353
+ end
354
+
355
+ class RubyVM::AbstractSyntaxTree::Node
356
+ # source://pp//lib/pp.rb#679
357
+ def pretty_print(q); end
358
+
359
+ # source://pp//lib/pp.rb#666
360
+ def pretty_print_children(q, names = T.unsafe(nil)); end
361
+ end
362
+
363
+ class Set
364
+ include ::Enumerable
365
+
366
+ # source://pp//lib/pp.rb#443
367
+ def pretty_print(pp); end
368
+
369
+ # source://pp//lib/pp.rb#451
370
+ def pretty_print_cycle(pp); end
371
+ end
372
+
373
+ class Set::CoreSet < ::Set; end
374
+
375
+ class String
376
+ include ::Comparable
377
+
378
+ # source://pp//lib/pp.rb#541
379
+ def pretty_print(q); end
380
+ end
381
+
382
+ class Struct
383
+ include ::Enumerable
384
+
385
+ # source://pp//lib/pp.rb#468
386
+ def pretty_print(q); end
387
+
388
+ # source://pp//lib/pp.rb#482
389
+ def pretty_print_cycle(q); end
390
+ end