sorbet-rails 0.6.2 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +2 -0
- data/README.md +3 -3
- data/lib/bundled_rbi/typed_enum.rbi +7 -0
- data/lib/sorbet-rails.rb +0 -2
- data/lib/sorbet-rails/active_record_rbi_formatter.rb +301 -0
- data/lib/sorbet-rails/config.rb +0 -1
- data/lib/sorbet-rails/dependent_gem_rbis/activerecord.rbi +11 -0
- data/lib/sorbet-rails/deprecation.rb +5 -0
- data/lib/sorbet-rails/gem_plugins/active_flag_plugin.rb +0 -1
- data/lib/sorbet-rails/gem_plugins/paperclip_plugin.rb +0 -1
- data/lib/sorbet-rails/model_plugins/active_record_assoc.rb +36 -8
- data/lib/sorbet-rails/model_plugins/active_record_attribute.rb +20 -9
- data/lib/sorbet-rails/model_plugins/active_record_enum.rb +0 -1
- data/lib/sorbet-rails/model_plugins/active_record_named_scope.rb +15 -6
- data/lib/sorbet-rails/model_plugins/active_record_querying.rb +34 -3
- data/lib/sorbet-rails/model_plugins/active_storage_methods.rb +1 -1
- data/lib/sorbet-rails/model_plugins/base.rb +10 -0
- data/lib/sorbet-rails/model_plugins/enumerable_collections.rb +0 -50
- data/lib/sorbet-rails/model_plugins/plugins.rb +0 -3
- data/lib/sorbet-rails/model_rbi_formatter.rb +6 -10
- data/lib/sorbet-rails/model_utils.rb +83 -36
- data/lib/sorbet-rails/rails_mixins/generated_url_helpers.rb +2 -3
- data/lib/sorbet-rails/railtie.rb +0 -2
- data/lib/sorbet-rails/tasks/rails_rbi.rake +32 -24
- data/sorbet-rails.gemspec +2 -2
- data/spec/active_record_rbi_formatter_spec.rb +24 -0
- data/spec/generators/rails-template.rb +90 -6
- data/spec/generators/sorbet_test_cases.rb +204 -122
- data/spec/model_rbi_formatter_spec.rb +1 -1
- data/spec/rails_helper.rb +14 -1
- data/spec/rake_rails_rbi_active_record_spec.rb +21 -0
- data/spec/rake_rails_rbi_models_spec.rb +7 -0
- data/spec/sorbet_spec.rb +12 -1
- data/spec/support/v5.0/Gemfile.lock +8 -8
- data/spec/support/v5.0/app/models/headmaster.rb +8 -0
- data/spec/support/v5.0/app/models/school.rb +2 -0
- data/spec/support/v5.0/app/models/spell.rb +5 -0
- data/spec/support/v5.0/app/models/spell_book.rb +5 -0
- data/spec/support/v5.0/app/models/subject.rb +5 -0
- data/spec/support/v5.0/app/models/wizard.rb +6 -1
- data/spec/support/v5.0/db/migrate/20190620000010_add_subject.rb +8 -0
- data/spec/support/v5.0/db/migrate/20190620000011_add_subjects_wizards.rb +8 -0
- data/spec/support/v5.0/db/migrate/20190620000012_add_spell.rb +8 -0
- data/spec/support/v5.0/db/migrate/20190620000013_add_spells_spell_books.rb +8 -0
- data/spec/support/v5.0/db/migrate/20190620000014_create_headmasters.rb +9 -0
- data/spec/support/v5.0/db/schema.rb +28 -1
- data/spec/support/v5.0/lib/mythical_rbi_plugin.rb +1 -1
- data/spec/support/v5.0/sorbet_test_cases.rb +204 -122
- data/spec/support/v5.1/Gemfile.lock +8 -8
- data/spec/support/v5.1/app/models/headmaster.rb +8 -0
- data/spec/support/v5.1/app/models/school.rb +2 -0
- data/spec/support/v5.1/app/models/spell.rb +5 -0
- data/spec/support/v5.1/app/models/spell_book.rb +5 -0
- data/spec/support/v5.1/app/models/subject.rb +5 -0
- data/spec/support/v5.1/app/models/wizard.rb +6 -1
- data/spec/support/v5.1/db/migrate/20190620000010_add_subject.rb +8 -0
- data/spec/support/v5.1/db/migrate/20190620000011_add_subjects_wizards.rb +8 -0
- data/spec/support/v5.1/db/migrate/20190620000012_add_spell.rb +8 -0
- data/spec/support/v5.1/db/migrate/20190620000013_add_spells_spell_books.rb +8 -0
- data/spec/support/v5.1/db/migrate/20190620000014_create_headmasters.rb +9 -0
- data/spec/support/v5.1/db/schema.rb +28 -1
- data/spec/support/v5.1/lib/mythical_rbi_plugin.rb +1 -1
- data/spec/support/v5.1/sorbet_test_cases.rb +204 -122
- data/spec/support/v5.2/Gemfile +1 -1
- data/spec/support/v5.2/Gemfile.lock +9 -9
- data/spec/support/v5.2/app/models/headmaster.rb +8 -0
- data/spec/support/v5.2/app/models/school.rb +2 -0
- data/spec/support/v5.2/app/models/spell.rb +5 -0
- data/spec/support/v5.2/app/models/spell_book.rb +5 -0
- data/spec/support/v5.2/app/models/subject.rb +5 -0
- data/spec/support/v5.2/app/models/wizard.rb +5 -0
- data/spec/support/v5.2/config/puma.rb +3 -0
- data/spec/support/v5.2/db/migrate/20190620000010_add_subject.rb +8 -0
- data/spec/support/v5.2/db/migrate/20190620000011_add_subjects_wizards.rb +8 -0
- data/spec/support/v5.2/db/migrate/20190620000012_add_spell.rb +8 -0
- data/spec/support/v5.2/db/migrate/20190620000013_add_spells_spell_books.rb +8 -0
- data/spec/support/v5.2/db/migrate/20190620000014_create_headmasters.rb +9 -0
- data/spec/support/v5.2/db/schema.rb +28 -1
- data/spec/support/v5.2/lib/mythical_rbi_plugin.rb +1 -1
- data/spec/support/v5.2/sorbet_test_cases.rb +204 -122
- data/spec/support/v6.0/Gemfile.lock +8 -8
- data/spec/support/v6.0/app/models/headmaster.rb +8 -0
- data/spec/support/v6.0/app/models/school.rb +2 -0
- data/spec/support/v6.0/app/models/spell.rb +5 -0
- data/spec/support/v6.0/app/models/spell_book.rb +5 -0
- data/spec/support/v6.0/app/models/subject.rb +5 -0
- data/spec/support/v6.0/app/models/wizard.rb +6 -1
- data/spec/support/v6.0/db/migrate/20190620000010_add_subject.rb +8 -0
- data/spec/support/v6.0/db/migrate/20190620000011_add_subjects_wizards.rb +8 -0
- data/spec/support/v6.0/db/migrate/20190620000012_add_spell.rb +8 -0
- data/spec/support/v6.0/db/migrate/20190620000013_add_spells_spell_books.rb +8 -0
- data/spec/support/v6.0/db/migrate/20190620000014_create_headmasters.rb +9 -0
- data/spec/support/v6.0/db/schema.rb +28 -1
- data/spec/support/v6.0/lib/mythical_rbi_plugin.rb +1 -1
- data/spec/support/v6.0/sorbet_test_cases.rb +204 -122
- data/spec/test_data/v5.0/expected_active_record_base.rbi +113 -0
- data/spec/test_data/v5.0/expected_active_record_relation.rbi +199 -0
- data/spec/test_data/v5.0/expected_habtm_subjects.rbi +660 -0
- data/spec/test_data/v5.0/expected_habtm_wizards.rbi +660 -0
- data/spec/test_data/v5.0/expected_headmaster.rbi +304 -0
- data/spec/test_data/v5.0/expected_internal_metadata.rbi +38 -401
- data/spec/test_data/v5.0/expected_potion.rbi +38 -401
- data/spec/test_data/v5.0/expected_robe.rbi +38 -403
- data/spec/test_data/v5.0/expected_schema_migration.rbi +38 -401
- data/spec/test_data/v5.0/expected_school.rbi +47 -401
- data/spec/test_data/v5.0/expected_spell.rbi +292 -0
- data/spec/test_data/v5.0/expected_spell/habtm_spell_books.rbi +295 -0
- data/spec/test_data/v5.0/expected_spell_book.rbi +86 -432
- data/spec/test_data/v5.0/expected_spell_book/habtm_spell_books.rbi +637 -0
- data/spec/test_data/v5.0/expected_spell_book/habtm_spells.rbi +295 -0
- data/spec/test_data/v5.0/expected_squib.rbi +122 -477
- data/spec/test_data/v5.0/expected_subject.rbi +292 -0
- data/spec/test_data/v5.0/expected_subject/habtm_wizards.rbi +295 -0
- data/spec/test_data/v5.0/expected_wand.rbi +75 -442
- data/spec/test_data/v5.0/expected_wizard.rbi +144 -498
- data/spec/test_data/v5.0/expected_wizard/habtm_subjects.rbi +295 -0
- data/spec/test_data/v5.0/expected_wizard_wo_spellbook.rbi +138 -498
- data/spec/test_data/v5.1/expected_active_record_base.rbi +113 -0
- data/spec/test_data/v5.1/expected_active_record_relation.rbi +178 -0
- data/spec/test_data/v5.1/expected_habtm_subjects.rbi +672 -0
- data/spec/test_data/v5.1/expected_habtm_wizards.rbi +672 -0
- data/spec/test_data/v5.1/expected_headmaster.rbi +310 -0
- data/spec/test_data/v5.1/expected_internal_metadata.rbi +38 -407
- data/spec/test_data/v5.1/expected_potion.rbi +38 -407
- data/spec/test_data/v5.1/expected_robe.rbi +38 -409
- data/spec/test_data/v5.1/expected_schema_migration.rbi +38 -407
- data/spec/test_data/v5.1/expected_school.rbi +47 -407
- data/spec/test_data/v5.1/expected_spell.rbi +298 -0
- data/spec/test_data/v5.1/expected_spell/habtm_spell_books.rbi +301 -0
- data/spec/test_data/v5.1/expected_spell_book.rbi +86 -438
- data/spec/test_data/v5.1/expected_spell_book/habtm_spell_books.rbi +649 -0
- data/spec/test_data/v5.1/expected_spell_book/habtm_spells.rbi +301 -0
- data/spec/test_data/v5.1/expected_squib.rbi +123 -484
- data/spec/test_data/v5.1/expected_subject.rbi +298 -0
- data/spec/test_data/v5.1/expected_subject/habtm_wizards.rbi +301 -0
- data/spec/test_data/v5.1/expected_wand.rbi +75 -448
- data/spec/test_data/v5.1/expected_wizard.rbi +145 -505
- data/spec/test_data/v5.1/expected_wizard/habtm_subjects.rbi +301 -0
- data/spec/test_data/v5.1/expected_wizard_wo_spellbook.rbi +139 -505
- data/spec/test_data/v5.2/expected_active_record_base.rbi +113 -0
- data/spec/test_data/v5.2/expected_active_record_relation.rbi +175 -0
- data/spec/test_data/v5.2/expected_attachment.rbi +38 -407
- data/spec/test_data/v5.2/expected_blob.rbi +60 -426
- data/spec/test_data/v5.2/expected_habtm_subjects.rbi +672 -0
- data/spec/test_data/v5.2/expected_habtm_wizards.rbi +672 -0
- data/spec/test_data/v5.2/expected_headmaster.rbi +310 -0
- data/spec/test_data/v5.2/expected_internal_metadata.rbi +38 -407
- data/spec/test_data/v5.2/expected_potion.rbi +38 -407
- data/spec/test_data/v5.2/expected_robe.rbi +38 -409
- data/spec/test_data/v5.2/expected_schema_migration.rbi +38 -407
- data/spec/test_data/v5.2/expected_school.rbi +47 -407
- data/spec/test_data/v5.2/expected_spell.rbi +298 -0
- data/spec/test_data/v5.2/expected_spell/habtm_spell_books.rbi +301 -0
- data/spec/test_data/v5.2/expected_spell_book.rbi +86 -438
- data/spec/test_data/v5.2/expected_spell_book/habtm_spell_books.rbi +649 -0
- data/spec/test_data/v5.2/expected_spell_book/habtm_spells.rbi +301 -0
- data/spec/test_data/v5.2/expected_squib.rbi +133 -488
- data/spec/test_data/v5.2/expected_subject.rbi +298 -0
- data/spec/test_data/v5.2/expected_subject/habtm_wizards.rbi +301 -0
- data/spec/test_data/v5.2/expected_wand.rbi +75 -448
- data/spec/test_data/v5.2/expected_wizard.rbi +155 -509
- data/spec/test_data/v5.2/expected_wizard/habtm_subjects.rbi +301 -0
- data/spec/test_data/v5.2/expected_wizard_wo_spellbook.rbi +149 -509
- data/spec/test_data/v6.0/expected_active_record_base.rbi +113 -0
- data/spec/test_data/v6.0/expected_active_record_relation.rbi +175 -0
- data/spec/test_data/v6.0/expected_attachment.rbi +38 -431
- data/spec/test_data/v6.0/expected_blob.rbi +60 -450
- data/spec/test_data/v6.0/expected_habtm_subjects.rbi +720 -0
- data/spec/test_data/v6.0/expected_habtm_wizards.rbi +720 -0
- data/spec/test_data/v6.0/expected_headmaster.rbi +334 -0
- data/spec/test_data/v6.0/expected_internal_metadata.rbi +38 -431
- data/spec/test_data/v6.0/expected_potion.rbi +38 -431
- data/spec/test_data/v6.0/expected_robe.rbi +38 -433
- data/spec/test_data/v6.0/expected_routes.rbi +14 -7
- data/spec/test_data/v6.0/expected_schema_migration.rbi +38 -431
- data/spec/test_data/v6.0/expected_school.rbi +47 -431
- data/spec/test_data/v6.0/expected_spell.rbi +322 -0
- data/spec/test_data/v6.0/expected_spell/habtm_spell_books.rbi +325 -0
- data/spec/test_data/v6.0/expected_spell_book.rbi +98 -474
- data/spec/test_data/v6.0/expected_spell_book/habtm_spell_books.rbi +697 -0
- data/spec/test_data/v6.0/expected_spell_book/habtm_spells.rbi +325 -0
- data/spec/test_data/v6.0/expected_squib.rbi +162 -541
- data/spec/test_data/v6.0/expected_subject.rbi +322 -0
- data/spec/test_data/v6.0/expected_subject/habtm_wizards.rbi +325 -0
- data/spec/test_data/v6.0/expected_wand.rbi +91 -488
- data/spec/test_data/v6.0/expected_wizard.rbi +184 -562
- data/spec/test_data/v6.0/expected_wizard/habtm_subjects.rbi +325 -0
- data/spec/test_data/v6.0/expected_wizard_wo_spellbook.rbi +178 -562
- metadata +170 -24
- data/lib/bundled_rbi/active_record_base.rbi +0 -83
- data/lib/bundled_rbi/active_record_relation.rbi +0 -122
- data/lib/bundled_rbi/parameters.rbi +0 -28
- data/lib/sorbet-rails/custom_types/boolean_string.rb +0 -32
- data/lib/sorbet-rails/custom_types/integer_string.rb +0 -35
- data/lib/sorbet-rails/model_plugins/active_record_finder_methods.rb +0 -131
- data/lib/sorbet-rails/rails_mixins/custom_params_methods.rb +0 -46
- data/spec/boolean_string_spec.rb +0 -59
- data/spec/custom_params_methods_spec.rb +0 -138
- data/spec/integer_string_spec.rb +0 -46
- data/spec/support/v5.0/typed-override.yaml +0 -2
- data/spec/support/v5.1/typed-override.yaml +0 -2
- data/spec/support/v5.2/typed-override.yaml +0 -2
- data/spec/support/v6.0/typed-override.yaml +0 -2
@@ -3,8 +3,6 @@
|
|
3
3
|
|
4
4
|
# typed: strong
|
5
5
|
module Wizard::EnumInstanceMethods
|
6
|
-
extend T::Sig
|
7
|
-
|
8
6
|
sig { returns(T::Boolean) }
|
9
7
|
def broom_nimbus?; end
|
10
8
|
|
@@ -114,8 +112,6 @@ module Wizard::ActiveRelation_WhereNot
|
|
114
112
|
end
|
115
113
|
|
116
114
|
module Wizard::GeneratedAttributeMethods
|
117
|
-
extend T::Sig
|
118
|
-
|
119
115
|
sig { returns(T::Boolean) }
|
120
116
|
def broom?; end
|
121
117
|
|
@@ -167,10 +163,10 @@ module Wizard::GeneratedAttributeMethods
|
|
167
163
|
sig { returns(T::Boolean) }
|
168
164
|
def id?; end
|
169
165
|
|
170
|
-
sig { returns(
|
166
|
+
sig { returns(String) }
|
171
167
|
def name; end
|
172
168
|
|
173
|
-
sig { params(value: T.
|
169
|
+
sig { params(value: T.any(String, Symbol)).void }
|
174
170
|
def name=(value); end
|
175
171
|
|
176
172
|
sig { returns(T::Boolean) }
|
@@ -236,73 +232,78 @@ end
|
|
236
232
|
|
237
233
|
class Wizard::Broom < T::Enum
|
238
234
|
enums do
|
239
|
-
Nimbus = new(
|
240
|
-
Firebolt = new(
|
235
|
+
Nimbus = new(%q{nimbus})
|
236
|
+
Firebolt = new(%q{firebolt})
|
241
237
|
end
|
242
238
|
|
243
239
|
end
|
244
240
|
|
245
241
|
class Wizard::EyeColor < T::Enum
|
246
242
|
enums do
|
247
|
-
Brown = new(
|
248
|
-
Green = new(
|
249
|
-
Blue = new(
|
243
|
+
Brown = new(%q{brown})
|
244
|
+
Green = new(%q{green})
|
245
|
+
Blue = new(%q{blue})
|
250
246
|
end
|
251
247
|
|
252
248
|
end
|
253
249
|
|
254
250
|
class Wizard::HairColor < T::Enum
|
255
251
|
enums do
|
256
|
-
Brown = new(
|
257
|
-
Black = new(
|
258
|
-
Blonde = new(
|
252
|
+
Brown = new(%q{brown})
|
253
|
+
Black = new(%q{black})
|
254
|
+
Blonde = new(%q{blonde})
|
259
255
|
end
|
260
256
|
|
261
257
|
end
|
262
258
|
|
263
259
|
class Wizard::House < T::Enum
|
264
260
|
enums do
|
265
|
-
Gryffindor = new(
|
266
|
-
Hufflepuff = new(
|
267
|
-
Ravenclaw = new(
|
268
|
-
Slytherin = new(
|
261
|
+
Gryffindor = new(%q{Gryffindor})
|
262
|
+
Hufflepuff = new(%q{Hufflepuff})
|
263
|
+
Ravenclaw = new(%q{Ravenclaw})
|
264
|
+
Slytherin = new(%q{Slytherin})
|
269
265
|
end
|
270
266
|
|
271
267
|
end
|
272
268
|
|
273
269
|
class Wizard::ProfessorEnum < T::Enum
|
274
270
|
enums do
|
275
|
-
SeverusSnape = new(
|
276
|
-
MinervaMcGonagall = new(
|
277
|
-
PomonaSprout = new(
|
278
|
-
FiliusFlitwick = new(
|
279
|
-
Hagrid = new(
|
271
|
+
SeverusSnape = new(%q{Severus Snape})
|
272
|
+
MinervaMcGonagall = new(%q{Minerva McGonagall})
|
273
|
+
PomonaSprout = new(%q{Pomona Sprout})
|
274
|
+
FiliusFlitwick = new(%q{Filius Flitwick})
|
275
|
+
Hagrid = new(%q{Hagrid})
|
276
|
+
AlastorMadEyeMoody = new(%q{Alastor 'Mad-Eye' Moody})
|
280
277
|
end
|
281
278
|
|
282
279
|
end
|
283
280
|
|
284
281
|
class Wizard::QuidditchPosition < T::Enum
|
285
282
|
enums do
|
286
|
-
Keeper = new(
|
287
|
-
Seeker = new(
|
288
|
-
Beater = new(
|
289
|
-
Chaser = new(
|
283
|
+
Keeper = new(%q{keeper})
|
284
|
+
Seeker = new(%q{seeker})
|
285
|
+
Beater = new(%q{beater})
|
286
|
+
Chaser = new(%q{chaser})
|
290
287
|
end
|
291
288
|
|
292
289
|
end
|
293
290
|
|
294
291
|
module Wizard::GeneratedAssociationMethods
|
295
|
-
extend T::Sig
|
296
|
-
|
297
292
|
sig { returns(::ActiveStorage::Attachment::ActiveRecord_Associations_CollectionProxy) }
|
298
293
|
def hats_attachments; end
|
299
294
|
|
295
|
+
sig { returns(T::Array[Integer]) }
|
296
|
+
def hats_attachment_ids; end
|
297
|
+
|
300
298
|
sig { params(value: T::Enumerable[::ActiveStorage::Attachment]).void }
|
301
299
|
def hats_attachments=(value); end
|
302
300
|
|
303
301
|
sig { returns(::ActiveStorage::Blob::ActiveRecord_Associations_CollectionProxy) }
|
304
302
|
def hats_blobs; end
|
305
303
|
|
304
|
+
sig { returns(T::Array[Integer]) }
|
305
|
+
def hats_blob_ids; end
|
306
|
+
|
306
307
|
sig { params(value: T::Enumerable[::ActiveStorage::Blob]).void }
|
307
308
|
def hats_blobs=(value); end
|
308
309
|
|
@@ -327,9 +328,21 @@ module Wizard::GeneratedAssociationMethods
|
|
327
328
|
sig { returns(::SpellBook::ActiveRecord_Associations_CollectionProxy) }
|
328
329
|
def spell_books; end
|
329
330
|
|
331
|
+
sig { returns(T::Array[Integer]) }
|
332
|
+
def spell_book_ids; end
|
333
|
+
|
330
334
|
sig { params(value: T::Enumerable[::SpellBook]).void }
|
331
335
|
def spell_books=(value); end
|
332
336
|
|
337
|
+
sig { returns(::Subject::ActiveRecord_Associations_CollectionProxy) }
|
338
|
+
def subjects; end
|
339
|
+
|
340
|
+
sig { returns(T::Array[Integer]) }
|
341
|
+
def subject_ids; end
|
342
|
+
|
343
|
+
sig { params(value: T::Enumerable[::Subject]).void }
|
344
|
+
def subjects=(value); end
|
345
|
+
|
333
346
|
sig { returns(T.nilable(::Wand)) }
|
334
347
|
def wand; end
|
335
348
|
|
@@ -359,8 +372,7 @@ class Wizard < ApplicationRecord
|
|
359
372
|
include Wizard::GeneratedAttributeMethods
|
360
373
|
include Wizard::GeneratedAssociationMethods
|
361
374
|
extend Wizard::CustomFinderMethods
|
362
|
-
extend
|
363
|
-
extend T::Generic
|
375
|
+
extend Wizard::QueryMethodsReturningRelation
|
364
376
|
RelationType = T.type_alias { T.any(Wizard::ActiveRecord_Relation, Wizard::ActiveRecord_Associations_CollectionProxy, Wizard::ActiveRecord_AssociationRelation) }
|
365
377
|
|
366
378
|
sig { returns(T::Hash[T.any(String, Symbol), String]) }
|
@@ -441,93 +453,6 @@ class Wizard < ApplicationRecord
|
|
441
453
|
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
442
454
|
def self.with_attached_school_photo(*args); end
|
443
455
|
|
444
|
-
sig { returns(Wizard::ActiveRecord_Relation) }
|
445
|
-
def self.all; end
|
446
|
-
|
447
|
-
sig { params(block: T.nilable(T.proc.void)).returns(Wizard::ActiveRecord_Relation) }
|
448
|
-
def self.unscoped(&block); end
|
449
|
-
|
450
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
451
|
-
def self.select(*args); end
|
452
|
-
|
453
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
454
|
-
def self.order(*args); end
|
455
|
-
|
456
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
457
|
-
def self.reorder(*args); end
|
458
|
-
|
459
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
460
|
-
def self.group(*args); end
|
461
|
-
|
462
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
463
|
-
def self.limit(*args); end
|
464
|
-
|
465
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
466
|
-
def self.offset(*args); end
|
467
|
-
|
468
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
469
|
-
def self.joins(*args); end
|
470
|
-
|
471
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
472
|
-
def self.left_joins(*args); end
|
473
|
-
|
474
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
475
|
-
def self.left_outer_joins(*args); end
|
476
|
-
|
477
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
478
|
-
def self.where(*args); end
|
479
|
-
|
480
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
481
|
-
def self.rewhere(*args); end
|
482
|
-
|
483
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
484
|
-
def self.preload(*args); end
|
485
|
-
|
486
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
487
|
-
def self.eager_load(*args); end
|
488
|
-
|
489
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
490
|
-
def self.includes(*args); end
|
491
|
-
|
492
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
493
|
-
def self.from(*args); end
|
494
|
-
|
495
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
496
|
-
def self.lock(*args); end
|
497
|
-
|
498
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
499
|
-
def self.readonly(*args); end
|
500
|
-
|
501
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
502
|
-
def self.or(*args); end
|
503
|
-
|
504
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
505
|
-
def self.having(*args); end
|
506
|
-
|
507
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
508
|
-
def self.create_with(*args); end
|
509
|
-
|
510
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
511
|
-
def self.distinct(*args); end
|
512
|
-
|
513
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
514
|
-
def self.references(*args); end
|
515
|
-
|
516
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
517
|
-
def self.none(*args); end
|
518
|
-
|
519
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
520
|
-
def self.unscope(*args); end
|
521
|
-
|
522
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
523
|
-
def self.merge(*args); end
|
524
|
-
|
525
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
526
|
-
def self.except(*args); end
|
527
|
-
|
528
|
-
sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Wizard::ActiveRecord_Relation) }
|
529
|
-
def self.extending(*args, &block); end
|
530
|
-
|
531
456
|
sig { returns(T.nilable(Wizard::Broom)) }
|
532
457
|
def typed_broom; end
|
533
458
|
|
@@ -563,32 +488,12 @@ class Wizard < ApplicationRecord
|
|
563
488
|
|
564
489
|
sig { params(value: T.nilable(Wizard::QuidditchPosition)).void }
|
565
490
|
def typed_quidditch_position=(value); end
|
566
|
-
|
567
|
-
sig { params(conditions: T.untyped).returns(T::Boolean) }
|
568
|
-
def self.exists?(conditions = nil); end
|
569
|
-
|
570
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
571
|
-
def self.any?(*args); end
|
572
|
-
|
573
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
574
|
-
def self.many?(*args); end
|
575
|
-
|
576
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
577
|
-
def self.none?(*args); end
|
578
|
-
|
579
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
580
|
-
def self.one?(*args); end
|
581
|
-
|
582
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
583
|
-
def self.empty?(*args); end
|
584
491
|
end
|
585
492
|
|
586
493
|
class Wizard::ActiveRecord_Relation < ActiveRecord::Relation
|
587
494
|
include Wizard::ActiveRelation_WhereNot
|
588
495
|
include Wizard::CustomFinderMethods
|
589
|
-
include
|
590
|
-
extend T::Sig
|
591
|
-
extend T::Generic
|
496
|
+
include Wizard::QueryMethodsReturningRelation
|
592
497
|
Elem = type_member(fixed: Wizard)
|
593
498
|
|
594
499
|
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
@@ -650,119 +555,78 @@ class Wizard::ActiveRecord_Relation < ActiveRecord::Relation
|
|
650
555
|
|
651
556
|
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
652
557
|
def with_attached_school_photo(*args); end
|
558
|
+
end
|
653
559
|
|
654
|
-
|
655
|
-
|
656
|
-
|
657
|
-
|
658
|
-
|
659
|
-
|
660
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
661
|
-
def select(*args); end
|
662
|
-
|
663
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
664
|
-
def order(*args); end
|
665
|
-
|
666
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
667
|
-
def reorder(*args); end
|
668
|
-
|
669
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
670
|
-
def group(*args); end
|
671
|
-
|
672
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
673
|
-
def limit(*args); end
|
674
|
-
|
675
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
676
|
-
def offset(*args); end
|
677
|
-
|
678
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
679
|
-
def joins(*args); end
|
680
|
-
|
681
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
682
|
-
def left_joins(*args); end
|
683
|
-
|
684
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
685
|
-
def left_outer_joins(*args); end
|
686
|
-
|
687
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
688
|
-
def where(*args); end
|
689
|
-
|
690
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
691
|
-
def rewhere(*args); end
|
692
|
-
|
693
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
694
|
-
def preload(*args); end
|
695
|
-
|
696
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
697
|
-
def eager_load(*args); end
|
560
|
+
class Wizard::ActiveRecord_AssociationRelation < ActiveRecord::AssociationRelation
|
561
|
+
include Wizard::ActiveRelation_WhereNot
|
562
|
+
include Wizard::CustomFinderMethods
|
563
|
+
include Wizard::QueryMethodsReturningAssociationRelation
|
564
|
+
Elem = type_member(fixed: Wizard)
|
698
565
|
|
699
|
-
sig { params(args: T.untyped).returns(Wizard::
|
700
|
-
def
|
566
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
567
|
+
def Gryffindor(*args); end
|
701
568
|
|
702
|
-
sig { params(args: T.untyped).returns(Wizard::
|
703
|
-
def
|
569
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
570
|
+
def Hagrid(*args); end
|
704
571
|
|
705
|
-
sig { params(args: T.untyped).returns(Wizard::
|
706
|
-
def
|
572
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
573
|
+
def Hufflepuff(*args); end
|
707
574
|
|
708
|
-
sig { params(args: T.untyped).returns(Wizard::
|
709
|
-
def
|
575
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
576
|
+
def Ravenclaw(*args); end
|
710
577
|
|
711
|
-
sig { params(args: T.untyped).returns(Wizard::
|
712
|
-
def
|
578
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
579
|
+
def Slytherin(*args); end
|
713
580
|
|
714
|
-
sig { params(args: T.untyped).returns(Wizard::
|
715
|
-
def
|
581
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
582
|
+
def black_hair(*args); end
|
716
583
|
|
717
|
-
sig { params(args: T.untyped).returns(Wizard::
|
718
|
-
def
|
584
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
585
|
+
def blonde_hair(*args); end
|
719
586
|
|
720
|
-
sig { params(args: T.untyped).returns(Wizard::
|
721
|
-
def
|
587
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
588
|
+
def broom_firebolt(*args); end
|
722
589
|
|
723
|
-
sig { params(args: T.untyped).returns(Wizard::
|
724
|
-
def
|
590
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
591
|
+
def broom_nimbus(*args); end
|
725
592
|
|
726
|
-
sig { params(args: T.untyped).returns(Wizard::
|
727
|
-
def
|
593
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
594
|
+
def brown_hair(*args); end
|
728
595
|
|
729
|
-
sig { params(args: T.untyped).returns(Wizard::
|
730
|
-
def
|
596
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
597
|
+
def color_blue_eyes(*args); end
|
731
598
|
|
732
|
-
sig { params(args: T.untyped).returns(Wizard::
|
733
|
-
def
|
599
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
600
|
+
def color_brown_eyes(*args); end
|
734
601
|
|
735
|
-
sig { params(args: T.untyped).returns(Wizard::
|
736
|
-
def
|
602
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
603
|
+
def color_green_eyes(*args); end
|
737
604
|
|
738
|
-
sig { params(args: T.untyped
|
739
|
-
def
|
605
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
606
|
+
def quidditch_beater(*args); end
|
740
607
|
|
741
|
-
sig { params(
|
742
|
-
def
|
608
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
609
|
+
def quidditch_chaser(*args); end
|
743
610
|
|
744
|
-
sig { params(args: T.untyped).returns(
|
745
|
-
def
|
611
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
612
|
+
def quidditch_keeper(*args); end
|
746
613
|
|
747
|
-
sig { params(args: T.untyped).returns(
|
748
|
-
def
|
614
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
615
|
+
def quidditch_seeker(*args); end
|
749
616
|
|
750
|
-
sig { params(args: T.untyped).returns(
|
751
|
-
def
|
617
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
618
|
+
def recent(*args); end
|
752
619
|
|
753
|
-
sig { params(args: T.untyped).returns(
|
754
|
-
def
|
620
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
621
|
+
def with_attached_hats(*args); end
|
755
622
|
|
756
|
-
sig { params(args: T.untyped).returns(
|
757
|
-
def
|
623
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
624
|
+
def with_attached_school_photo(*args); end
|
758
625
|
end
|
759
626
|
|
760
|
-
class Wizard::
|
761
|
-
include Wizard::ActiveRelation_WhereNot
|
627
|
+
class Wizard::ActiveRecord_Associations_CollectionProxy < ActiveRecord::Associations::CollectionProxy
|
762
628
|
include Wizard::CustomFinderMethods
|
763
|
-
include
|
764
|
-
extend T::Sig
|
765
|
-
extend T::Generic
|
629
|
+
include Wizard::QueryMethodsReturningAssociationRelation
|
766
630
|
Elem = type_member(fixed: Wizard)
|
767
631
|
|
768
632
|
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
@@ -825,254 +689,125 @@ class Wizard::ActiveRecord_AssociationRelation < ActiveRecord::AssociationRelati
|
|
825
689
|
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
826
690
|
def with_attached_school_photo(*args); end
|
827
691
|
|
828
|
-
sig {
|
692
|
+
sig { params(records: T.any(Wizard, T::Array[Wizard])).returns(T.self_type) }
|
693
|
+
def <<(*records); end
|
694
|
+
|
695
|
+
sig { params(records: T.any(Wizard, T::Array[Wizard])).returns(T.self_type) }
|
696
|
+
def append(*records); end
|
697
|
+
|
698
|
+
sig { params(records: T.any(Wizard, T::Array[Wizard])).returns(T.self_type) }
|
699
|
+
def push(*records); end
|
700
|
+
|
701
|
+
sig { params(records: T.any(Wizard, T::Array[Wizard])).returns(T.self_type) }
|
702
|
+
def concat(*records); end
|
703
|
+
end
|
704
|
+
|
705
|
+
module Wizard::QueryMethodsReturningRelation
|
706
|
+
sig { returns(Wizard::ActiveRecord_Relation) }
|
829
707
|
def all; end
|
830
708
|
|
831
|
-
sig { params(block: T.nilable(T.proc.void)).returns(Wizard::
|
709
|
+
sig { params(block: T.nilable(T.proc.void)).returns(Wizard::ActiveRecord_Relation) }
|
832
710
|
def unscoped(&block); end
|
833
711
|
|
834
|
-
sig { params(args: T.untyped).returns(Wizard::
|
712
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
835
713
|
def select(*args); end
|
836
714
|
|
837
|
-
sig { params(args: T.untyped).returns(Wizard::
|
715
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
838
716
|
def order(*args); end
|
839
717
|
|
840
|
-
sig { params(args: T.untyped).returns(Wizard::
|
718
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
841
719
|
def reorder(*args); end
|
842
720
|
|
843
|
-
sig { params(args: T.untyped).returns(Wizard::
|
721
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
844
722
|
def group(*args); end
|
845
723
|
|
846
|
-
sig { params(args: T.untyped).returns(Wizard::
|
724
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
847
725
|
def limit(*args); end
|
848
726
|
|
849
|
-
sig { params(args: T.untyped).returns(Wizard::
|
727
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
850
728
|
def offset(*args); end
|
851
729
|
|
852
|
-
sig { params(args: T.untyped).returns(Wizard::
|
730
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
853
731
|
def joins(*args); end
|
854
732
|
|
855
|
-
sig { params(args: T.untyped).returns(Wizard::
|
733
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
856
734
|
def left_joins(*args); end
|
857
735
|
|
858
|
-
sig { params(args: T.untyped).returns(Wizard::
|
736
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
859
737
|
def left_outer_joins(*args); end
|
860
738
|
|
861
|
-
sig { params(args: T.untyped).returns(Wizard::
|
739
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
862
740
|
def where(*args); end
|
863
741
|
|
864
|
-
sig { params(args: T.untyped).returns(Wizard::
|
742
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
865
743
|
def rewhere(*args); end
|
866
744
|
|
867
|
-
sig { params(args: T.untyped).returns(Wizard::
|
745
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
868
746
|
def preload(*args); end
|
869
747
|
|
870
|
-
sig { params(args: T.untyped).returns(Wizard::
|
748
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
871
749
|
def eager_load(*args); end
|
872
750
|
|
873
|
-
sig { params(args: T.untyped).returns(Wizard::
|
751
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
874
752
|
def includes(*args); end
|
875
753
|
|
876
|
-
sig { params(args: T.untyped).returns(Wizard::
|
754
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
877
755
|
def from(*args); end
|
878
756
|
|
879
|
-
sig { params(args: T.untyped).returns(Wizard::
|
757
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
880
758
|
def lock(*args); end
|
881
759
|
|
882
|
-
sig { params(args: T.untyped).returns(Wizard::
|
760
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
883
761
|
def readonly(*args); end
|
884
762
|
|
885
|
-
sig { params(args: T.untyped).returns(Wizard::
|
763
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
886
764
|
def or(*args); end
|
887
765
|
|
888
|
-
sig { params(args: T.untyped).returns(Wizard::
|
766
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
889
767
|
def having(*args); end
|
890
768
|
|
891
|
-
sig { params(args: T.untyped).returns(Wizard::
|
769
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
892
770
|
def create_with(*args); end
|
893
771
|
|
894
|
-
sig { params(args: T.untyped).returns(Wizard::
|
772
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
895
773
|
def distinct(*args); end
|
896
774
|
|
897
|
-
sig { params(args: T.untyped).returns(Wizard::
|
775
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
898
776
|
def references(*args); end
|
899
777
|
|
900
|
-
sig { params(args: T.untyped).returns(Wizard::
|
778
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
901
779
|
def none(*args); end
|
902
780
|
|
903
|
-
sig { params(args: T.untyped).returns(Wizard::
|
781
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
904
782
|
def unscope(*args); end
|
905
783
|
|
906
|
-
sig { params(args: T.untyped).returns(Wizard::
|
784
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
907
785
|
def merge(*args); end
|
908
786
|
|
909
|
-
sig { params(args: T.untyped).returns(Wizard::
|
787
|
+
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_Relation) }
|
910
788
|
def except(*args); end
|
911
789
|
|
912
|
-
sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Wizard::
|
790
|
+
sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Wizard::ActiveRecord_Relation) }
|
913
791
|
def extending(*args, &block); end
|
914
792
|
|
915
|
-
sig { params(args: T.untyped).returns(Wizard) }
|
916
|
-
def find(*args); end
|
917
|
-
|
918
|
-
sig { params(args: T.untyped).returns(T.nilable(Wizard)) }
|
919
|
-
def find_by(*args); end
|
920
|
-
|
921
|
-
sig { params(args: T.untyped).returns(Wizard) }
|
922
|
-
def find_by!(*args); end
|
923
|
-
|
924
|
-
sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: Wizard).void)).returns(Wizard) }
|
925
|
-
def find_or_initialize_by(attributes, &block); end
|
926
|
-
|
927
|
-
sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: Wizard).void)).returns(Wizard) }
|
928
|
-
def find_or_create_by(attributes, &block); end
|
929
|
-
|
930
|
-
sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: Wizard).void)).returns(Wizard) }
|
931
|
-
def find_or_create_by!(attributes, &block); end
|
932
|
-
|
933
|
-
sig { returns(T.nilable(Wizard)) }
|
934
|
-
def first; end
|
935
|
-
|
936
|
-
sig { returns(Wizard) }
|
937
|
-
def first!; end
|
938
|
-
|
939
|
-
sig { returns(T.nilable(Wizard)) }
|
940
|
-
def second; end
|
941
|
-
|
942
|
-
sig { returns(Wizard) }
|
943
|
-
def second!; end
|
944
|
-
|
945
|
-
sig { returns(T.nilable(Wizard)) }
|
946
|
-
def third; end
|
947
|
-
|
948
|
-
sig { returns(Wizard) }
|
949
|
-
def third!; end
|
950
|
-
|
951
|
-
sig { returns(T.nilable(Wizard)) }
|
952
|
-
def third_to_last; end
|
953
|
-
|
954
|
-
sig { returns(Wizard) }
|
955
|
-
def third_to_last!; end
|
956
|
-
|
957
|
-
sig { returns(T.nilable(Wizard)) }
|
958
|
-
def second_to_last; end
|
959
|
-
|
960
|
-
sig { returns(Wizard) }
|
961
|
-
def second_to_last!; end
|
962
|
-
|
963
|
-
sig { returns(T.nilable(Wizard)) }
|
964
|
-
def last; end
|
965
|
-
|
966
|
-
sig { returns(Wizard) }
|
967
|
-
def last!; end
|
968
|
-
|
969
|
-
sig { params(conditions: T.untyped).returns(T::Boolean) }
|
970
|
-
def exists?(conditions = nil); end
|
971
|
-
|
972
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
973
|
-
def any?(*args); end
|
974
|
-
|
975
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
976
|
-
def many?(*args); end
|
977
|
-
|
978
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
979
|
-
def none?(*args); end
|
980
|
-
|
981
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
982
|
-
def one?(*args); end
|
983
|
-
|
984
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
985
|
-
def empty?(*args); end
|
986
|
-
|
987
|
-
sig { override.params(block: T.proc.params(e: Wizard).void).returns(T::Array[Wizard]) }
|
988
|
-
def each(&block); end
|
989
|
-
|
990
|
-
sig { params(level: T.nilable(Integer)).returns(T::Array[Wizard]) }
|
991
|
-
def flatten(level); end
|
992
|
-
|
993
|
-
sig { returns(T::Array[Wizard]) }
|
994
|
-
def to_a; end
|
995
|
-
|
996
793
|
sig do
|
997
|
-
|
998
|
-
|
999
|
-
|
1000
|
-
|
794
|
+
params(
|
795
|
+
of: T.nilable(Integer),
|
796
|
+
start: T.nilable(Integer),
|
797
|
+
finish: T.nilable(Integer),
|
798
|
+
load: T.nilable(T::Boolean),
|
799
|
+
error_on_ignore: T.nilable(T::Boolean),
|
800
|
+
block: T.nilable(T.proc.params(e: Wizard::ActiveRecord_Relation).void)
|
801
|
+
).returns(ActiveRecord::Batches::BatchEnumerator)
|
1001
802
|
end
|
1002
|
-
def
|
803
|
+
def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, &block); end
|
1003
804
|
end
|
1004
805
|
|
1005
|
-
|
1006
|
-
include Wizard::CustomFinderMethods
|
1007
|
-
include Enumerable
|
1008
|
-
extend T::Sig
|
1009
|
-
extend T::Generic
|
1010
|
-
Elem = type_member(fixed: Wizard)
|
1011
|
-
|
1012
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1013
|
-
def Gryffindor(*args); end
|
1014
|
-
|
1015
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1016
|
-
def Hagrid(*args); end
|
1017
|
-
|
1018
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1019
|
-
def Hufflepuff(*args); end
|
1020
|
-
|
1021
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1022
|
-
def Ravenclaw(*args); end
|
1023
|
-
|
1024
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1025
|
-
def Slytherin(*args); end
|
1026
|
-
|
1027
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1028
|
-
def black_hair(*args); end
|
1029
|
-
|
1030
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1031
|
-
def blonde_hair(*args); end
|
1032
|
-
|
1033
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1034
|
-
def broom_firebolt(*args); end
|
1035
|
-
|
1036
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1037
|
-
def broom_nimbus(*args); end
|
1038
|
-
|
1039
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1040
|
-
def brown_hair(*args); end
|
1041
|
-
|
1042
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1043
|
-
def color_blue_eyes(*args); end
|
1044
|
-
|
1045
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1046
|
-
def color_brown_eyes(*args); end
|
1047
|
-
|
1048
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1049
|
-
def color_green_eyes(*args); end
|
1050
|
-
|
1051
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1052
|
-
def quidditch_beater(*args); end
|
1053
|
-
|
1054
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1055
|
-
def quidditch_chaser(*args); end
|
1056
|
-
|
1057
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1058
|
-
def quidditch_keeper(*args); end
|
1059
|
-
|
1060
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1061
|
-
def quidditch_seeker(*args); end
|
1062
|
-
|
1063
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1064
|
-
def recent(*args); end
|
1065
|
-
|
1066
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1067
|
-
def with_attached_hats(*args); end
|
1068
|
-
|
1069
|
-
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1070
|
-
def with_attached_school_photo(*args); end
|
1071
|
-
|
806
|
+
module Wizard::QueryMethodsReturningAssociationRelation
|
1072
807
|
sig { returns(Wizard::ActiveRecord_AssociationRelation) }
|
1073
808
|
def all; end
|
1074
809
|
|
1075
|
-
sig { params(block: T.nilable(T.proc.void)).returns(Wizard::
|
810
|
+
sig { params(block: T.nilable(T.proc.void)).returns(Wizard::ActiveRecord_Relation) }
|
1076
811
|
def unscoped(&block); end
|
1077
812
|
|
1078
813
|
sig { params(args: T.untyped).returns(Wizard::ActiveRecord_AssociationRelation) }
|
@@ -1156,104 +891,15 @@ class Wizard::ActiveRecord_Associations_CollectionProxy < ActiveRecord::Associat
|
|
1156
891
|
sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Wizard::ActiveRecord_AssociationRelation) }
|
1157
892
|
def extending(*args, &block); end
|
1158
893
|
|
1159
|
-
sig { params(args: T.untyped).returns(Wizard) }
|
1160
|
-
def find(*args); end
|
1161
|
-
|
1162
|
-
sig { params(args: T.untyped).returns(T.nilable(Wizard)) }
|
1163
|
-
def find_by(*args); end
|
1164
|
-
|
1165
|
-
sig { params(args: T.untyped).returns(Wizard) }
|
1166
|
-
def find_by!(*args); end
|
1167
|
-
|
1168
|
-
sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: Wizard).void)).returns(Wizard) }
|
1169
|
-
def find_or_initialize_by(attributes, &block); end
|
1170
|
-
|
1171
|
-
sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: Wizard).void)).returns(Wizard) }
|
1172
|
-
def find_or_create_by(attributes, &block); end
|
1173
|
-
|
1174
|
-
sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: Wizard).void)).returns(Wizard) }
|
1175
|
-
def find_or_create_by!(attributes, &block); end
|
1176
|
-
|
1177
|
-
sig { returns(T.nilable(Wizard)) }
|
1178
|
-
def first; end
|
1179
|
-
|
1180
|
-
sig { returns(Wizard) }
|
1181
|
-
def first!; end
|
1182
|
-
|
1183
|
-
sig { returns(T.nilable(Wizard)) }
|
1184
|
-
def second; end
|
1185
|
-
|
1186
|
-
sig { returns(Wizard) }
|
1187
|
-
def second!; end
|
1188
|
-
|
1189
|
-
sig { returns(T.nilable(Wizard)) }
|
1190
|
-
def third; end
|
1191
|
-
|
1192
|
-
sig { returns(Wizard) }
|
1193
|
-
def third!; end
|
1194
|
-
|
1195
|
-
sig { returns(T.nilable(Wizard)) }
|
1196
|
-
def third_to_last; end
|
1197
|
-
|
1198
|
-
sig { returns(Wizard) }
|
1199
|
-
def third_to_last!; end
|
1200
|
-
|
1201
|
-
sig { returns(T.nilable(Wizard)) }
|
1202
|
-
def second_to_last; end
|
1203
|
-
|
1204
|
-
sig { returns(Wizard) }
|
1205
|
-
def second_to_last!; end
|
1206
|
-
|
1207
|
-
sig { returns(T.nilable(Wizard)) }
|
1208
|
-
def last; end
|
1209
|
-
|
1210
|
-
sig { returns(Wizard) }
|
1211
|
-
def last!; end
|
1212
|
-
|
1213
|
-
sig { params(conditions: T.untyped).returns(T::Boolean) }
|
1214
|
-
def exists?(conditions = nil); end
|
1215
|
-
|
1216
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
1217
|
-
def any?(*args); end
|
1218
|
-
|
1219
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
1220
|
-
def many?(*args); end
|
1221
|
-
|
1222
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
1223
|
-
def none?(*args); end
|
1224
|
-
|
1225
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
1226
|
-
def one?(*args); end
|
1227
|
-
|
1228
|
-
sig { params(args: T.untyped).returns(T::Boolean) }
|
1229
|
-
def empty?(*args); end
|
1230
|
-
|
1231
|
-
sig { override.params(block: T.proc.params(e: Wizard).void).returns(T::Array[Wizard]) }
|
1232
|
-
def each(&block); end
|
1233
|
-
|
1234
|
-
sig { params(level: T.nilable(Integer)).returns(T::Array[Wizard]) }
|
1235
|
-
def flatten(level); end
|
1236
|
-
|
1237
|
-
sig { returns(T::Array[Wizard]) }
|
1238
|
-
def to_a; end
|
1239
|
-
|
1240
894
|
sig do
|
1241
|
-
|
1242
|
-
|
1243
|
-
|
1244
|
-
|
895
|
+
params(
|
896
|
+
of: T.nilable(Integer),
|
897
|
+
start: T.nilable(Integer),
|
898
|
+
finish: T.nilable(Integer),
|
899
|
+
load: T.nilable(T::Boolean),
|
900
|
+
error_on_ignore: T.nilable(T::Boolean),
|
901
|
+
block: T.nilable(T.proc.params(e: Wizard::ActiveRecord_AssociationRelation).void)
|
902
|
+
).returns(ActiveRecord::Batches::BatchEnumerator)
|
1245
903
|
end
|
1246
|
-
def
|
1247
|
-
|
1248
|
-
sig { params(records: T.any(Wizard, T::Array[Wizard])).returns(T.self_type) }
|
1249
|
-
def <<(*records); end
|
1250
|
-
|
1251
|
-
sig { params(records: T.any(Wizard, T::Array[Wizard])).returns(T.self_type) }
|
1252
|
-
def append(*records); end
|
1253
|
-
|
1254
|
-
sig { params(records: T.any(Wizard, T::Array[Wizard])).returns(T.self_type) }
|
1255
|
-
def push(*records); end
|
1256
|
-
|
1257
|
-
sig { params(records: T.any(Wizard, T::Array[Wizard])).returns(T.self_type) }
|
1258
|
-
def concat(*records); end
|
904
|
+
def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, &block); end
|
1259
905
|
end
|