clean-architecture 2.0.0 → 3.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (118) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/rspec.yml +21 -0
  3. data/.gitignore +1 -0
  4. data/.ruby-version +1 -1
  5. data/CHANGELOG.md +42 -0
  6. data/Gemfile +1 -0
  7. data/README.md +423 -4
  8. data/clean-architecture.gemspec +9 -5
  9. data/generate_require_files.rb +1 -0
  10. data/lib/clean-architecture.rb +1 -0
  11. data/lib/clean_architecture/adapters/all.rb +1 -0
  12. data/lib/clean_architecture/adapters/attribute_hash_base.rb +1 -0
  13. data/lib/clean_architecture/all.rb +3 -0
  14. data/lib/clean_architecture/builders/abstract_active_record_entity_builder.rb +124 -0
  15. data/lib/clean_architecture/builders/all.rb +6 -0
  16. data/lib/clean_architecture/checks/all.rb +1 -0
  17. data/lib/clean_architecture/checks/authorization.rb +1 -0
  18. data/lib/clean_architecture/entities/all.rb +1 -0
  19. data/lib/clean_architecture/entities/failure_details.rb +2 -1
  20. data/lib/clean_architecture/entities/targeted_parameters.rb +1 -0
  21. data/lib/clean_architecture/entities/untargeted_parameters.rb +1 -0
  22. data/lib/clean_architecture/interfaces/all.rb +1 -0
  23. data/lib/clean_architecture/interfaces/authorization_parameters.rb +1 -0
  24. data/lib/clean_architecture/interfaces/base_parameters.rb +1 -0
  25. data/lib/clean_architecture/interfaces/jsonable.rb +1 -0
  26. data/lib/clean_architecture/interfaces/success_payload.rb +1 -0
  27. data/lib/clean_architecture/interfaces/targeted_parameters.rb +1 -0
  28. data/lib/clean_architecture/interfaces/use_case.rb +1 -0
  29. data/lib/clean_architecture/interfaces/use_case_actor.rb +1 -0
  30. data/lib/clean_architecture/interfaces/use_case_target.rb +1 -0
  31. data/lib/clean_architecture/matchers/all.rb +1 -0
  32. data/lib/clean_architecture/matchers/use_case_result.rb +1 -0
  33. data/lib/clean_architecture/queries/all.rb +1 -0
  34. data/lib/clean_architecture/queries/http_failure_code.rb +1 -0
  35. data/lib/clean_architecture/queries/http_success_code.rb +1 -0
  36. data/lib/clean_architecture/serializers/all.rb +1 -0
  37. data/lib/clean_architecture/serializers/html_response_from_result.rb +1 -0
  38. data/lib/clean_architecture/serializers/json_response_from_result.rb +1 -0
  39. data/lib/clean_architecture/serializers/success_collection_payload.rb +1 -0
  40. data/lib/clean_architecture/serializers/success_payload.rb +1 -0
  41. data/lib/clean_architecture/types.rb +2 -1
  42. data/lib/clean_architecture/use_cases/abstract_use_case.rb +62 -0
  43. data/lib/clean_architecture/use_cases/all.rb +10 -0
  44. data/lib/clean_architecture/use_cases/contract.rb +9 -0
  45. data/lib/clean_architecture/use_cases/errors.rb +57 -0
  46. data/lib/clean_architecture/use_cases/form.rb +116 -0
  47. data/lib/clean_architecture/use_cases/parameters.rb +42 -0
  48. data/lib/clean_architecture/version.rb +2 -1
  49. data/sorbet/config +2 -0
  50. data/sorbet/rbi/gems/activemodel.rbi +74 -0
  51. data/sorbet/rbi/gems/activesupport.rbi +440 -0
  52. data/sorbet/rbi/gems/ast.rbi +47 -0
  53. data/sorbet/rbi/gems/axiom-types.rbi +159 -0
  54. data/sorbet/rbi/gems/byebug.rbi +1039 -0
  55. data/sorbet/rbi/gems/codeclimate-engine-rb.rbi +123 -0
  56. data/sorbet/rbi/gems/coderay.rbi +91 -0
  57. data/sorbet/rbi/gems/coercible.rbi +156 -0
  58. data/sorbet/rbi/gems/concurrent-ruby.rbi +1587 -0
  59. data/sorbet/rbi/gems/descendants_tracker.rbi +17 -0
  60. data/sorbet/rbi/gems/docile.rbi +31 -0
  61. data/sorbet/rbi/gems/dry-configurable.rbi +89 -0
  62. data/sorbet/rbi/gems/dry-container.rbi +88 -0
  63. data/sorbet/rbi/gems/dry-core.rbi +79 -0
  64. data/sorbet/rbi/gems/dry-equalizer.rbi +25 -0
  65. data/sorbet/rbi/gems/dry-inflector.rbi +72 -0
  66. data/sorbet/rbi/gems/dry-initializer.rbi +209 -0
  67. data/sorbet/rbi/gems/dry-logic.rbi +304 -0
  68. data/sorbet/rbi/gems/dry-matcher.rbi +33 -0
  69. data/sorbet/rbi/gems/dry-monads.rbi +508 -0
  70. data/sorbet/rbi/gems/dry-schema.rbi +790 -0
  71. data/sorbet/rbi/gems/dry-struct.rbi +165 -0
  72. data/sorbet/rbi/gems/dry-types.rbi +688 -0
  73. data/sorbet/rbi/gems/dry-validation.rbi +284 -0
  74. data/sorbet/rbi/gems/duckface-interfaces.rbi +93 -0
  75. data/sorbet/rbi/gems/equalizer.rbi +22 -0
  76. data/sorbet/rbi/gems/i18n.rbi +132 -0
  77. data/sorbet/rbi/gems/ice_nine.rbi +66 -0
  78. data/sorbet/rbi/gems/jaro_winkler.rbi +14 -0
  79. data/sorbet/rbi/gems/kwalify.rbi +339 -0
  80. data/sorbet/rbi/gems/method_source.rbi +63 -0
  81. data/sorbet/rbi/gems/parallel.rbi +81 -0
  82. data/sorbet/rbi/gems/parser.rbi +1293 -0
  83. data/sorbet/rbi/gems/pry-byebug.rbi +149 -0
  84. data/sorbet/rbi/gems/pry.rbi +1964 -0
  85. data/sorbet/rbi/gems/psych.rbi +462 -0
  86. data/sorbet/rbi/gems/rainbow.rbi +117 -0
  87. data/sorbet/rbi/gems/rake.rbi +634 -0
  88. data/sorbet/rbi/gems/rb-readline.rbi +766 -0
  89. data/sorbet/rbi/gems/reek.rbi +1066 -0
  90. data/sorbet/rbi/gems/rspec-core.rbi +1658 -0
  91. data/sorbet/rbi/gems/rspec-expectations.rbi +430 -0
  92. data/sorbet/rbi/gems/rspec-mocks.rbi +815 -0
  93. data/sorbet/rbi/gems/rspec-support.rbi +268 -0
  94. data/sorbet/rbi/gems/rspec.rbi +14 -0
  95. data/sorbet/rbi/gems/rubocop-rspec.rbi +875 -0
  96. data/sorbet/rbi/gems/rubocop.rbi +7014 -0
  97. data/sorbet/rbi/gems/ruby-progressbar.rbi +304 -0
  98. data/sorbet/rbi/gems/simplecov-html.rbi +30 -0
  99. data/sorbet/rbi/gems/simplecov.rbi +225 -0
  100. data/sorbet/rbi/gems/stackprof.rbi +51 -0
  101. data/sorbet/rbi/gems/thread_safe.rbi +81 -0
  102. data/sorbet/rbi/gems/timecop.rbi +97 -0
  103. data/sorbet/rbi/gems/unicode-display_width.rbi +16 -0
  104. data/sorbet/rbi/gems/virtus.rbi +421 -0
  105. data/sorbet/rbi/hidden-definitions/errors.txt +7332 -0
  106. data/sorbet/rbi/hidden-definitions/hidden.rbi +17521 -0
  107. data/sorbet/rbi/sorbet-typed/lib/activemodel/all/activemodel.rbi +422 -0
  108. data/sorbet/rbi/sorbet-typed/lib/activesupport/>=6.0.0.rc1/activesupport.rbi +23 -0
  109. data/sorbet/rbi/sorbet-typed/lib/activesupport/all/activesupport.rbi +625 -0
  110. data/sorbet/rbi/sorbet-typed/lib/bundler/all/bundler.rbi +8684 -0
  111. data/sorbet/rbi/sorbet-typed/lib/minitest/all/minitest.rbi +99 -0
  112. data/sorbet/rbi/sorbet-typed/lib/rainbow/all/rainbow.rbi +254 -0
  113. data/sorbet/rbi/sorbet-typed/lib/ruby/all/gem.rbi +4222 -0
  114. data/sorbet/rbi/sorbet-typed/lib/ruby/all/open3.rbi +111 -0
  115. data/sorbet/rbi/sorbet-typed/lib/ruby/all/resolv.rbi +543 -0
  116. data/sorbet/rbi/todo.rbi +12 -0
  117. metadata +156 -24
  118. data/Gemfile.lock +0 -187
@@ -0,0 +1,51 @@
1
+ # This file is autogenerated. Do not edit it by hand. Regenerate it with:
2
+ # srb rbi gems
3
+
4
+ # typed: strong
5
+ #
6
+ # If you would like to make changes to this file, great! Please create the gem's shim here:
7
+ #
8
+ # https://github.com/sorbet/sorbet-typed/new/master?filename=lib/stackprof/all/stackprof.rbi
9
+ #
10
+ # stackprof-0.2.13
11
+ module StackProf
12
+ def self.results(*arg0); end
13
+ def self.run(*arg0); end
14
+ def self.running?; end
15
+ def self.sample; end
16
+ def self.start(*arg0); end
17
+ def self.stop; end
18
+ end
19
+ class StackProf::Report
20
+ def +(other); end
21
+ def add_lines(a, b); end
22
+ def callers_for(addr); end
23
+ def convert_to_d3_flame_graph_format(name, stacks, depth); end
24
+ def data; end
25
+ def files; end
26
+ def flamegraph_row(f, x, y, weight, addr); end
27
+ def frames(sort_by_total = nil); end
28
+ def initialize(data); end
29
+ def max_samples; end
30
+ def modeline; end
31
+ def normalized_frames; end
32
+ def overall_samples; end
33
+ def print_alphabetical_flamegraph(f = nil, skip_common = nil); end
34
+ def print_callgrind(f = nil); end
35
+ def print_d3_flamegraph(f = nil, skip_common = nil); end
36
+ def print_debug; end
37
+ def print_dump(f = nil); end
38
+ def print_file(filter, f = nil); end
39
+ def print_files(sort_by_total = nil, limit = nil, f = nil); end
40
+ def print_flamegraph(f, skip_common, alphabetical = nil); end
41
+ def print_graphviz(options = nil, f = nil); end
42
+ def print_json(f = nil); end
43
+ def print_method(name, f = nil); end
44
+ def print_stackcollapse; end
45
+ def print_text(sort_by_total = nil, limit = nil, select_files = nil, reject_files = nil, select_names = nil, reject_names = nil, f = nil); end
46
+ def print_timeline_flamegraph(f = nil, skip_common = nil); end
47
+ def root_frames; end
48
+ def source_display(f, file, lines, range = nil); end
49
+ def version; end
50
+ def walk_method(name); end
51
+ end
@@ -0,0 +1,81 @@
1
+ # This file is autogenerated. Do not edit it by hand. Regenerate it with:
2
+ # srb rbi gems
3
+
4
+ # typed: strong
5
+ #
6
+ # If you would like to make changes to this file, great! Please create the gem's shim here:
7
+ #
8
+ # https://github.com/sorbet/sorbet-typed/new/master?filename=lib/thread_safe/all/thread_safe.rbi
9
+ #
10
+ # thread_safe-0.3.6
11
+ module ThreadSafe
12
+ end
13
+ module Threadsafe
14
+ def self.const_missing(name); end
15
+ end
16
+ class SynchronizedDelegator < SimpleDelegator
17
+ def initialize(obj); end
18
+ def method_missing(method, *args, &block); end
19
+ def setup; end
20
+ def teardown; end
21
+ end
22
+ class ThreadSafe::NonConcurrentCacheBackend
23
+ def [](key); end
24
+ def []=(key, value); end
25
+ def _get(key); end
26
+ def _set(key, value); end
27
+ def clear; end
28
+ def compute(key); end
29
+ def compute_if_absent(key); end
30
+ def compute_if_present(key); end
31
+ def delete(key); end
32
+ def delete_pair(key, value); end
33
+ def dupped_backend; end
34
+ def each_pair; end
35
+ def get_and_set(key, value); end
36
+ def get_or_default(key, default_value); end
37
+ def initialize(options = nil); end
38
+ def initialize_copy(other); end
39
+ def key?(key); end
40
+ def merge_pair(key, value); end
41
+ def pair?(key, expected_value); end
42
+ def replace_if_exists(key, new_value); end
43
+ def replace_pair(key, old_value, new_value); end
44
+ def size; end
45
+ def store_computed_value(key, new_value); end
46
+ def value?(value); end
47
+ end
48
+ class ThreadSafe::MriCacheBackend < ThreadSafe::NonConcurrentCacheBackend
49
+ def []=(key, value); end
50
+ def clear; end
51
+ def compute(key); end
52
+ def compute_if_absent(key); end
53
+ def compute_if_present(key); end
54
+ def delete(key); end
55
+ def delete_pair(key, value); end
56
+ def get_and_set(key, value); end
57
+ def merge_pair(key, value); end
58
+ def replace_if_exists(key, new_value); end
59
+ def replace_pair(key, old_value, new_value); end
60
+ end
61
+ class ThreadSafe::Cache < ThreadSafe::MriCacheBackend
62
+ def [](key); end
63
+ def each_key; end
64
+ def each_value; end
65
+ def empty?; end
66
+ def fetch(key, default_value = nil); end
67
+ def fetch_or_store(key, default_value = nil); end
68
+ def get(key); end
69
+ def initialize(options = nil, &block); end
70
+ def initialize_copy(other); end
71
+ def key(value); end
72
+ def keys; end
73
+ def marshal_dump; end
74
+ def marshal_load(hash); end
75
+ def populate_from(hash); end
76
+ def put(key, value); end
77
+ def put_if_absent(key, value); end
78
+ def raise_fetch_no_key; end
79
+ def validate_options_hash!(options); end
80
+ def values; end
81
+ end
@@ -0,0 +1,97 @@
1
+ # This file is autogenerated. Do not edit it by hand. Regenerate it with:
2
+ # srb rbi gems
3
+
4
+ # typed: strong
5
+ #
6
+ # If you would like to make changes to this file, great! Please create the gem's shim here:
7
+ #
8
+ # https://github.com/sorbet/sorbet-typed/new/master?filename=lib/timecop/all/timecop.rbi
9
+ #
10
+ # timecop-0.9.1
11
+ class Time
12
+ def self.mock_time; end
13
+ def self.new(*args); end
14
+ def self.new_with_mock_time(*args); end
15
+ def self.new_without_mock_time(*arg0); end
16
+ def self.now_with_mock_time; end
17
+ def self.now_without_mock_time; end
18
+ end
19
+ class Date
20
+ def self.closest_wday(wday); end
21
+ def self.mock_date; end
22
+ def self.mocked_time_stack_item; end
23
+ def self.parse_with_mock_date(*args); end
24
+ def self.parse_without_mock_date(*arg0); end
25
+ def self.strptime_with_mock_date(str = nil, fmt = nil, start = nil); end
26
+ def self.strptime_without_mock_date(*arg0); end
27
+ def self.today_with_mock_date; end
28
+ def self.today_without_mock_date(*arg0); end
29
+ end
30
+ class DateTime < Date
31
+ def self.mock_time; end
32
+ def self.mocked_time_stack_item; end
33
+ def self.now_with_mock_time; end
34
+ def self.now_without_mock_time(*arg0); end
35
+ def self.parse_with_mock_date(*args); end
36
+ def self.parse_without_mock_date(*arg0); end
37
+ end
38
+ class Timecop
39
+ def baseline; end
40
+ def baseline=(b); end
41
+ def initialize; end
42
+ def return(&block); end
43
+ def return_to_baseline; end
44
+ def self.allocate; end
45
+ def self.baseline; end
46
+ def self.baseline=(baseline); end
47
+ def self.freeze(*args, &block); end
48
+ def self.frozen?; end
49
+ def self.instance; end
50
+ def self.new(*arg0); end
51
+ def self.return(&block); end
52
+ def self.return_to_baseline; end
53
+ def self.safe_mode=(safe); end
54
+ def self.safe_mode?; end
55
+ def self.scale(*args, &block); end
56
+ def self.send_travel(mock_type, *args, &block); end
57
+ def self.thread_safe; end
58
+ def self.thread_safe=(t); end
59
+ def self.top_stack_item; end
60
+ def self.travel(*args, &block); end
61
+ def set_baseline(b); end
62
+ def set_stack(s); end
63
+ def stack; end
64
+ def thread_safe; end
65
+ def thread_safe=(t); end
66
+ def travel(mock_type, *args, &block); end
67
+ def unmock!; end
68
+ extend Singleton::SingletonClassMethods
69
+ include Singleton
70
+ end
71
+ class Timecop::TimeStackItem
72
+ def compute_travel_offset; end
73
+ def date(date_klass = nil); end
74
+ def datetime(datetime_klass = nil); end
75
+ def day; end
76
+ def hour; end
77
+ def initialize(mock_type, *args); end
78
+ def min; end
79
+ def mock_type; end
80
+ def month; end
81
+ def parse_time(*args); end
82
+ def rational_to_utc_offset(rational); end
83
+ def scaled_time; end
84
+ def scaling_factor; end
85
+ def sec; end
86
+ def time(time_klass = nil); end
87
+ def time_klass; end
88
+ def times_are_equal_within_epsilon(t1, t2, epsilon_in_seconds); end
89
+ def travel_offset; end
90
+ def travel_offset_days; end
91
+ def utc_offset; end
92
+ def utc_offset_to_rational(utc_offset); end
93
+ def year; end
94
+ end
95
+ class Timecop::SafeModeException < StandardError
96
+ def initialize; end
97
+ end
@@ -0,0 +1,16 @@
1
+ # This file is autogenerated. Do not edit it by hand. Regenerate it with:
2
+ # srb rbi gems
3
+
4
+ # typed: strong
5
+ #
6
+ # If you would like to make changes to this file, great! Please create the gem's shim here:
7
+ #
8
+ # https://github.com/sorbet/sorbet-typed/new/master?filename=lib/unicode-display_width/all/unicode-display_width.rbi
9
+ #
10
+ # unicode-display_width-1.6.0
11
+ module Unicode
12
+ end
13
+ module Unicode::DisplayWidth
14
+ def self.emoji_extra_width_of(string, ambiguous = nil, overwrite = nil, _ = nil); end
15
+ def self.of(string, ambiguous = nil, overwrite = nil, options = nil); end
16
+ end
@@ -0,0 +1,421 @@
1
+ # This file is autogenerated. Do not edit it by hand. Regenerate it with:
2
+ # srb rbi gems
3
+
4
+ # typed: true
5
+ #
6
+ # If you would like to make changes to this file, great! Please create the gem's shim here:
7
+ #
8
+ # https://github.com/sorbet/sorbet-typed/new/master?filename=lib/virtus/all/virtus.rbi
9
+ #
10
+ # virtus-1.0.5
11
+ module Virtus
12
+ def self.coerce; end
13
+ def self.coerce=(value); end
14
+ def self.coercer(&block); end
15
+ def self.config(&block); end
16
+ def self.configuration; end
17
+ def self.extended(object); end
18
+ def self.finalize; end
19
+ def self.included(object); end
20
+ def self.model(options = nil, &block); end
21
+ def self.module(options = nil, &block); end
22
+ def self.value_object(options = nil, &block); end
23
+ def self.warn(msg); end
24
+ end
25
+ class Virtus::Equalizer < Module
26
+ def <<(key); end
27
+ def define_cmp_method; end
28
+ def define_hash_method; end
29
+ def define_inspect_method; end
30
+ def define_methods; end
31
+ def include_comparison_methods; end
32
+ def initialize(name, keys = nil); end
33
+ end
34
+ module Virtus::Equalizer::Methods
35
+ def ==(other); end
36
+ def eql?(other); end
37
+ end
38
+ module Virtus::Options
39
+ def accept_options(*new_options); end
40
+ def accepted_options; end
41
+ def add_accepted_options(new_options); end
42
+ def define_option_method(option); end
43
+ def inherited(descendant); end
44
+ def options; end
45
+ def set_options(new_options); end
46
+ end
47
+ module Virtus::TypeLookup
48
+ def determine_type(class_or_name); end
49
+ def determine_type_and_cache(class_or_name); end
50
+ def determine_type_from_descendant(descendant); end
51
+ def determine_type_from_primitive(primitive); end
52
+ def determine_type_from_string(string); end
53
+ def primitive; end
54
+ def self.extended(model); end
55
+ end
56
+ module Virtus::Model
57
+ def self.extended(descendant); end
58
+ def self.included(descendant); end
59
+ end
60
+ module Virtus::Model::Core
61
+ def self.extended(descendant); end
62
+ def self.included(descendant); end
63
+ end
64
+ module Virtus::Model::Constructor
65
+ def self.included(descendant); end
66
+ end
67
+ module Virtus::Model::MassAssignment
68
+ def self.extended(descendant); end
69
+ def self.included(descendant); end
70
+ end
71
+ module Virtus::Extensions
72
+ def self.extended(object); end
73
+ end
74
+ module Virtus::Extensions::Methods
75
+ def attribute(name, type = nil, options = nil); end
76
+ def attribute_set; end
77
+ def self.extended(descendant); end
78
+ def values(&block); end
79
+ end
80
+ module Virtus::Extensions::AllowedWriterMethods
81
+ def allowed_writer_methods; end
82
+ end
83
+ module Virtus::ConstMissingExtensions
84
+ def const_missing(name); end
85
+ end
86
+ module Virtus::ClassInclusions
87
+ def self.included(descendant); end
88
+ end
89
+ module Virtus::ClassInclusions::Methods
90
+ def allowed_writer_methods; end
91
+ def attribute_set; end
92
+ end
93
+ module Virtus::ModuleExtensions
94
+ def attribute(name, type = nil, options = nil); end
95
+ def define_attributes(object); end
96
+ def extended(object); end
97
+ def included(object); end
98
+ def self.extended(mod); end
99
+ def self.setup(mod, inclusions = nil, attribute_definitions = nil); end
100
+ include Virtus::ConstMissingExtensions
101
+ end
102
+ class Virtus::Configuration
103
+ def coerce; end
104
+ def coerce=(arg0); end
105
+ def coercer(&block); end
106
+ def constructor; end
107
+ def constructor=(arg0); end
108
+ def finalize; end
109
+ def finalize=(arg0); end
110
+ def initialize(options = nil); end
111
+ def mass_assignment; end
112
+ def mass_assignment=(arg0); end
113
+ def nullify_blank; end
114
+ def nullify_blank=(arg0); end
115
+ def required; end
116
+ def required=(arg0); end
117
+ def strict; end
118
+ def strict=(arg0); end
119
+ def to_h; end
120
+ end
121
+ class Virtus::Builder
122
+ def add_extended_hook; end
123
+ def add_included_hook; end
124
+ def config; end
125
+ def extensions; end
126
+ def initialize(conf, mod = nil); end
127
+ def mod; end
128
+ def options; end
129
+ def self.call(options, &block); end
130
+ def self.pending; end
131
+ def with_hook_context; end
132
+ end
133
+ class Virtus::ModelBuilder < Virtus::Builder
134
+ end
135
+ class Virtus::ModuleBuilder < Virtus::Builder
136
+ def add_included_hook; end
137
+ end
138
+ class Virtus::ValueObjectBuilder < Virtus::Builder
139
+ def extensions; end
140
+ def options; end
141
+ end
142
+ class Virtus::Builder::HookContext
143
+ def attribute_method; end
144
+ def builder; end
145
+ def config; end
146
+ def constructor?; end
147
+ def finalize?; end
148
+ def initialize(builder, config); end
149
+ def initialize_attribute_method; end
150
+ def mass_assignment?; end
151
+ def modules; end
152
+ end
153
+ module Virtus::ClassMethods
154
+ def allowed_methods; end
155
+ def assert_valid_name(name); end
156
+ def attribute_set; end
157
+ def attributes; end
158
+ def inherited(descendant); end
159
+ def self.extended(descendant); end
160
+ include Virtus::ConstMissingExtensions
161
+ include Virtus::Extensions::Methods
162
+ end
163
+ module Virtus::InstanceMethods
164
+ def [](name); end
165
+ def []=(name, value); end
166
+ def allowed_methods; end
167
+ def assert_valid_name(name); end
168
+ def freeze; end
169
+ def reset_attribute(attribute_name); end
170
+ def set_default_attributes!; end
171
+ def set_default_attributes; end
172
+ end
173
+ module Virtus::InstanceMethods::Constructor
174
+ def initialize(attributes = nil); end
175
+ end
176
+ module Virtus::InstanceMethods::MassAssignment
177
+ def attributes; end
178
+ def attributes=(attributes); end
179
+ def to_h; end
180
+ def to_hash; end
181
+ end
182
+ module Virtus::ValueObject
183
+ def self.included(base); end
184
+ end
185
+ module Virtus::ValueObject::InstanceMethods
186
+ def clone; end
187
+ def dup; end
188
+ def with(attribute_updates); end
189
+ end
190
+ module Virtus::ValueObject::AllowedWriterMethods
191
+ def allowed_writer_methods; end
192
+ end
193
+ module Virtus::ValueObject::ClassMethods
194
+ def attribute(name, type, options = nil); end
195
+ def equalizer; end
196
+ end
197
+ class Virtus::Coercer
198
+ def call(input); end
199
+ def initialize(type); end
200
+ def primitive; end
201
+ def success?(primitive, input); end
202
+ def type; end
203
+ end
204
+ class Virtus::AttributeSet < Module
205
+ def <<(attribute); end
206
+ def [](name); end
207
+ def []=(name, attribute); end
208
+ def coerce(attributes); end
209
+ def define_reader_method(attribute, method_name, visibility); end
210
+ def define_writer_method(attribute, method_name, visibility); end
211
+ def each; end
212
+ def finalize; end
213
+ def get(object); end
214
+ def initialize(parent = nil, attributes = nil); end
215
+ def merge(attributes); end
216
+ def merge_attributes(attributes); end
217
+ def reset; end
218
+ def self.create(descendant); end
219
+ def set(object, attributes); end
220
+ def set_defaults(object, filter = nil); end
221
+ def skip_default?(object, attribute); end
222
+ def update_index(name, attribute); end
223
+ include Enumerable
224
+ end
225
+ class Virtus::Attribute
226
+ def coerce(input); end
227
+ def coercer; end
228
+ def coercible?; end
229
+ def default_value; end
230
+ def define_accessor_methods(attribute_set); end
231
+ def finalize; end
232
+ def finalized?; end
233
+ def initialize(type, options); end
234
+ def lazy?; end
235
+ def nullify_blank?; end
236
+ def options; end
237
+ def primitive; end
238
+ def rename(name); end
239
+ def required?; end
240
+ def self.accessor(value = nil); end
241
+ def self.build(type, options = nil); end
242
+ def self.build_coercer(type, options = nil); end
243
+ def self.build_type(definition); end
244
+ def self.coerce(value = nil); end
245
+ def self.default(value = nil); end
246
+ def self.finalize(value = nil); end
247
+ def self.lazy(value = nil); end
248
+ def self.merge_options!(*arg0); end
249
+ def self.nullify_blank(value = nil); end
250
+ def self.primitive(value = nil); end
251
+ def self.required(value = nil); end
252
+ def self.strict(value = nil); end
253
+ def strict?; end
254
+ def type; end
255
+ def value_coerced?(value); end
256
+ extend DescendantsTracker
257
+ include Anonymous_Equalizer_51
258
+ include Equalizer::Methods
259
+ end
260
+ class Virtus::Attribute::DefaultValue
261
+ def call(*arg0); end
262
+ def initialize(value); end
263
+ def self.build(*args); end
264
+ def value; end
265
+ extend DescendantsTracker
266
+ end
267
+ class Virtus::Attribute::DefaultValue::FromClonable < Virtus::Attribute::DefaultValue
268
+ def call(*arg0); end
269
+ def self.handle?(value); end
270
+ end
271
+ class Virtus::Attribute::DefaultValue::FromCallable < Virtus::Attribute::DefaultValue
272
+ def call(*args); end
273
+ def self.handle?(value); end
274
+ end
275
+ class Virtus::Attribute::DefaultValue::FromSymbol < Virtus::Attribute::DefaultValue
276
+ def call(instance, _); end
277
+ def self.handle?(value); end
278
+ end
279
+ module Anonymous_Equalizer_51
280
+ def cmp?(comparator, other); end
281
+ def hash; end
282
+ def inspect; end
283
+ end
284
+ class Virtus::PendingAttribute
285
+ def determine_type; end
286
+ def finalize; end
287
+ def finalized?; end
288
+ def initialize(type, options); end
289
+ def name; end
290
+ def options; end
291
+ def type; end
292
+ end
293
+ class Virtus::TypeDefinition
294
+ def initialize(type); end
295
+ def initialize_primitive; end
296
+ def pending?; end
297
+ def primitive; end
298
+ def type; end
299
+ end
300
+ class Virtus::Attribute::Builder
301
+ def attribute; end
302
+ def determine_coercer; end
303
+ def determine_visibility; end
304
+ def initialize(type_definition, options); end
305
+ def initialize_attribute; end
306
+ def initialize_class; end
307
+ def initialize_coercer; end
308
+ def initialize_default_value; end
309
+ def initialize_options(options); end
310
+ def initialize_type; end
311
+ def klass; end
312
+ def options; end
313
+ def self.call(type, options = nil); end
314
+ def self.determine_type(klass, default = nil); end
315
+ def type; end
316
+ def type_definition; end
317
+ end
318
+ class Virtus::Attribute::Coercer < Virtus::Coercer
319
+ def call(value); end
320
+ def coercers; end
321
+ def initialize(type, coercers); end
322
+ def method; end
323
+ def success?(primitive, value); end
324
+ end
325
+ module Virtus::Attribute::Accessor
326
+ def defined?(instance); end
327
+ def get(instance); end
328
+ def instance_variable_name; end
329
+ def name; end
330
+ def public_reader?; end
331
+ def public_writer?; end
332
+ def self.extended(descendant); end
333
+ def set(instance, value); end
334
+ def set_default_value(instance); end
335
+ end
336
+ module Virtus::Attribute::Coercible
337
+ def set(instance, value); end
338
+ end
339
+ module Virtus::Attribute::Strict
340
+ def coerce(*arg0); end
341
+ end
342
+ module Virtus::Attribute::LazyDefault
343
+ def get(instance); end
344
+ end
345
+ module Virtus::Attribute::NullifyBlank
346
+ def coerce(input); end
347
+ end
348
+ class Virtus::Attribute::Boolean < Virtus::Attribute
349
+ def define_accessor_methods(attribute_set); end
350
+ def self.build_type(*arg0); end
351
+ def value_coerced?(value); end
352
+ end
353
+ class Virtus::Attribute::Collection < Virtus::Attribute
354
+ def coerce(value); end
355
+ def finalize; end
356
+ def finalized?; end
357
+ def member_type; end
358
+ def self.build_type(definition); end
359
+ def self.merge_options!(type, options); end
360
+ end
361
+ class Virtus::Attribute::Collection::Type < Struct
362
+ def coercion_method; end
363
+ def member_type; end
364
+ def member_type=(_); end
365
+ def primitive; end
366
+ def primitive=(_); end
367
+ def self.[](*arg0); end
368
+ def self.axiom_type?(type); end
369
+ def self.infer(type, primitive); end
370
+ def self.infer_member_type(type); end
371
+ def self.inspect; end
372
+ def self.members; end
373
+ def self.new(*arg0); end
374
+ def self.pending?(primitive); end
375
+ end
376
+ class Virtus::Attribute::Hash < Virtus::Attribute
377
+ def coerce(*arg0); end
378
+ def finalize; end
379
+ def finalized?; end
380
+ def key_type; end
381
+ def self.build_type(definition); end
382
+ def self.merge_options!(type, options); end
383
+ def value_type; end
384
+ end
385
+ class Virtus::Attribute::Hash::Type < Struct
386
+ def coercion_method; end
387
+ def key_type; end
388
+ def key_type=(_); end
389
+ def primitive; end
390
+ def self.[](*arg0); end
391
+ def self.axiom_type?(type); end
392
+ def self.determine_type(type); end
393
+ def self.infer(type); end
394
+ def self.infer_key_and_value_types(type); end
395
+ def self.inspect; end
396
+ def self.members; end
397
+ def self.new(*arg0); end
398
+ def self.pending?(primitive); end
399
+ def value_type; end
400
+ def value_type=(_); end
401
+ end
402
+ class Virtus::Attribute::EmbeddedValue < Virtus::Attribute
403
+ def self.build_coercer(type, _options); end
404
+ def self.build_type(definition); end
405
+ def self.handles?(klass); end
406
+ end
407
+ class Virtus::Attribute::EmbeddedValue::FromStruct < Virtus::Coercer
408
+ def call(input); end
409
+ end
410
+ class Virtus::Attribute::EmbeddedValue::FromOpenStruct < Virtus::Coercer
411
+ def call(input); end
412
+ end
413
+ class Virtus::CoercionError < StandardError
414
+ def attribute; end
415
+ def attribute_name; end
416
+ def attribute_name?; end
417
+ def build_message; end
418
+ def initialize(output, attribute); end
419
+ def output; end
420
+ def target_type; end
421
+ end