packwerk 1.1.2 → 1.1.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ci.yml +14 -5
  3. data/.ruby-version +1 -1
  4. data/Gemfile +1 -1
  5. data/Gemfile.lock +127 -110
  6. data/README.md +7 -0
  7. data/dev.yml +1 -1
  8. data/gemfiles/Gemfile-rails-6-0 +22 -0
  9. data/lib/packwerk.rb +1 -0
  10. data/lib/packwerk/application_validator.rb +5 -5
  11. data/lib/packwerk/node_processor.rb +2 -1
  12. data/lib/packwerk/node_visitor.rb +1 -1
  13. data/lib/packwerk/version.rb +1 -1
  14. data/library.yml +1 -1
  15. data/service.yml +2 -2
  16. data/shipit.rubygems.yml +5 -1
  17. data/sorbet/rbi/gems/{actioncable@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → actioncable@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +56 -36
  18. data/sorbet/rbi/gems/{actionmailbox@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → actionmailbox@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +25 -28
  19. data/sorbet/rbi/gems/{actionmailer@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → actionmailer@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +43 -24
  20. data/sorbet/rbi/gems/{actionpack@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → actionpack@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +382 -284
  21. data/sorbet/rbi/gems/{actiontext@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → actiontext@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +76 -40
  22. data/sorbet/rbi/gems/{actionview@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → actionview@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +206 -195
  23. data/sorbet/rbi/gems/{activejob@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → activejob@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +64 -75
  24. data/sorbet/rbi/gems/{activemodel@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → activemodel@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +103 -56
  25. data/sorbet/rbi/gems/{activerecord@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → activerecord@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +1250 -898
  26. data/sorbet/rbi/gems/{activestorage@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → activestorage@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +92 -120
  27. data/sorbet/rbi/gems/{activesupport@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → activesupport@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +292 -193
  28. data/sorbet/rbi/gems/{ast@2.4.1.rbi → ast@2.4.2.rbi} +2 -1
  29. data/sorbet/rbi/gems/{better_html@1.0.15.rbi → better_html@1.0.16.rbi} +2 -2
  30. data/sorbet/rbi/gems/{concurrent-ruby@1.1.6.rbi → concurrent-ruby@1.1.8.rbi} +12 -9
  31. data/sorbet/rbi/gems/{erubi@1.9.0.rbi → erubi@1.10.0.rbi} +3 -1
  32. data/sorbet/rbi/gems/{i18n@1.8.2.rbi → i18n@1.8.10.rbi} +19 -52
  33. data/sorbet/rbi/gems/{loofah@2.5.0.rbi → loofah@2.9.0.rbi} +3 -1
  34. data/sorbet/rbi/gems/marcel@1.0.0.rbi +70 -0
  35. data/sorbet/rbi/gems/{mini_mime@1.0.2.rbi → mini_mime@1.0.3.rbi} +6 -6
  36. data/sorbet/rbi/gems/{mini_portile2@2.4.0.rbi → minitest-focus@1.2.1.rbi} +2 -2
  37. data/sorbet/rbi/gems/{minitest@5.14.0.rbi → minitest@5.14.4.rbi} +31 -29
  38. data/sorbet/rbi/gems/{mocha@1.11.2.rbi → mocha@1.12.0.rbi} +25 -36
  39. data/sorbet/rbi/gems/{nio4r@2.5.2.rbi → nio4r@2.5.7.rbi} +21 -20
  40. data/sorbet/rbi/gems/{nokogiri@1.10.9.rbi → nokogiri@1.11.2.rbi} +193 -154
  41. data/sorbet/rbi/gems/{parallel@1.19.1.rbi → parallel@1.20.1.rbi} +1 -1
  42. data/sorbet/rbi/gems/parlour@6.0.0.rbi +1272 -0
  43. data/sorbet/rbi/gems/{parser@2.7.1.4.rbi → parser@3.0.0.0.rbi} +287 -174
  44. data/sorbet/rbi/gems/{pry@0.13.1.rbi → pry@0.14.0.rbi} +1 -1
  45. data/sorbet/rbi/gems/racc@1.5.2.rbi +57 -0
  46. data/sorbet/rbi/gems/{rack@2.2.2.rbi → rack@2.2.3.rbi} +23 -35
  47. data/sorbet/rbi/gems/{rails@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → rails@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +1 -1
  48. data/sorbet/rbi/gems/{railties@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi → railties@7.0.0.alpha-d612542336d9a61381311c95a27d801bb4094779.rbi} +132 -121
  49. data/sorbet/rbi/gems/{rake@13.0.1.rbi → rake@13.0.3.rbi} +16 -20
  50. data/sorbet/rbi/gems/regexp_parser@2.1.1.rbi +8 -0
  51. data/sorbet/rbi/gems/rubocop-ast@1.4.1.rbi +8 -0
  52. data/sorbet/rbi/gems/{rubocop-performance@1.5.2.rbi → rubocop-performance@1.10.2.rbi} +1 -1
  53. data/sorbet/rbi/gems/{rubocop-shopify@1.0.2.rbi → rubocop-shopify@2.0.1.rbi} +1 -1
  54. data/sorbet/rbi/gems/{rubocop-sorbet@0.3.7.rbi → rubocop-sorbet@0.6.1.rbi} +1 -1
  55. data/sorbet/rbi/gems/{rubocop@0.82.0.rbi → rubocop@1.12.0.rbi} +1 -1
  56. data/sorbet/rbi/gems/{ruby-progressbar@1.10.1.rbi → ruby-progressbar@1.11.0.rbi} +1 -1
  57. data/sorbet/rbi/gems/spoom@1.1.0.rbi +1061 -0
  58. data/sorbet/rbi/gems/{spring@2.1.0.rbi → spring@2.1.1.rbi} +7 -7
  59. data/sorbet/rbi/gems/{sprockets-rails@3.2.1.rbi → sprockets-rails@3.2.2.rbi} +88 -68
  60. data/sorbet/rbi/gems/{sprockets@4.0.0.rbi → sprockets@4.0.2.rbi} +8 -7
  61. data/sorbet/rbi/gems/{tapioca@0.4.5.rbi → tapioca@0.4.19.rbi} +109 -24
  62. data/sorbet/rbi/gems/{thor@1.0.1.rbi → thor@1.1.0.rbi} +16 -15
  63. data/sorbet/rbi/gems/{tzinfo@2.0.2.rbi → tzinfo@2.0.4.rbi} +21 -2
  64. data/sorbet/rbi/gems/{unicode-display_width@1.7.0.rbi → unicode-display_width@2.0.0.rbi} +1 -1
  65. data/sorbet/rbi/gems/{websocket-driver@0.7.1.rbi → websocket-driver@0.7.3.rbi} +29 -29
  66. data/sorbet/rbi/gems/{websocket-extensions@0.1.4.rbi → websocket-extensions@0.1.5.rbi} +2 -2
  67. data/sorbet/rbi/gems/zeitwerk@2.4.2.rbi +177 -0
  68. metadata +54 -52
  69. data/sorbet/rbi/gems/jaro_winkler@1.5.4.rbi +0 -8
  70. data/sorbet/rbi/gems/marcel@0.3.3.rbi +0 -30
  71. data/sorbet/rbi/gems/mimemagic@0.3.5.rbi +0 -47
  72. data/sorbet/rbi/gems/parlour@4.0.1.rbi +0 -561
  73. data/sorbet/rbi/gems/spoom@1.0.4.rbi +0 -418
  74. data/sorbet/rbi/gems/zeitwerk@2.3.0.rbi +0 -8
@@ -1,8 +0,0 @@
1
- # DO NOT EDIT MANUALLY
2
- # This is an autogenerated file for types exported from the `jaro_winkler` gem.
3
- # Please instead update this file by running `dev typecheck update`.
4
-
5
- # typed: true
6
-
7
- # THIS IS AN EMPTY RBI FILE.
8
- # see https://github.com/Shopify/tapioca/blob/master/README.md#manual-gem-requires
@@ -1,30 +0,0 @@
1
- # DO NOT EDIT MANUALLY
2
- # This is an autogenerated file for types exported from the `marcel` gem.
3
- # Please instead update this file by running `dev typecheck update`.
4
-
5
- # typed: true
6
-
7
- module Marcel
8
- end
9
-
10
- class Marcel::MimeType
11
- class << self
12
- def extend(type, extensions: T.unsafe(nil), parents: T.unsafe(nil), magic: T.unsafe(nil)); end
13
- def for(pathname_or_io = T.unsafe(nil), name: T.unsafe(nil), extension: T.unsafe(nil), declared_type: T.unsafe(nil)); end
14
-
15
- private
16
-
17
- def for_data(pathname_or_io); end
18
- def for_declared_type(declared_type); end
19
- def for_extension(extension); end
20
- def for_name(name); end
21
- def most_specific_type(from_magic_type, fallback_type); end
22
- def parse_media_type(content_type); end
23
- def root_types(type); end
24
- def with_io(pathname_or_io, &block); end
25
- end
26
- end
27
-
28
- Marcel::MimeType::BINARY = T.let(T.unsafe(nil), String)
29
-
30
- Marcel::VERSION = T.let(T.unsafe(nil), String)
@@ -1,47 +0,0 @@
1
- # DO NOT EDIT MANUALLY
2
- # This is an autogenerated file for types exported from the `mimemagic` gem.
3
- # Please instead update this file by running `dev typecheck update`.
4
-
5
- # typed: true
6
-
7
- class MimeMagic
8
- def initialize(type); end
9
-
10
- def ==(other); end
11
- def audio?; end
12
- def child_of?(parent); end
13
- def comment; end
14
- def eql?(other); end
15
- def extensions; end
16
- def hash; end
17
- def image?; end
18
- def mediatype; end
19
- def subtype; end
20
- def text?; end
21
- def to_s; end
22
- def type; end
23
- def video?; end
24
-
25
- class << self
26
- def add(type, options); end
27
- def all_by_magic(io); end
28
- def by_extension(ext); end
29
- def by_magic(io); end
30
- def by_path(path); end
31
- def child?(child, parent); end
32
- def remove(type); end
33
-
34
- private
35
-
36
- def magic_match(io, method); end
37
- def magic_match_io(io, matches, buffer); end
38
- end
39
- end
40
-
41
- MimeMagic::EXTENSIONS = T.let(T.unsafe(nil), Hash)
42
-
43
- MimeMagic::MAGIC = T.let(T.unsafe(nil), Array)
44
-
45
- MimeMagic::TYPES = T.let(T.unsafe(nil), Hash)
46
-
47
- MimeMagic::VERSION = T.let(T.unsafe(nil), String)
@@ -1,561 +0,0 @@
1
- # DO NOT EDIT MANUALLY
2
- # This is an autogenerated file for types exported from the `parlour` gem.
3
- # Please instead update this file by running `dev typecheck update`.
4
-
5
- # typed: true
6
-
7
- module Parlour
8
- end
9
-
10
- class Parlour::ConflictResolver
11
- sig { params(namespace: Parlour::RbiGenerator::Namespace, resolver: T.proc.params(desc: String, choices: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T.nilable(Parlour::RbiGenerator::RbiObject))).void }
12
- def resolve_conflicts(namespace, &resolver); end
13
-
14
- private
15
-
16
- sig { params(arr: T::Array[T.untyped]).returns(T::Boolean) }
17
- def all_eql?(arr); end
18
- sig { params(namespace: Parlour::RbiGenerator::Namespace, name: T.nilable(String)).void }
19
- def deduplicate_mixins_of_name(namespace, name); end
20
- sig { params(arr: T::Array[T.untyped]).returns(T.nilable(Symbol)) }
21
- def merge_strategy(arr); end
22
- end
23
-
24
- module Parlour::Debugging
25
- class << self
26
- sig { params(value: T::Boolean).returns(T::Boolean) }
27
- def debug_mode=(value); end
28
- sig { returns(T::Boolean) }
29
- def debug_mode?; end
30
- sig { params(object: T.untyped, message: String).void }
31
- def debug_puts(object, message); end
32
- sig { params(object: T.untyped).returns(String) }
33
- def name_for_debug_caller(object); end
34
- end
35
- end
36
-
37
- module Parlour::Debugging::Tree
38
- class << self
39
- sig { params(message: String).returns(String) }
40
- def begin(message); end
41
- sig { params(message: String).returns(String) }
42
- def end(message); end
43
- sig { params(message: String).returns(String) }
44
- def here(message); end
45
- def line_prefix; end
46
- def text_prefix; end
47
- end
48
- end
49
-
50
- Parlour::Debugging::Tree::INDENT_SPACES = T.let(T.unsafe(nil), Integer)
51
-
52
- class Parlour::DetachedRbiGenerator < ::Parlour::RbiGenerator
53
- sig { override.returns(T.nilable(Parlour::Plugin)) }
54
- def current_plugin; end
55
- sig { returns(T.untyped) }
56
- def detached!; end
57
- sig { override.returns(Parlour::RbiGenerator::Options) }
58
- def options; end
59
- sig { override.params(strictness: String).returns(String) }
60
- def rbi(strictness = T.unsafe(nil)); end
61
- end
62
-
63
- class Parlour::ParseError < ::StandardError
64
- def initialize(buffer, range); end
65
-
66
- sig { returns(Parser::Source::Buffer) }
67
- def buffer; end
68
- sig { returns(Parser::Source::Range) }
69
- def range; end
70
- end
71
-
72
- class Parlour::Plugin
73
- abstract!
74
-
75
- sig { params(options: T::Hash[T.untyped, T.untyped]).void }
76
- def initialize(options); end
77
-
78
- sig { abstract.params(root: Parlour::RbiGenerator::Namespace).void }
79
- def generate(root); end
80
- sig { returns(T.nilable(String)) }
81
- def strictness; end
82
- def strictness=(_); end
83
-
84
- class << self
85
- sig { params(new_plugin: T.class_of(Parlour::Plugin)).void }
86
- def inherited(new_plugin); end
87
- sig { returns(T::Hash[String, T.class_of(Parlour::Plugin)]) }
88
- def registered_plugins; end
89
- sig { params(plugins: T::Array[Parlour::Plugin], generator: Parlour::RbiGenerator, allow_failure: T::Boolean).void }
90
- def run_plugins(plugins, generator, allow_failure: T.unsafe(nil)); end
91
- end
92
- end
93
-
94
- class Parlour::RbiGenerator
95
- sig { params(break_params: Integer, tab_size: Integer, sort_namespaces: T::Boolean).void }
96
- def initialize(break_params: T.unsafe(nil), tab_size: T.unsafe(nil), sort_namespaces: T.unsafe(nil)); end
97
-
98
- sig { overridable.returns(T.nilable(Parlour::Plugin)) }
99
- def current_plugin; end
100
- def current_plugin=(_); end
101
- sig { overridable.returns(Parlour::RbiGenerator::Options) }
102
- def options; end
103
- sig { overridable.params(strictness: String).returns(String) }
104
- def rbi(strictness = T.unsafe(nil)); end
105
- sig { overridable.returns(Parlour::RbiGenerator::Namespace) }
106
- def root; end
107
- end
108
-
109
- class Parlour::RbiGenerator::Arbitrary < ::Parlour::RbiGenerator::RbiObject
110
- sig { params(generator: Parlour::RbiGenerator, code: String, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Arbitrary).void)).void }
111
- def initialize(generator, code: T.unsafe(nil), &block); end
112
-
113
- sig { params(other: Object).returns(T::Boolean) }
114
- def ==(other); end
115
- sig { returns(String) }
116
- def code; end
117
- def code=(_); end
118
- sig { override.returns(String) }
119
- def describe; end
120
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
121
- def generate_rbi(indent_level, options); end
122
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
123
- def merge_into_self(others); end
124
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
125
- def mergeable?(others); end
126
- end
127
-
128
- class Parlour::RbiGenerator::Attribute < ::Parlour::RbiGenerator::Method
129
- sig { params(generator: Parlour::RbiGenerator, name: String, kind: Symbol, type: String, class_attribute: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Attribute).void)).void }
130
- def initialize(generator, name, kind, type, class_attribute: T.unsafe(nil), &block); end
131
-
132
- sig { override.params(other: Object).returns(T::Boolean) }
133
- def ==(other); end
134
- sig { returns(T::Boolean) }
135
- def class_attribute; end
136
- sig { returns(Symbol) }
137
- def kind; end
138
-
139
- private
140
-
141
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
142
- def generate_definition(indent_level, options); end
143
- end
144
-
145
- class Parlour::RbiGenerator::ClassNamespace < ::Parlour::RbiGenerator::Namespace
146
- sig { params(generator: Parlour::RbiGenerator, name: String, final: T::Boolean, superclass: T.nilable(String), abstract: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::ClassNamespace).void)).void }
147
- def initialize(generator, name, final, superclass, abstract, &block); end
148
-
149
- sig { returns(T::Boolean) }
150
- def abstract; end
151
- sig { override.returns(String) }
152
- def describe; end
153
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
154
- def generate_rbi(indent_level, options); end
155
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
156
- def merge_into_self(others); end
157
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
158
- def mergeable?(others); end
159
- sig { returns(T.nilable(String)) }
160
- def superclass; end
161
- end
162
-
163
- class Parlour::RbiGenerator::Constant < ::Parlour::RbiGenerator::RbiObject
164
- sig { params(generator: Parlour::RbiGenerator, name: String, value: String, eigen_constant: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Constant).void)).void }
165
- def initialize(generator, name: T.unsafe(nil), value: T.unsafe(nil), eigen_constant: T.unsafe(nil), &block); end
166
-
167
- sig { params(other: Object).returns(T::Boolean) }
168
- def ==(other); end
169
- sig { override.returns(String) }
170
- def describe; end
171
- def eigen_constant; end
172
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
173
- def generate_rbi(indent_level, options); end
174
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
175
- def merge_into_self(others); end
176
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
177
- def mergeable?(others); end
178
- sig { returns(String) }
179
- def value; end
180
- end
181
-
182
- class Parlour::RbiGenerator::EnumClassNamespace < ::Parlour::RbiGenerator::ClassNamespace
183
- sig { params(generator: Parlour::RbiGenerator, name: String, final: T::Boolean, enums: T::Array[T.any(String, [String, String])], abstract: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::EnumClassNamespace).void)).void }
184
- def initialize(generator, name, final, enums, abstract, &block); end
185
-
186
- sig { returns(T::Array[T.any(String, [String, String])]) }
187
- def enums; end
188
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
189
- def generate_body(indent_level, options); end
190
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
191
- def merge_into_self(others); end
192
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
193
- def mergeable?(others); end
194
- end
195
-
196
- class Parlour::RbiGenerator::Extend < ::Parlour::RbiGenerator::RbiObject
197
- sig { params(generator: Parlour::RbiGenerator, name: String, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Extend).void)).void }
198
- def initialize(generator, name: T.unsafe(nil), &block); end
199
-
200
- sig { params(other: Object).returns(T::Boolean) }
201
- def ==(other); end
202
- sig { override.returns(String) }
203
- def describe; end
204
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
205
- def generate_rbi(indent_level, options); end
206
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
207
- def merge_into_self(others); end
208
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
209
- def mergeable?(others); end
210
- end
211
-
212
- class Parlour::RbiGenerator::Include < ::Parlour::RbiGenerator::RbiObject
213
- sig { params(generator: Parlour::RbiGenerator, name: String, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Include).void)).void }
214
- def initialize(generator, name: T.unsafe(nil), &block); end
215
-
216
- sig { params(other: Object).returns(T::Boolean) }
217
- def ==(other); end
218
- sig { override.returns(String) }
219
- def describe; end
220
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
221
- def generate_rbi(indent_level, options); end
222
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
223
- def merge_into_self(others); end
224
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
225
- def mergeable?(others); end
226
- end
227
-
228
- class Parlour::RbiGenerator::Method < ::Parlour::RbiGenerator::RbiObject
229
- sig { params(generator: Parlour::RbiGenerator, name: String, parameters: T::Array[Parlour::RbiGenerator::Parameter], return_type: T.nilable(String), abstract: T::Boolean, implementation: T::Boolean, override: T::Boolean, overridable: T::Boolean, class_method: T::Boolean, final: T::Boolean, type_parameters: T.nilable(T::Array[Symbol]), block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Method).void)).void }
230
- def initialize(generator, name, parameters, return_type = T.unsafe(nil), abstract: T.unsafe(nil), implementation: T.unsafe(nil), override: T.unsafe(nil), overridable: T.unsafe(nil), class_method: T.unsafe(nil), final: T.unsafe(nil), type_parameters: T.unsafe(nil), &block); end
231
-
232
- sig { overridable.params(other: Object).returns(T::Boolean) }
233
- def ==(other); end
234
- sig { returns(T::Boolean) }
235
- def abstract; end
236
- sig { returns(T::Boolean) }
237
- def class_method; end
238
- sig { override.returns(String) }
239
- def describe; end
240
- sig { returns(T::Boolean) }
241
- def final; end
242
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
243
- def generate_rbi(indent_level, options); end
244
- sig { returns(T::Boolean) }
245
- def implementation; end
246
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
247
- def merge_into_self(others); end
248
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
249
- def mergeable?(others); end
250
- sig { returns(T::Boolean) }
251
- def overridable; end
252
- sig { returns(T::Boolean) }
253
- def override; end
254
- sig { returns(T::Array[Parlour::RbiGenerator::Parameter]) }
255
- def parameters; end
256
- sig { returns(T.nilable(String)) }
257
- def return_type; end
258
- sig { returns(T::Array[Symbol]) }
259
- def type_parameters; end
260
-
261
- private
262
-
263
- sig { overridable.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
264
- def generate_definition(indent_level, options); end
265
- sig { returns(String) }
266
- def qualifiers; end
267
- end
268
-
269
- class Parlour::RbiGenerator::ModuleNamespace < ::Parlour::RbiGenerator::Namespace
270
- sig { params(generator: Parlour::RbiGenerator, name: String, final: T::Boolean, interface: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::ClassNamespace).void)).void }
271
- def initialize(generator, name, final, interface, &block); end
272
-
273
- sig { override.returns(String) }
274
- def describe; end
275
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
276
- def generate_rbi(indent_level, options); end
277
- sig { returns(T::Boolean) }
278
- def interface; end
279
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
280
- def merge_into_self(others); end
281
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
282
- def mergeable?(others); end
283
- end
284
-
285
- class Parlour::RbiGenerator::Namespace < ::Parlour::RbiGenerator::RbiObject
286
- sig { params(generator: Parlour::RbiGenerator, name: T.nilable(String), final: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Namespace).void)).void }
287
- def initialize(generator, name = T.unsafe(nil), final = T.unsafe(nil), &block); end
288
-
289
- sig { params(comment: T.any(String, T::Array[String])).void }
290
- def add_comment_to_next_child(comment); end
291
- sig { returns(T::Array[Parlour::RbiGenerator::RbiObject]) }
292
- def children; end
293
- sig { returns(T::Array[Parlour::RbiGenerator::Constant]) }
294
- def constants; end
295
- def create_arbitrary(code:, &block); end
296
- def create_attr(*args, &blk); end
297
- sig { params(name: String, type: String, class_attribute: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Attribute).void)).returns(Parlour::RbiGenerator::Attribute) }
298
- def create_attr_accessor(name, type:, class_attribute: T.unsafe(nil), &block); end
299
- sig { params(name: String, type: String, class_attribute: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Attribute).void)).returns(Parlour::RbiGenerator::Attribute) }
300
- def create_attr_reader(name, type:, class_attribute: T.unsafe(nil), &block); end
301
- sig { params(name: String, type: String, class_attribute: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Attribute).void)).returns(Parlour::RbiGenerator::Attribute) }
302
- def create_attr_writer(name, type:, class_attribute: T.unsafe(nil), &block); end
303
- sig { params(name: String, kind: Symbol, type: String, class_attribute: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Attribute).void)).returns(Parlour::RbiGenerator::Attribute) }
304
- def create_attribute(name, kind:, type:, class_attribute: T.unsafe(nil), &block); end
305
- sig { params(name: String, final: T::Boolean, superclass: T.nilable(String), abstract: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::ClassNamespace).void)).returns(Parlour::RbiGenerator::ClassNamespace) }
306
- def create_class(name, final: T.unsafe(nil), superclass: T.unsafe(nil), abstract: T.unsafe(nil), &block); end
307
- sig { params(name: String, value: String, eigen_constant: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Constant).void)).returns(Parlour::RbiGenerator::Constant) }
308
- def create_constant(name, value:, eigen_constant: T.unsafe(nil), &block); end
309
- sig { params(name: String, final: T::Boolean, enums: T.nilable(T::Array[T.any(String, [String, String])]), abstract: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::EnumClassNamespace).void)).returns(Parlour::RbiGenerator::EnumClassNamespace) }
310
- def create_enum_class(name, final: T.unsafe(nil), enums: T.unsafe(nil), abstract: T.unsafe(nil), &block); end
311
- sig { params(name: String, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Extend).void)).returns(Parlour::RbiGenerator::Extend) }
312
- def create_extend(name, &block); end
313
- sig { params(extendables: T::Array[String]).returns(T::Array[Parlour::RbiGenerator::Extend]) }
314
- def create_extends(extendables); end
315
- sig { params(name: String, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Include).void)).returns(Parlour::RbiGenerator::Include) }
316
- def create_include(name, &block); end
317
- sig { params(includables: T::Array[String]).returns(T::Array[Parlour::RbiGenerator::Include]) }
318
- def create_includes(includables); end
319
- sig { params(name: String, parameters: T.nilable(T::Array[Parlour::RbiGenerator::Parameter]), return_type: T.nilable(String), returns: T.nilable(String), abstract: T::Boolean, implementation: T::Boolean, override: T::Boolean, overridable: T::Boolean, class_method: T::Boolean, final: T::Boolean, type_parameters: T.nilable(T::Array[Symbol]), block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Method).void)).returns(Parlour::RbiGenerator::Method) }
320
- def create_method(name, parameters: T.unsafe(nil), return_type: T.unsafe(nil), returns: T.unsafe(nil), abstract: T.unsafe(nil), implementation: T.unsafe(nil), override: T.unsafe(nil), overridable: T.unsafe(nil), class_method: T.unsafe(nil), final: T.unsafe(nil), type_parameters: T.unsafe(nil), &block); end
321
- sig { params(name: String, final: T::Boolean, interface: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::ClassNamespace).void)).returns(Parlour::RbiGenerator::ModuleNamespace) }
322
- def create_module(name, final: T.unsafe(nil), interface: T.unsafe(nil), &block); end
323
- sig { params(name: String, final: T::Boolean, props: T.nilable(T::Array[Parlour::RbiGenerator::StructProp]), abstract: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::StructClassNamespace).void)).returns(Parlour::RbiGenerator::StructClassNamespace) }
324
- def create_struct_class(name, final: T.unsafe(nil), props: T.unsafe(nil), abstract: T.unsafe(nil), &block); end
325
- sig { params(name: String, type: String, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::Constant).void)).returns(Parlour::RbiGenerator::Constant) }
326
- def create_type_alias(name, type:, &block); end
327
- sig { overridable.override.returns(String) }
328
- def describe; end
329
- sig { returns(T::Array[Parlour::RbiGenerator::Extend]) }
330
- def extends; end
331
- sig { returns(T::Boolean) }
332
- def final; end
333
- sig { overridable.override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
334
- def generate_rbi(indent_level, options); end
335
- sig { returns(T::Array[Parlour::RbiGenerator::Include]) }
336
- def includes; end
337
- sig { overridable.override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
338
- def merge_into_self(others); end
339
- sig { overridable.override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
340
- def mergeable?(others); end
341
- sig { params(object: T.untyped, block: T.proc.params(x: Parlour::RbiGenerator::Namespace).void).void }
342
- def path(object, &block); end
343
-
344
- private
345
-
346
- sig { overridable.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
347
- def generate_body(indent_level, options); end
348
- sig { params(object: Parlour::RbiGenerator::RbiObject).void }
349
- def move_next_comments(object); end
350
- end
351
-
352
- class Parlour::RbiGenerator::Options
353
- sig { params(break_params: Integer, tab_size: Integer, sort_namespaces: T::Boolean).void }
354
- def initialize(break_params:, tab_size:, sort_namespaces:); end
355
-
356
- sig { returns(Integer) }
357
- def break_params; end
358
- sig { params(level: Integer, str: String).returns(String) }
359
- def indented(level, str); end
360
- sig { returns(T::Boolean) }
361
- def sort_namespaces; end
362
- sig { returns(Integer) }
363
- def tab_size; end
364
- end
365
-
366
- class Parlour::RbiGenerator::Parameter
367
- sig { params(name: String, type: T.nilable(String), default: T.nilable(String)).void }
368
- def initialize(name, type: T.unsafe(nil), default: T.unsafe(nil)); end
369
-
370
- sig { params(other: Object).returns(T::Boolean) }
371
- def ==(other); end
372
- sig { returns(T.nilable(String)) }
373
- def default; end
374
- sig { returns(Symbol) }
375
- def kind; end
376
- sig { returns(String) }
377
- def name; end
378
- sig { returns(String) }
379
- def name_without_kind; end
380
- sig { returns(String) }
381
- def to_def_param; end
382
- sig { returns(String) }
383
- def to_sig_param; end
384
- sig { returns(String) }
385
- def type; end
386
- end
387
-
388
- Parlour::RbiGenerator::Parameter::PREFIXES = T.let(T.unsafe(nil), Hash)
389
-
390
- class Parlour::RbiGenerator::RbiObject
391
- abstract!
392
-
393
- sig { params(generator: Parlour::RbiGenerator, name: String).void }
394
- def initialize(generator, name); end
395
-
396
- sig { params(comment: T.any(String, T::Array[String])).void }
397
- def add_comment(comment); end
398
- def add_comments(*args, &blk); end
399
- sig { returns(T::Array[String]) }
400
- def comments; end
401
- sig { abstract.returns(String) }
402
- def describe; end
403
- sig { abstract.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
404
- def generate_rbi(indent_level, options); end
405
- sig { returns(T.nilable(Parlour::Plugin)) }
406
- def generated_by; end
407
- sig { returns(Parlour::RbiGenerator) }
408
- def generator; end
409
- sig { abstract.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
410
- def merge_into_self(others); end
411
- sig { abstract.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
412
- def mergeable?(others); end
413
- sig { returns(String) }
414
- def name; end
415
-
416
- private
417
-
418
- sig { params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
419
- def generate_comments(indent_level, options); end
420
- end
421
-
422
- class Parlour::RbiGenerator::StructClassNamespace < ::Parlour::RbiGenerator::ClassNamespace
423
- sig { params(generator: Parlour::RbiGenerator, name: String, final: T::Boolean, props: T::Array[Parlour::RbiGenerator::StructProp], abstract: T::Boolean, block: T.nilable(T.proc.params(x: Parlour::RbiGenerator::StructClassNamespace).void)).void }
424
- def initialize(generator, name, final, props, abstract, &block); end
425
-
426
- sig { override.params(indent_level: Integer, options: Parlour::RbiGenerator::Options).returns(T::Array[String]) }
427
- def generate_body(indent_level, options); end
428
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).void }
429
- def merge_into_self(others); end
430
- sig { override.params(others: T::Array[Parlour::RbiGenerator::RbiObject]).returns(T::Boolean) }
431
- def mergeable?(others); end
432
- sig { returns(T::Array[Parlour::RbiGenerator::StructProp]) }
433
- def props; end
434
- end
435
-
436
- class Parlour::RbiGenerator::StructProp
437
- sig { params(name: String, type: String, optional: T.nilable(T.any(Symbol, T::Boolean)), enum: T.nilable(String), dont_store: T.nilable(T::Boolean), foreign: T.nilable(String), default: T.nilable(String), factory: T.nilable(String), immutable: T.nilable(T::Boolean), array: T.nilable(String), override: T.nilable(T::Boolean), redaction: T.nilable(String)).void }
438
- def initialize(name, type, optional: T.unsafe(nil), enum: T.unsafe(nil), dont_store: T.unsafe(nil), foreign: T.unsafe(nil), default: T.unsafe(nil), factory: T.unsafe(nil), immutable: T.unsafe(nil), array: T.unsafe(nil), override: T.unsafe(nil), redaction: T.unsafe(nil)); end
439
-
440
- sig { params(other: Object).returns(T::Boolean) }
441
- def ==(other); end
442
- sig { returns(T.nilable(String)) }
443
- def array; end
444
- sig { returns(T.nilable(String)) }
445
- def default; end
446
- sig { returns(T.nilable(T::Boolean)) }
447
- def dont_store; end
448
- sig { returns(T.nilable(String)) }
449
- def enum; end
450
- sig { returns(T.nilable(String)) }
451
- def factory; end
452
- sig { returns(T.nilable(String)) }
453
- def foreign; end
454
- sig { returns(T.nilable(T::Boolean)) }
455
- def immutable; end
456
- sig { returns(String) }
457
- def name; end
458
- sig { returns(T.nilable(T.any(Symbol, T::Boolean))) }
459
- def optional; end
460
- sig { returns(T.nilable(T::Boolean)) }
461
- def override; end
462
- sig { returns(T.nilable(String)) }
463
- def redaction; end
464
- sig { returns(String) }
465
- def to_prop_call; end
466
- sig { returns(T.nilable(String)) }
467
- def type; end
468
- end
469
-
470
- Parlour::RbiGenerator::StructProp::EXTRA_PROPERTIES = T.let(T.unsafe(nil), Array)
471
-
472
- module Parlour::TypeLoader
473
- class << self
474
- sig { params(filename: String, generator: T.nilable(Parlour::RbiGenerator)).returns(Parlour::RbiGenerator::Namespace) }
475
- def load_file(filename, generator: T.unsafe(nil)); end
476
- sig { params(root: String, inclusions: T::Array[String], exclusions: T::Array[String], generator: T.nilable(Parlour::RbiGenerator)).returns(Parlour::RbiGenerator::Namespace) }
477
- def load_project(root, inclusions: T.unsafe(nil), exclusions: T.unsafe(nil), generator: T.unsafe(nil)); end
478
- sig { params(source: String, filename: T.nilable(String), generator: T.nilable(Parlour::RbiGenerator)).returns(Parlour::RbiGenerator::Namespace) }
479
- def load_source(source, filename = T.unsafe(nil), generator: T.unsafe(nil)); end
480
- end
481
- end
482
-
483
- class Parlour::TypeParser
484
- sig { params(ast: Parser::AST::Node, unknown_node_errors: T::Boolean, generator: T.nilable(Parlour::RbiGenerator)).void }
485
- def initialize(ast, unknown_node_errors: T.unsafe(nil), generator: T.unsafe(nil)); end
486
-
487
- sig { returns(Parser::AST::Node) }
488
- def ast; end
489
- def ast=(_); end
490
- sig { returns(Parlour::RbiGenerator) }
491
- def generator; end
492
- def generator=(_); end
493
- sig { returns(Parlour::RbiGenerator::Namespace) }
494
- def parse_all; end
495
- sig { params(path: Parlour::TypeParser::NodePath, is_within_eigenclass: T::Boolean).returns(T::Array[Parlour::RbiGenerator::Method]) }
496
- def parse_method_into_methods(path, is_within_eigenclass: T.unsafe(nil)); end
497
- sig { params(path: Parlour::TypeParser::NodePath, is_within_eigenclass: T::Boolean).returns(T::Array[Parlour::RbiGenerator::RbiObject]) }
498
- def parse_path_to_object(path, is_within_eigenclass: T.unsafe(nil)); end
499
- sig { params(path: Parlour::TypeParser::NodePath, is_within_eigenclass: T::Boolean).returns(T::Array[Parlour::RbiGenerator::Method]) }
500
- def parse_sig_into_methods(path, is_within_eigenclass: T.unsafe(nil)); end
501
- sig { params(path: Parlour::TypeParser::NodePath).returns(Parlour::TypeParser::IntermediateSig) }
502
- def parse_sig_into_sig(path); end
503
- sig { returns(T::Boolean) }
504
- def unknown_node_errors; end
505
-
506
- protected
507
-
508
- sig { params(node: T.nilable(Parser::AST::Node), modifier: Symbol).returns(T::Boolean) }
509
- def body_has_modifier?(node, modifier); end
510
- sig { params(node: Parser::AST::Node).returns([T::Array[String], T::Array[String]]) }
511
- def body_includes_and_extends(node); end
512
- sig { params(node: T.nilable(Parser::AST::Node)).returns(T::Array[Symbol]) }
513
- def constant_names(node); end
514
- sig { params(node: T.nilable(Parser::AST::Node)).returns(T.nilable(String)) }
515
- def node_to_s(node); end
516
- sig { params(desc: String, node: T.any(Parlour::TypeParser::NodePath, Parser::AST::Node)).returns(T.noreturn) }
517
- def parse_err(desc, node); end
518
- sig { params(path: Parlour::TypeParser::NodePath).returns(T::Boolean) }
519
- def previous_sibling_sig_node?(path); end
520
- sig { params(node: Parser::AST::Node).returns(T::Boolean) }
521
- def sig_node?(node); end
522
- sig { type_parameters(:A, :B).params(a: T::Array[T.type_parameter(:A)], fa: T.proc.params(item: T.type_parameter(:A)).returns(T.untyped), b: T::Array[T.type_parameter(:B)], fb: T.proc.params(item: T.type_parameter(:B)).returns(T.untyped)).returns(T::Array[[T.type_parameter(:A), T.type_parameter(:B)]]) }
523
- def zip_by(a, fa, b, fb); end
524
-
525
- class << self
526
- sig { params(filename: String, source: String, generator: T.nilable(Parlour::RbiGenerator)).returns(Parlour::TypeParser) }
527
- def from_source(filename, source, generator: T.unsafe(nil)); end
528
- end
529
- end
530
-
531
- class Parlour::TypeParser::IntermediateSig < ::T::Struct
532
- prop :type_parameters, T.nilable(T::Array[Symbol])
533
- prop :overridable, T::Boolean
534
- prop :override, T::Boolean
535
- prop :abstract, T::Boolean
536
- prop :final, T::Boolean
537
- prop :return_type, T.nilable(String)
538
- prop :params, T.nilable(T::Array[Parser::AST::Node])
539
-
540
- class << self
541
- def inherited(s); end
542
- end
543
- end
544
-
545
- class Parlour::TypeParser::NodePath
546
- sig { params(indices: T::Array[Integer]).void }
547
- def initialize(indices); end
548
-
549
- sig { params(index: Integer).returns(Parlour::TypeParser::NodePath) }
550
- def child(index); end
551
- sig { returns(T::Array[Integer]) }
552
- def indices; end
553
- sig { returns(Parlour::TypeParser::NodePath) }
554
- def parent; end
555
- sig { params(offset: Integer).returns(Parlour::TypeParser::NodePath) }
556
- def sibling(offset); end
557
- sig { params(start: Parser::AST::Node).returns(Parser::AST::Node) }
558
- def traverse(start); end
559
- end
560
-
561
- Parlour::VERSION = T.let(T.unsafe(nil), String)