lazy_migrate 0.1.5 → 0.2.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 +4 -4
- data/.gitignore +4 -0
- data/Appraisals +9 -0
- data/Gemfile.lock +131 -2
- data/Guardfile +39 -0
- data/README.md +31 -9
- data/bin/exe/lazy_migrate +1 -2
- data/gemfiles/.bundle/config +2 -0
- data/gemfiles/rails_5_1_5.gemfile +8 -0
- data/gemfiles/rails_5_1_5.gemfile.lock +170 -0
- data/gemfiles/rails_5_2_4_3.gemfile +8 -0
- data/gemfiles/rails_5_2_4_3.gemfile.lock +178 -0
- data/github/demo.gif +0 -0
- data/lazy_migrate.gemspec +6 -0
- data/lib/lazy_migrate.rb +6 -2
- data/lib/lazy_migrate/client.rb +123 -0
- data/lib/lazy_migrate/migration.rb +14 -0
- data/lib/lazy_migrate/migrator_adapter.rb +144 -0
- data/lib/lazy_migrate/migrator_adapter_factory.rb +24 -0
- data/lib/lazy_migrate/new_migrator_adapter.rb +85 -0
- data/lib/lazy_migrate/old_migrator_adapter.rb +97 -0
- data/lib/lazy_migrate/version.rb +2 -1
- data/sorbet/config +2 -0
- data/sorbet/rbi/gems/actioncable.rbi +393 -0
- data/sorbet/rbi/gems/actionmailer.rbi +425 -0
- data/sorbet/rbi/gems/actionpack.rbi +3230 -0
- data/sorbet/rbi/gems/actionview.rbi +1153 -0
- data/sorbet/rbi/gems/activejob.rbi +282 -0
- data/sorbet/rbi/gems/activemodel.rbi +742 -0
- data/sorbet/rbi/gems/activerecord.rbi +4004 -0
- data/sorbet/rbi/gems/activestorage.rbi +174 -0
- data/sorbet/rbi/gems/activesupport.rbi +2300 -0
- data/sorbet/rbi/gems/appraisal.rbi +151 -0
- data/sorbet/rbi/gems/arel.rbi +1253 -0
- data/sorbet/rbi/gems/byebug.rbi +1041 -0
- data/sorbet/rbi/gems/coderay.rbi +92 -0
- data/sorbet/rbi/gems/concurrent-ruby.rbi +1586 -0
- data/sorbet/rbi/gems/crass.rbi +93 -0
- data/sorbet/rbi/gems/erubi.rbi +27 -0
- data/sorbet/rbi/gems/globalid.rbi +99 -0
- data/sorbet/rbi/gems/i18n.rbi +192 -0
- data/sorbet/rbi/gems/loofah.rbi +131 -0
- data/sorbet/rbi/gems/mail.rbi +1092 -0
- data/sorbet/rbi/gems/marcel.rbi +13 -0
- data/sorbet/rbi/gems/method_source.rbi +64 -0
- data/sorbet/rbi/gems/mini_mime.rbi +52 -0
- data/sorbet/rbi/gems/minitest.rbi +282 -0
- data/sorbet/rbi/gems/nio4r.rbi +68 -0
- data/sorbet/rbi/gems/nokogiri.rbi +1011 -0
- data/sorbet/rbi/gems/pastel.rbi +119 -0
- data/sorbet/rbi/gems/pry-byebug.rbi +155 -0
- data/sorbet/rbi/gems/pry.rbi +1949 -0
- data/sorbet/rbi/gems/rack-test.rbi +162 -0
- data/sorbet/rbi/gems/rack.rbi +525 -0
- data/sorbet/rbi/gems/rails-dom-testing.rbi +68 -0
- data/sorbet/rbi/gems/rails-html-sanitizer.rbi +92 -0
- data/sorbet/rbi/gems/railties.rbi +724 -0
- data/sorbet/rbi/gems/rake.rbi +666 -0
- data/sorbet/rbi/gems/rspec-core.rbi +1939 -0
- data/sorbet/rbi/gems/rspec-expectations.rbi +1123 -0
- data/sorbet/rbi/gems/rspec-mocks.rbi +1090 -0
- data/sorbet/rbi/gems/rspec-support.rbi +280 -0
- data/sorbet/rbi/gems/rspec.rbi +15 -0
- data/sorbet/rbi/gems/sprockets-rails.rbi +106 -0
- data/sorbet/rbi/gems/sprockets.rbi +755 -0
- data/sorbet/rbi/gems/sqlite3.rbi +354 -0
- data/sorbet/rbi/gems/thor.rbi +580 -0
- data/sorbet/rbi/gems/thread_safe.rbi +82 -0
- data/sorbet/rbi/gems/tty-color.rbi +44 -0
- data/sorbet/rbi/gems/tty-cursor.rbi +72 -0
- data/sorbet/rbi/gems/tty-prompt.rbi +531 -0
- data/sorbet/rbi/gems/tty-reader.rbi +176 -0
- data/sorbet/rbi/gems/tty-screen.rbi +66 -0
- data/sorbet/rbi/gems/tzinfo.rbi +406 -0
- data/sorbet/rbi/gems/websocket-driver.rbi +103 -0
- data/sorbet/rbi/gems/websocket-extensions.rbi +29 -0
- data/sorbet/rbi/gems/wisper.rbi +130 -0
- data/sorbet/rbi/hidden-definitions/errors.txt +7584 -0
- data/sorbet/rbi/hidden-definitions/hidden.rbi +13328 -0
- data/sorbet/rbi/sorbet-typed/lib/actionmailer/all/actionmailer.rbi +13 -0
- data/sorbet/rbi/sorbet-typed/lib/actionpack/all/actionpack.rbi +954 -0
- data/sorbet/rbi/sorbet-typed/lib/actionview/all/actionview.rbi +321 -0
- data/sorbet/rbi/sorbet-typed/lib/activemodel/all/activemodel.rbi +597 -0
- data/sorbet/rbi/sorbet-typed/lib/activerecord/<6/activerecord.rbi +13 -0
- data/sorbet/rbi/sorbet-typed/lib/activerecord/>=5.2/activerecord.rbi +16 -0
- data/sorbet/rbi/sorbet-typed/lib/activerecord/>=5/activerecord.rbi +53 -0
- data/sorbet/rbi/sorbet-typed/lib/activerecord/all/activerecord.rbi +1454 -0
- data/sorbet/rbi/sorbet-typed/lib/activerecord/all/model_schema.rbi +79 -0
- data/sorbet/rbi/sorbet-typed/lib/activerecord/all/sanitization.rbi +36 -0
- data/sorbet/rbi/sorbet-typed/lib/activerecord/~>5.2.0/activerecord.rbi +447 -0
- data/sorbet/rbi/sorbet-typed/lib/activestorage/<=6.1/activestorage.rbi +82 -0
- data/sorbet/rbi/sorbet-typed/lib/activestorage/all/activestorage.rbi +177 -0
- data/sorbet/rbi/sorbet-typed/lib/activesupport/all/activesupport.rbi +1431 -0
- data/sorbet/rbi/sorbet-typed/lib/minitest/all/minitest.rbi +108 -0
- data/sorbet/rbi/sorbet-typed/lib/railties/all/railties.rbi +25 -0
- data/sorbet/rbi/todo.rbi +18 -0
- data/sorbet/rbi/user-defined/activerecord.rbi +56 -0
- metadata +175 -3
- data/lib/lazy_migrate/migrator.rb +0 -186
@@ -0,0 +1,13 @@
|
|
1
|
+
# This file is autogenerated. Do not edit it by hand. Regenerate it with:
|
2
|
+
# srb rbi sorbet-typed
|
3
|
+
#
|
4
|
+
# If you would like to make changes to this file, great! Please upstream any changes you make here:
|
5
|
+
#
|
6
|
+
# https://github.com/sorbet/sorbet-typed/edit/master/lib/actionmailer/all/actionmailer.rbi
|
7
|
+
#
|
8
|
+
# typed: strong
|
9
|
+
|
10
|
+
class ActionMailer::Base
|
11
|
+
sig { params(headers: T.untyped).returns(Mail::Message) }
|
12
|
+
def mail(headers = nil, &block); end
|
13
|
+
end
|
@@ -0,0 +1,954 @@
|
|
1
|
+
# This file is autogenerated. Do not edit it by hand. Regenerate it with:
|
2
|
+
# srb rbi sorbet-typed
|
3
|
+
#
|
4
|
+
# If you would like to make changes to this file, great! Please upstream any changes you make here:
|
5
|
+
#
|
6
|
+
# https://github.com/sorbet/sorbet-typed/edit/master/lib/actionpack/all/actionpack.rbi
|
7
|
+
#
|
8
|
+
# typed: false
|
9
|
+
|
10
|
+
class ActionController::Base < ActionController::Metal
|
11
|
+
end
|
12
|
+
|
13
|
+
class AbstractController::Base < Object
|
14
|
+
end
|
15
|
+
|
16
|
+
class ActionController::Metal < AbstractController::Base
|
17
|
+
sig { returns(ActionDispatch::Request) }
|
18
|
+
def request(); end
|
19
|
+
|
20
|
+
sig { returns(ActionDispatch::Response) }
|
21
|
+
def response(); end
|
22
|
+
|
23
|
+
sig { returns(ActionController::Parameters) }
|
24
|
+
def params(); end
|
25
|
+
end
|
26
|
+
|
27
|
+
module ActionDispatch::Http::Parameters
|
28
|
+
sig { returns(ActionController::Parameters) }
|
29
|
+
def parameters(); end
|
30
|
+
|
31
|
+
# params is an alias of parameters
|
32
|
+
sig { returns(ActionController::Parameters) }
|
33
|
+
def params(); end
|
34
|
+
end
|
35
|
+
|
36
|
+
class ActionDispatch::Request
|
37
|
+
# Provides access to the request's HTTP headers, for example:
|
38
|
+
#
|
39
|
+
# ```ruby
|
40
|
+
# request.headers["Content-Type"] # => "text/plain"
|
41
|
+
# ```
|
42
|
+
sig { returns(ActionDispatch::Http::Headers) }
|
43
|
+
def headers; end
|
44
|
+
|
45
|
+
# Returns a `String` with the last requested path including their params.
|
46
|
+
#
|
47
|
+
# ```ruby
|
48
|
+
# # get '/foo'
|
49
|
+
# request.original_fullpath # => '/foo'
|
50
|
+
#
|
51
|
+
# # get '/foo?bar'
|
52
|
+
# request.original_fullpath # => '/foo?bar'
|
53
|
+
# ```
|
54
|
+
sig { returns(String) }
|
55
|
+
def original_fullpath; end
|
56
|
+
|
57
|
+
# Returns the `String` full path including params of the last URL requested.
|
58
|
+
#
|
59
|
+
# ```ruby
|
60
|
+
# # get "/articles"
|
61
|
+
# request.fullpath # => "/articles"
|
62
|
+
#
|
63
|
+
# # get "/articles?page=2"
|
64
|
+
# request.fullpath # => "/articles?page=2"
|
65
|
+
# ```
|
66
|
+
sig { returns(String) }
|
67
|
+
def fullpath; end
|
68
|
+
|
69
|
+
# Returns the original request URL as a `String`.
|
70
|
+
#
|
71
|
+
# ```ruby
|
72
|
+
# # get "/articles?page=2"
|
73
|
+
# request.original_url # => "http://www.example.com/articles?page=2"
|
74
|
+
# ```
|
75
|
+
sig { returns(String) }
|
76
|
+
def original_url; end
|
77
|
+
|
78
|
+
# The `String` MIME type of the request.
|
79
|
+
#
|
80
|
+
# ```
|
81
|
+
# # get "/articles"
|
82
|
+
# request.media_type # => "application/x-www-form-urlencoded"
|
83
|
+
# ```
|
84
|
+
sig { returns(String) }
|
85
|
+
def media_type; end
|
86
|
+
|
87
|
+
# Returns the content length of the request as an integer.
|
88
|
+
sig { returns(Integer) }
|
89
|
+
def content_length; end
|
90
|
+
|
91
|
+
# Returns the IP address of client as a `String`.
|
92
|
+
sig { returns(String) }
|
93
|
+
def ip; end
|
94
|
+
|
95
|
+
# Returns the IP address of client as a `String`,
|
96
|
+
# usually set by the RemoteIp middleware.
|
97
|
+
sig { returns(String) }
|
98
|
+
def remote_ip; end
|
99
|
+
|
100
|
+
# Returns the unique request id, which is based on either the X-Request-Id header that can
|
101
|
+
# be generated by a firewall, load balancer, or web server or by the RequestId middleware
|
102
|
+
# (which sets the action_dispatch.request_id environment variable).
|
103
|
+
#
|
104
|
+
# This unique ID is useful for tracing a request from end-to-end as part of logging or debugging.
|
105
|
+
# This relies on the Rack variable set by the ActionDispatch::RequestId middleware.
|
106
|
+
sig { returns(String) }
|
107
|
+
def request_id; end
|
108
|
+
|
109
|
+
# Returns true if the request has a header matching the given key parameter.
|
110
|
+
#
|
111
|
+
# ```ruby
|
112
|
+
# request.key? :ip_spoofing_check # => true
|
113
|
+
# ```
|
114
|
+
sig { params(key: Symbol).returns(T::Boolean) }
|
115
|
+
def key?(key); end
|
116
|
+
|
117
|
+
# True if the request came from localhost, 127.0.0.1, or ::1.
|
118
|
+
sig { returns(T::Boolean) }
|
119
|
+
def local?; end
|
120
|
+
end
|
121
|
+
|
122
|
+
class ActionDispatch::Response
|
123
|
+
end
|
124
|
+
|
125
|
+
class ActionDispatch::Http::Headers
|
126
|
+
end
|
127
|
+
|
128
|
+
class ActionController::Parameters
|
129
|
+
sig { params(other: ActionController::Parameters).returns(T::Boolean) }
|
130
|
+
def ==(other); end
|
131
|
+
|
132
|
+
sig { params(key: T.any(String, Symbol), value: T.untyped).void }
|
133
|
+
def []=(key, value); end
|
134
|
+
|
135
|
+
sig { returns(T.nilable(T::Array[T.any(String, Symbol)])) }
|
136
|
+
def always_permitted_parameters; end
|
137
|
+
|
138
|
+
sig { params(obj: T.nilable(T::Array[T.any(String, Symbol)])).void }
|
139
|
+
def always_permitted_parameters=(obj); end
|
140
|
+
|
141
|
+
sig { params(options: T.untyped).returns(T.untyped) }
|
142
|
+
def as_json(options = nil); end
|
143
|
+
|
144
|
+
sig { returns(T.untyped) }
|
145
|
+
def deep_dup; end
|
146
|
+
|
147
|
+
sig { params(key: T.any(String, Symbol), block: T.untyped).returns(T.untyped) }
|
148
|
+
def delete(key, &block); end
|
149
|
+
|
150
|
+
sig { params(keys: T.any(String, Symbol)).returns(T.untyped) }
|
151
|
+
def dig(*keys); end
|
152
|
+
|
153
|
+
sig { params(block: T.untyped).returns(T.untyped) }
|
154
|
+
def each_pair(&block); end
|
155
|
+
|
156
|
+
# each is an alias of each_pair
|
157
|
+
sig { params(block: T.untyped).returns(T.untyped) }
|
158
|
+
def each(&block); end
|
159
|
+
|
160
|
+
sig { returns(T::Boolean) }
|
161
|
+
def empty?; end
|
162
|
+
|
163
|
+
sig { params(keys: T.any(String, Symbol)).returns(ActionController::Parameters) }
|
164
|
+
def except(*keys); end
|
165
|
+
|
166
|
+
sig { params(keys: T.any(String, Symbol)).returns(T.untyped) }
|
167
|
+
def extract!(*keys); end
|
168
|
+
|
169
|
+
sig { params(key: T.any(String, Symbol), args: T.untyped).returns(T.untyped) }
|
170
|
+
def fetch(key, *args); end
|
171
|
+
|
172
|
+
sig { params(key: T.any(String, Symbol)).returns(T::Boolean) }
|
173
|
+
def has_key?(key); end
|
174
|
+
|
175
|
+
sig { params(value: T.untyped).returns(T::Boolean) }
|
176
|
+
def has_value?(value); end
|
177
|
+
|
178
|
+
sig { params(key: T.any(String, Symbol)).returns(T::Boolean) }
|
179
|
+
def include?(key); end
|
180
|
+
|
181
|
+
sig { params(parameters: T.untyped).void }
|
182
|
+
def initialize(parameters = nil); end
|
183
|
+
|
184
|
+
sig { returns(String) }
|
185
|
+
def inspect; end
|
186
|
+
|
187
|
+
sig { params(key: T.any(String, Symbol)).returns(T::Boolean) }
|
188
|
+
def key?(key); end
|
189
|
+
|
190
|
+
sig { returns(T::Array[T.untyped]) }
|
191
|
+
def keys; end
|
192
|
+
|
193
|
+
sig { params(other_hash: T.untyped).returns(ActionController::Parameters) }
|
194
|
+
def merge!(other_hash); end
|
195
|
+
|
196
|
+
sig { params(other_hash: T.untyped).returns(ActionController::Parameters) }
|
197
|
+
def merge(other_hash); end
|
198
|
+
|
199
|
+
sig { returns(T.untyped) }
|
200
|
+
def parameters; end
|
201
|
+
|
202
|
+
sig { returns(T.self_type) }
|
203
|
+
def permit!; end
|
204
|
+
|
205
|
+
# You can pass _a lot_ of stuff to permit, so filters is left untyped for now.
|
206
|
+
sig { params(filters: T.untyped).returns(ActionController::Parameters) }
|
207
|
+
def permit(*filters); end
|
208
|
+
|
209
|
+
sig { params(new_permitted: T.untyped).void }
|
210
|
+
def permitted=(new_permitted); end
|
211
|
+
|
212
|
+
sig { returns(T::Boolean) }
|
213
|
+
def permitted?; end
|
214
|
+
|
215
|
+
sig { params(block: T.untyped).returns(T.untyped) }
|
216
|
+
def reject!(&block); end
|
217
|
+
|
218
|
+
# delete_if is an alias of reject!
|
219
|
+
sig { params(block: T.untyped).returns(T.untyped) }
|
220
|
+
def delete_if(&block); end
|
221
|
+
|
222
|
+
sig { params(block: T.untyped).returns(T.untyped) }
|
223
|
+
def reject(&block); end
|
224
|
+
|
225
|
+
sig do
|
226
|
+
params(
|
227
|
+
key: T.any(String, Symbol),
|
228
|
+
).returns(
|
229
|
+
T.nilable(
|
230
|
+
T.any(
|
231
|
+
String,
|
232
|
+
Numeric,
|
233
|
+
ActionController::Parameters,
|
234
|
+
),
|
235
|
+
),
|
236
|
+
)
|
237
|
+
end
|
238
|
+
def [](key); end
|
239
|
+
|
240
|
+
sig do
|
241
|
+
params(
|
242
|
+
key: T.any(
|
243
|
+
String,
|
244
|
+
Symbol,
|
245
|
+
T::Array[T.any(String, Symbol)],
|
246
|
+
),
|
247
|
+
).returns(
|
248
|
+
T.any(
|
249
|
+
String,
|
250
|
+
Numeric,
|
251
|
+
T::Array[T.untyped],
|
252
|
+
ActionController::Parameters,
|
253
|
+
),
|
254
|
+
)
|
255
|
+
end
|
256
|
+
def require(key); end
|
257
|
+
|
258
|
+
# required is an alias of require
|
259
|
+
sig do
|
260
|
+
params(
|
261
|
+
key: T.any(
|
262
|
+
String,
|
263
|
+
Symbol,
|
264
|
+
T::Array[T.any(String, Symbol)],
|
265
|
+
),
|
266
|
+
).returns(
|
267
|
+
T.any(
|
268
|
+
String,
|
269
|
+
Numeric,
|
270
|
+
T::Array[T.untyped],
|
271
|
+
ActionController::Parameters,
|
272
|
+
),
|
273
|
+
)
|
274
|
+
end
|
275
|
+
def required(key); end
|
276
|
+
|
277
|
+
sig { params(other_hash: T.untyped).returns(ActionController::Parameters) }
|
278
|
+
def reverse_merge!(other_hash); end
|
279
|
+
|
280
|
+
# with_defaults! is an alias of reverse_merge!
|
281
|
+
sig { params(other_hash: T.untyped).returns(ActionController::Parameters) }
|
282
|
+
def with_defaults!(other_hash); end
|
283
|
+
|
284
|
+
sig { params(other_hash: T.untyped).returns(ActionController::Parameters) }
|
285
|
+
def reverse_merge(other_hash); end
|
286
|
+
|
287
|
+
# with_defaults is an alias of reverse_merge
|
288
|
+
sig { params(other_hash: T.untyped).returns(ActionController::Parameters) }
|
289
|
+
def with_defaults(other_hash); end
|
290
|
+
|
291
|
+
sig { params(block: T.untyped).returns(T.nilable(ActionController::Parameters)) }
|
292
|
+
def select!(&block); end
|
293
|
+
|
294
|
+
# keep_if is an alias of select!
|
295
|
+
sig { params(block: T.untyped).returns(T.nilable(ActionController::Parameters)) }
|
296
|
+
def keep_if(&block); end
|
297
|
+
|
298
|
+
sig { params(block: T.untyped).returns(ActionController::Parameters) }
|
299
|
+
def select(&block); end
|
300
|
+
|
301
|
+
sig { returns(T.any(Symbol, T::Boolean)) }
|
302
|
+
def self.action_on_unpermitted_parameters; end
|
303
|
+
|
304
|
+
sig { params(obj: T.any(Symbol, T::Boolean)).void }
|
305
|
+
def self.action_on_unpermitted_parameters=(obj); end
|
306
|
+
|
307
|
+
sig { returns(T::Array[T.any(String, Symbol)]) }
|
308
|
+
def self.always_permitted_parameters; end
|
309
|
+
|
310
|
+
sig { params(obj: T::Array[T.any(String, Symbol)]).void }
|
311
|
+
def self.always_permitted_parameters=(obj); end
|
312
|
+
|
313
|
+
sig { returns(T::Boolean) }
|
314
|
+
def self.permit_all_parameters; end
|
315
|
+
|
316
|
+
sig { params(obj: T::Boolean).void }
|
317
|
+
def self.permit_all_parameters=(obj); end
|
318
|
+
|
319
|
+
sig { params(keys: T.any(String, Symbol)).returns(ActionController::Parameters) }
|
320
|
+
def slice!(*keys); end
|
321
|
+
|
322
|
+
sig { params(keys: T.any(String, Symbol)).returns(ActionController::Parameters) }
|
323
|
+
def slice(*keys); end
|
324
|
+
|
325
|
+
sig { returns(ActiveSupport::HashWithIndifferentAccess) }
|
326
|
+
def to_h; end
|
327
|
+
|
328
|
+
sig { returns(T::Hash[T.untyped, T.untyped]) }
|
329
|
+
def to_hash; end
|
330
|
+
|
331
|
+
# to_param is an alias of to_query
|
332
|
+
sig { params(args: String).returns(T.nilable(String)) }
|
333
|
+
def to_param(*args); end
|
334
|
+
|
335
|
+
sig { params(args: String).returns(T.nilable(String)) }
|
336
|
+
def to_query(*args); end
|
337
|
+
|
338
|
+
sig { returns(String) }
|
339
|
+
def to_s; end
|
340
|
+
|
341
|
+
sig { returns(ActiveSupport::HashWithIndifferentAccess) }
|
342
|
+
def to_unsafe_h; end
|
343
|
+
|
344
|
+
# to_unsafe_hash is an alias of to_unsafe_h
|
345
|
+
sig { returns(ActiveSupport::HashWithIndifferentAccess) }
|
346
|
+
def to_unsafe_hash; end
|
347
|
+
|
348
|
+
sig { params(block: T.untyped).returns(ActionController::Parameters) }
|
349
|
+
def transform_keys!(&block); end
|
350
|
+
|
351
|
+
sig { params(block: T.untyped).returns(ActionController::Parameters) }
|
352
|
+
def transform_keys(&block); end
|
353
|
+
|
354
|
+
sig { returns(ActionController::Parameters) }
|
355
|
+
def transform_values!; end
|
356
|
+
|
357
|
+
sig { returns(ActionController::Parameters) }
|
358
|
+
def transform_values; end
|
359
|
+
|
360
|
+
sig { params(value: T.untyped).returns(T::Boolean) }
|
361
|
+
def value?(value); end
|
362
|
+
|
363
|
+
sig { returns(T::Array[T.untyped]) }
|
364
|
+
def values; end
|
365
|
+
|
366
|
+
sig { params(keys: T.any(String, Symbol)).returns(T.untyped) }
|
367
|
+
def values_at(*keys); end
|
368
|
+
end
|
369
|
+
|
370
|
+
module ActionController::StrongParameters
|
371
|
+
sig { returns(ActionController::Parameters) }
|
372
|
+
def params; end
|
373
|
+
end
|
374
|
+
|
375
|
+
class ActionDispatch::Routing::RouteSet
|
376
|
+
sig { params(blk: T.proc.bind(ActionDispatch::Routing::Mapper).void).void }
|
377
|
+
def draw(&blk); end
|
378
|
+
end
|
379
|
+
|
380
|
+
module ActionController::Flash::ClassMethods
|
381
|
+
sig { params(types: Symbol).void }
|
382
|
+
def add_flash_types(*types); end
|
383
|
+
end
|
384
|
+
|
385
|
+
module ActionController::RequestForgeryProtection::ClassMethods
|
386
|
+
sig do
|
387
|
+
params(
|
388
|
+
only: T.any(T::Array[Symbol], Symbol),
|
389
|
+
except: T.nilable(T.any(T::Array[Symbol], Symbol)),
|
390
|
+
if: T.untyped,
|
391
|
+
unless: T.untyped,
|
392
|
+
prepend: T.untyped,
|
393
|
+
with: T.nilable(Symbol),
|
394
|
+
exception: T.untyped,
|
395
|
+
reset_session: T.untyped,
|
396
|
+
null_session: T.untyped
|
397
|
+
).void
|
398
|
+
end
|
399
|
+
def protect_from_forgery(
|
400
|
+
only: nil,
|
401
|
+
except: nil,
|
402
|
+
if: nil,
|
403
|
+
unless: nil,
|
404
|
+
prepend: false,
|
405
|
+
with: nil,
|
406
|
+
exception: nil,
|
407
|
+
reset_session: nil,
|
408
|
+
null_session: nil
|
409
|
+
); end
|
410
|
+
end
|
411
|
+
|
412
|
+
module ActionDispatch::Routing::Mapper::HttpHelpers
|
413
|
+
# get, put, patch, post, and delete all have the same arguments as
|
414
|
+
# ActionDispatch::Routing::Mapper::Resources#match
|
415
|
+
sig do
|
416
|
+
params(
|
417
|
+
name: T.any(String, Symbol, T::Hash[String, String]),
|
418
|
+
controller: T.nilable(T.any(String, Symbol)),
|
419
|
+
action: T.nilable(T.any(String, Symbol)),
|
420
|
+
param: T.nilable(Symbol),
|
421
|
+
module: T.nilable(T.any(String, Symbol)),
|
422
|
+
as: T.nilable(T.any(String, Symbol)),
|
423
|
+
via: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
424
|
+
to: T.nilable(T.any(String, T.proc.returns(T.untyped))),
|
425
|
+
on: T.nilable(Symbol),
|
426
|
+
constraints: T.untyped,
|
427
|
+
defaults: T.nilable(T::Hash[T.untyped, T.untyped]),
|
428
|
+
anchor: T::Boolean,
|
429
|
+
format: T.nilable(T.any(String, T::Boolean)),
|
430
|
+
path: T.nilable(T.any(String, Symbol)),
|
431
|
+
block: T.untyped
|
432
|
+
).returns(T.untyped)
|
433
|
+
end
|
434
|
+
def delete(
|
435
|
+
name,
|
436
|
+
controller: nil,
|
437
|
+
action: nil,
|
438
|
+
param: :id,
|
439
|
+
module: nil,
|
440
|
+
as: nil,
|
441
|
+
via: nil,
|
442
|
+
to: nil,
|
443
|
+
on: nil,
|
444
|
+
constraints: nil,
|
445
|
+
defaults: nil,
|
446
|
+
anchor: true,
|
447
|
+
format: nil,
|
448
|
+
path: nil,
|
449
|
+
&block
|
450
|
+
); end
|
451
|
+
|
452
|
+
sig do
|
453
|
+
params(
|
454
|
+
name: T.any(String, Symbol, T::Hash[String, String]),
|
455
|
+
controller: T.nilable(T.any(String, Symbol)),
|
456
|
+
action: T.nilable(T.any(String, Symbol)),
|
457
|
+
param: T.nilable(Symbol),
|
458
|
+
module: T.nilable(T.any(String, Symbol)),
|
459
|
+
as: T.nilable(T.any(String, Symbol)),
|
460
|
+
via: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
461
|
+
to: T.nilable(T.any(String, Symbol, T.proc.returns(T.untyped))),
|
462
|
+
on: T.nilable(Symbol),
|
463
|
+
constraints: T.untyped,
|
464
|
+
defaults: T.nilable(T::Hash[T.untyped, T.untyped]),
|
465
|
+
anchor: T::Boolean,
|
466
|
+
format: T.nilable(T.any(String, T::Boolean)),
|
467
|
+
path: T.nilable(T.any(String, Symbol)),
|
468
|
+
block: T.untyped
|
469
|
+
).returns(T.untyped)
|
470
|
+
end
|
471
|
+
def get(
|
472
|
+
name,
|
473
|
+
controller: nil,
|
474
|
+
action: nil,
|
475
|
+
param: :id,
|
476
|
+
module: nil,
|
477
|
+
as: nil,
|
478
|
+
via: nil,
|
479
|
+
to: nil,
|
480
|
+
on: nil,
|
481
|
+
constraints: nil,
|
482
|
+
defaults: nil,
|
483
|
+
anchor: true,
|
484
|
+
format: nil,
|
485
|
+
path: nil,
|
486
|
+
&block
|
487
|
+
); end
|
488
|
+
|
489
|
+
sig do
|
490
|
+
params(
|
491
|
+
name: T.any(String, Symbol, T::Hash[String, String]),
|
492
|
+
controller: T.nilable(T.any(String, Symbol)),
|
493
|
+
action: T.nilable(T.any(String, Symbol)),
|
494
|
+
param: T.nilable(Symbol),
|
495
|
+
module: T.nilable(T.any(String, Symbol)),
|
496
|
+
as: T.nilable(T.any(String, Symbol)),
|
497
|
+
via: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
498
|
+
to: T.nilable(T.any(String, T.proc.returns(T.untyped))),
|
499
|
+
on: T.nilable(Symbol),
|
500
|
+
constraints: T.untyped,
|
501
|
+
defaults: T.nilable(T::Hash[T.untyped, T.untyped]),
|
502
|
+
anchor: T::Boolean,
|
503
|
+
format: T.nilable(T.any(String, T::Boolean)),
|
504
|
+
path: T.nilable(T.any(String, Symbol)),
|
505
|
+
block: T.untyped
|
506
|
+
).returns(T.untyped)
|
507
|
+
end
|
508
|
+
def patch(
|
509
|
+
name,
|
510
|
+
controller: nil,
|
511
|
+
action: nil,
|
512
|
+
param: :id,
|
513
|
+
module: nil,
|
514
|
+
as: nil,
|
515
|
+
via: nil,
|
516
|
+
to: nil,
|
517
|
+
on: nil,
|
518
|
+
constraints: nil,
|
519
|
+
defaults: nil,
|
520
|
+
anchor: true,
|
521
|
+
format: nil,
|
522
|
+
path: nil,
|
523
|
+
&block
|
524
|
+
); end
|
525
|
+
|
526
|
+
sig do
|
527
|
+
params(
|
528
|
+
name: T.any(String, Symbol, T::Hash[String, String]),
|
529
|
+
controller: T.nilable(T.any(String, Symbol)),
|
530
|
+
action: T.nilable(T.any(String, Symbol)),
|
531
|
+
param: T.nilable(Symbol),
|
532
|
+
module: T.nilable(T.any(String, Symbol)),
|
533
|
+
as: T.nilable(T.any(String, Symbol)),
|
534
|
+
via: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
535
|
+
to: T.nilable(T.any(String, T.proc.returns(T.untyped))),
|
536
|
+
on: T.nilable(Symbol),
|
537
|
+
constraints: T.untyped,
|
538
|
+
defaults: T.nilable(T::Hash[T.untyped, T.untyped]),
|
539
|
+
anchor: T::Boolean,
|
540
|
+
format: T.nilable(T.any(String, T::Boolean)),
|
541
|
+
path: T.nilable(T.any(String, Symbol)),
|
542
|
+
block: T.untyped
|
543
|
+
).returns(T.untyped)
|
544
|
+
end
|
545
|
+
def post(
|
546
|
+
name,
|
547
|
+
controller: nil,
|
548
|
+
action: nil,
|
549
|
+
param: :id,
|
550
|
+
module: nil,
|
551
|
+
as: nil,
|
552
|
+
via: nil,
|
553
|
+
to: nil,
|
554
|
+
on: nil,
|
555
|
+
constraints: nil,
|
556
|
+
defaults: nil,
|
557
|
+
anchor: true,
|
558
|
+
format: nil,
|
559
|
+
path: nil,
|
560
|
+
&block
|
561
|
+
); end
|
562
|
+
|
563
|
+
sig do
|
564
|
+
params(
|
565
|
+
name: T.any(String, Symbol, T::Hash[String, String]),
|
566
|
+
controller: T.nilable(T.any(String, Symbol)),
|
567
|
+
action: T.nilable(T.any(String, Symbol)),
|
568
|
+
param: T.nilable(Symbol),
|
569
|
+
module: T.nilable(T.any(String, Symbol)),
|
570
|
+
as: T.nilable(T.any(String, Symbol)),
|
571
|
+
via: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
572
|
+
to: T.nilable(T.any(String, T.proc.returns(T.untyped))),
|
573
|
+
on: T.nilable(Symbol),
|
574
|
+
constraints: T.untyped,
|
575
|
+
defaults: T.nilable(T::Hash[T.untyped, T.untyped]),
|
576
|
+
anchor: T::Boolean,
|
577
|
+
format: T.nilable(T.any(String, T::Boolean)),
|
578
|
+
path: T.nilable(T.any(String, Symbol)),
|
579
|
+
block: T.untyped
|
580
|
+
).returns(T.untyped)
|
581
|
+
end
|
582
|
+
def put(
|
583
|
+
name,
|
584
|
+
controller: nil,
|
585
|
+
action: nil,
|
586
|
+
param: :id,
|
587
|
+
module: nil,
|
588
|
+
as: nil,
|
589
|
+
via: nil,
|
590
|
+
to: nil,
|
591
|
+
on: nil,
|
592
|
+
constraints: nil,
|
593
|
+
defaults: nil,
|
594
|
+
anchor: true,
|
595
|
+
format: nil,
|
596
|
+
path: nil,
|
597
|
+
&block
|
598
|
+
); end
|
599
|
+
end
|
600
|
+
|
601
|
+
module ActionDispatch::Routing::Mapper::Resources
|
602
|
+
sig { params(name: T.untyped).returns(T.untyped) }
|
603
|
+
def action_path(name); end
|
604
|
+
|
605
|
+
sig { params(block: T.untyped).returns(T.untyped) }
|
606
|
+
def collection(&block); end
|
607
|
+
|
608
|
+
sig do
|
609
|
+
params(
|
610
|
+
name: T.any(String, Symbol, T::Hash[String, String]),
|
611
|
+
controller: T.nilable(T.any(String, Symbol)),
|
612
|
+
action: T.nilable(T.any(String, Symbol)),
|
613
|
+
param: T.nilable(Symbol),
|
614
|
+
module: T.nilable(T.any(String, Symbol)),
|
615
|
+
as: T.nilable(T.any(String, Symbol)),
|
616
|
+
via: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
617
|
+
to: T.nilable(T.any(String, T.proc.returns(T.untyped))),
|
618
|
+
on: T.nilable(Symbol),
|
619
|
+
constraints: T.untyped,
|
620
|
+
defaults: T.nilable(T::Hash[T.untyped, T.untyped]),
|
621
|
+
anchor: T::Boolean,
|
622
|
+
format: T.nilable(T.any(String, T::Boolean)),
|
623
|
+
path: T.nilable(T.any(String, Symbol)),
|
624
|
+
block: T.untyped
|
625
|
+
).returns(T.untyped)
|
626
|
+
end
|
627
|
+
def match(
|
628
|
+
name,
|
629
|
+
controller: nil,
|
630
|
+
action: nil,
|
631
|
+
param: :id,
|
632
|
+
module: nil,
|
633
|
+
as: nil,
|
634
|
+
via: nil,
|
635
|
+
to: nil,
|
636
|
+
on: nil,
|
637
|
+
constraints: nil,
|
638
|
+
defaults: nil,
|
639
|
+
anchor: true,
|
640
|
+
format: nil,
|
641
|
+
path: nil,
|
642
|
+
&block
|
643
|
+
); end
|
644
|
+
|
645
|
+
sig { params(block: T.untyped).returns(T.untyped) }
|
646
|
+
def member(&block); end
|
647
|
+
|
648
|
+
# These are set to T.unsafe(nil) because they do actually have values, but they
|
649
|
+
# can't be determined statically. They take the value of path when no explicit
|
650
|
+
# values are provided.
|
651
|
+
sig do
|
652
|
+
params(
|
653
|
+
path: T.untyped,
|
654
|
+
as: T.untyped,
|
655
|
+
module: T.untyped,
|
656
|
+
shallow_path: T.untyped,
|
657
|
+
shallow_prefix: T.untyped,
|
658
|
+
block: T.untyped
|
659
|
+
).returns(T.untyped)
|
660
|
+
end
|
661
|
+
def namespace(
|
662
|
+
path,
|
663
|
+
as: T.unsafe(nil),
|
664
|
+
module: T.unsafe(nil),
|
665
|
+
shallow_path: T.unsafe(nil),
|
666
|
+
shallow_prefix: T.unsafe(nil),
|
667
|
+
&block
|
668
|
+
); end
|
669
|
+
|
670
|
+
sig do
|
671
|
+
params(
|
672
|
+
resources: T.any(String, Symbol),
|
673
|
+
as: T.nilable(T.any(String, Symbol)),
|
674
|
+
controller: T.nilable(T.any(String, Symbol)),
|
675
|
+
concerns: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
676
|
+
param: T.nilable(Symbol),
|
677
|
+
path_names: T.untyped,
|
678
|
+
path: T.untyped,
|
679
|
+
only: T.nilable(T.any(
|
680
|
+
T::Array[T.any(String, Symbol)],
|
681
|
+
String,
|
682
|
+
Symbol
|
683
|
+
)),
|
684
|
+
except: T.nilable(T.any(
|
685
|
+
T::Array[T.any(String, Symbol)],
|
686
|
+
String,
|
687
|
+
Symbol
|
688
|
+
)),
|
689
|
+
shallow: T::Boolean,
|
690
|
+
shallow_path: T.nilable(String),
|
691
|
+
shallow_prefix: T.nilable(String),
|
692
|
+
format: T.untyped,
|
693
|
+
block: T.untyped
|
694
|
+
).returns(T.untyped)
|
695
|
+
end
|
696
|
+
def resource(
|
697
|
+
*resources,
|
698
|
+
as: nil,
|
699
|
+
controller: nil,
|
700
|
+
concerns: nil,
|
701
|
+
param: nil,
|
702
|
+
path_names: nil,
|
703
|
+
path: nil,
|
704
|
+
only: nil,
|
705
|
+
except: nil,
|
706
|
+
shallow: false,
|
707
|
+
shallow_path: nil,
|
708
|
+
shallow_prefix: nil,
|
709
|
+
format: nil,
|
710
|
+
&block
|
711
|
+
); end
|
712
|
+
|
713
|
+
sig do
|
714
|
+
params(
|
715
|
+
resources: T.any(String, Symbol),
|
716
|
+
as: T.nilable(T.any(String, Symbol)),
|
717
|
+
constraints: T.untyped,
|
718
|
+
controller: T.nilable(T.any(String, Symbol)),
|
719
|
+
concerns: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
720
|
+
defaults: T.untyped,
|
721
|
+
param: T.nilable(Symbol),
|
722
|
+
path_names: T.untyped,
|
723
|
+
path: T.untyped,
|
724
|
+
only: T.nilable(T.any(
|
725
|
+
T::Array[T.any(String, Symbol)],
|
726
|
+
String,
|
727
|
+
Symbol
|
728
|
+
)),
|
729
|
+
except: T.nilable(T.any(
|
730
|
+
T::Array[T.any(String, Symbol)],
|
731
|
+
String,
|
732
|
+
Symbol
|
733
|
+
)),
|
734
|
+
shallow: T::Boolean,
|
735
|
+
shallow_path: T.nilable(String),
|
736
|
+
shallow_prefix: T.nilable(String),
|
737
|
+
format: T.untyped,
|
738
|
+
block: T.untyped
|
739
|
+
).returns(T.untyped)
|
740
|
+
end
|
741
|
+
def resources(
|
742
|
+
*resources,
|
743
|
+
as: nil,
|
744
|
+
constraints: nil,
|
745
|
+
controller: nil,
|
746
|
+
concerns: nil,
|
747
|
+
defaults: nil,
|
748
|
+
param: nil,
|
749
|
+
path_names: nil,
|
750
|
+
path: nil,
|
751
|
+
only: nil,
|
752
|
+
except: nil,
|
753
|
+
shallow: false,
|
754
|
+
shallow_path: nil,
|
755
|
+
shallow_prefix: nil,
|
756
|
+
format: nil,
|
757
|
+
&block
|
758
|
+
); end
|
759
|
+
|
760
|
+
# Technically, path doesn't have a default value set. However, this is
|
761
|
+
# necessary to allow code like `root to: 'home#index'`.
|
762
|
+
sig { params(path: T.nilable(String), to: T.untyped, as: T.nilable(Symbol)).returns(T.untyped) }
|
763
|
+
def root(path = T.unsafe(nil), to: nil, as: nil); end
|
764
|
+
|
765
|
+
sig { returns(T.untyped) }
|
766
|
+
def shallow; end
|
767
|
+
|
768
|
+
sig { returns(T::Boolean) }
|
769
|
+
def shallow?; end
|
770
|
+
end
|
771
|
+
|
772
|
+
# https://api.rubyonrails.org/classes/AbstractController/Callbacks/ClassMethods.html
|
773
|
+
module AbstractController::Callbacks::ClassMethods
|
774
|
+
sig do
|
775
|
+
params(
|
776
|
+
names: Symbol,
|
777
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
778
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
779
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
780
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
781
|
+
raise: T::Boolean,
|
782
|
+
block: T.nilable(T.proc.returns(T.untyped))
|
783
|
+
).void
|
784
|
+
end
|
785
|
+
def after_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true, &block); end
|
786
|
+
|
787
|
+
# append_after_action is an alias of after_action
|
788
|
+
sig do
|
789
|
+
params(
|
790
|
+
names: Symbol,
|
791
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
792
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
793
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
794
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
795
|
+
raise: T::Boolean,
|
796
|
+
block: T.nilable(T.proc.returns(T.untyped))
|
797
|
+
).void
|
798
|
+
end
|
799
|
+
def append_after_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true, &block); end
|
800
|
+
|
801
|
+
# append_around_action is an alias of around_action
|
802
|
+
sig do
|
803
|
+
params(
|
804
|
+
names: Symbol,
|
805
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
806
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
807
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
808
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
809
|
+
raise: T::Boolean,
|
810
|
+
block: T.nilable(T.proc.returns(T.untyped))
|
811
|
+
).void
|
812
|
+
end
|
813
|
+
def append_around_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true, &block); end
|
814
|
+
|
815
|
+
# append_before_action is an alias of before_action
|
816
|
+
sig do
|
817
|
+
params(
|
818
|
+
names: Symbol,
|
819
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
820
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
821
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
822
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
823
|
+
raise: T::Boolean,
|
824
|
+
block: T.nilable(T.proc.returns(T.untyped))
|
825
|
+
).void
|
826
|
+
end
|
827
|
+
def append_before_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true, &block); end
|
828
|
+
|
829
|
+
sig do
|
830
|
+
params(
|
831
|
+
names: Symbol,
|
832
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
833
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
834
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
835
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
836
|
+
raise: T::Boolean,
|
837
|
+
block: T.nilable(T.proc.returns(T.untyped))
|
838
|
+
).void
|
839
|
+
end
|
840
|
+
def around_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true, &block); end
|
841
|
+
|
842
|
+
sig do
|
843
|
+
params(
|
844
|
+
names: Symbol,
|
845
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
846
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
847
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
848
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
849
|
+
raise: T::Boolean,
|
850
|
+
block: T.nilable(T.proc.returns(T.untyped))
|
851
|
+
).void
|
852
|
+
end
|
853
|
+
def before_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true, &block); end
|
854
|
+
|
855
|
+
sig do
|
856
|
+
params(
|
857
|
+
names: Symbol,
|
858
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
859
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
860
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
861
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
862
|
+
raise: T::Boolean,
|
863
|
+
block: T.nilable(T.proc.returns(T.untyped))
|
864
|
+
).void
|
865
|
+
end
|
866
|
+
def prepend_after_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true, &block); end
|
867
|
+
|
868
|
+
sig do
|
869
|
+
params(
|
870
|
+
names: Symbol,
|
871
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
872
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
873
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
874
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
875
|
+
raise: T::Boolean,
|
876
|
+
block: T.nilable(T.proc.returns(T.untyped))
|
877
|
+
).void
|
878
|
+
end
|
879
|
+
def prepend_around_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true, &block); end
|
880
|
+
|
881
|
+
sig do
|
882
|
+
params(
|
883
|
+
names: Symbol,
|
884
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
885
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
886
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
887
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
888
|
+
raise: T::Boolean,
|
889
|
+
block: T.nilable(T.proc.returns(T.untyped))
|
890
|
+
).void
|
891
|
+
end
|
892
|
+
def prepend_before_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true, &block); end
|
893
|
+
|
894
|
+
sig do
|
895
|
+
params(
|
896
|
+
names: Symbol,
|
897
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
898
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
899
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
900
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
901
|
+
raise: T::Boolean
|
902
|
+
).void
|
903
|
+
end
|
904
|
+
def skip_after_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true); end
|
905
|
+
|
906
|
+
sig do
|
907
|
+
params(
|
908
|
+
names: Symbol,
|
909
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
910
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
911
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
912
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
913
|
+
raise: T::Boolean
|
914
|
+
).void
|
915
|
+
end
|
916
|
+
def skip_around_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true); end
|
917
|
+
|
918
|
+
sig do
|
919
|
+
params(
|
920
|
+
names: Symbol,
|
921
|
+
except: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
922
|
+
only: T.nilable(T.any(Symbol, T::Array[Symbol])),
|
923
|
+
if: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
924
|
+
unless: T.nilable(T.any(Symbol, T::Array[Symbol], Proc)),
|
925
|
+
raise: T::Boolean
|
926
|
+
).void
|
927
|
+
end
|
928
|
+
def skip_before_action(*names, except: nil, only: nil, if: nil, unless: nil, raise: true); end
|
929
|
+
end
|
930
|
+
|
931
|
+
# https://api.rubyonrails.org/classes/ActionController/MimeResponds.html
|
932
|
+
module ActionController::MimeResponds
|
933
|
+
sig do
|
934
|
+
params(
|
935
|
+
mimes: T.nilable(Symbol),
|
936
|
+
block: T.nilable(T.proc.params(arg0: ActionController::MimeResponds::Collector).void)
|
937
|
+
).void
|
938
|
+
end
|
939
|
+
def respond_to(*mimes, &block); end
|
940
|
+
end
|
941
|
+
|
942
|
+
class ActionController::MimeResponds::Collector
|
943
|
+
sig { params(block: T.nilable(T.proc.void)).void }
|
944
|
+
def html(&block); end
|
945
|
+
|
946
|
+
sig { params(block: T.nilable(T.proc.void)).void }
|
947
|
+
def js(&block); end
|
948
|
+
|
949
|
+
sig { params(block: T.nilable(T.proc.void)).void }
|
950
|
+
def json(&block); end
|
951
|
+
|
952
|
+
sig { params(block: T.nilable(T.proc.void)).void }
|
953
|
+
def xml(&block); end
|
954
|
+
end
|