-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathoutput.rbs
More file actions
175 lines (124 loc) · 4.24 KB
/
output.rbs
File metadata and controls
175 lines (124 loc) · 4.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
class Solid::Output < Solid::Result
EXPECTED_OUTCOME: String
SourceMethodArity: ^(Method) -> Integer
attr_reader memo: Hash[Symbol, untyped]
def initialize: (
type: Symbol,
value: untyped,
?source: untyped,
?expectations: Solid::Result::Contract::Evaluator,
?terminal: bool
) -> void
def and_then: (?Symbol, **untyped) ?{ (Hash[Symbol, untyped]) -> untyped } -> untyped
def and_then!: (untyped, **untyped) -> untyped
private
def call_and_then_source_method: (Symbol, Hash[Symbol, untyped]) -> Solid::Output
def call_and_then_callable!: (untyped, value: untyped, injected_value: untyped, method_name: (Symbol | nil)) -> Solid::Output
def ensure_result_object: (untyped, origin: Symbol) -> Solid::Output
def raise_unexpected_outcome_error: (Solid::Output | untyped, Symbol) -> void
end
class Solid::Output
class Error < Solid::Result::Error
class InvalidExposure < Solid::Output::Error
end
end
end
class Solid::Output
class Success < Solid::Output
include Solid::Success
FetchValues: Proc
def and_expose: (Symbol, Array[Symbol], terminal: bool) -> Solid::Output::Success
end
def self.Success: (Symbol, **untyped) -> Solid::Output::Success
end
module Solid::Output::CallableAndThen
class Caller < Solid::Result::CallableAndThen::Caller
module KeyArgs
def self.parameters?: (untyped) -> bool
def self.invalid_arity: (untyped, Symbol) -> Solid::Result::CallableAndThen::Error::InvalidArity
end
def self.call: (
untyped source,
value: untyped,
injected_value: untyped,
method_name: (Symbol | nil),
) -> Solid::Output
private
def self.call_proc!: (
untyped source,
Hash[Symbol, untyped] value,
nil injected_value
) -> Solid::Output
def self.call_method!: (
untyped source,
Method method,
Hash[Symbol, untyped] value,
nil injected_value
) -> Solid::Output
def self.callable_method: (
untyped source,
(Symbol | nil) method_name
) -> ::Method
def self.ensure_result_object: (
untyped source,
untyped value,
Solid::Output result
) -> Solid::Output
def self.expected_result_object: () -> singleton(Solid::Output)
def self.expected_outcome: () -> String
end
end
class Solid::Output
class Failure < Solid::Output
include Solid::Failure
def and_expose: (Symbol, Array[Symbol], **untyped) -> Solid::Output::Failure
end
def self.Failure: (Symbol, **untyped) -> Solid::Output::Failure
end
class Solid::Output
module Mixin
Factory: singleton(Solid::Result::Mixin::Factory)
module Methods
def Success: (Symbol, **untyped) -> Solid::Output::Success
def Failure: (Symbol, **untyped) -> Solid::Output::Failure
private
def _ResultAs: (singleton(Solid::Output), Symbol, untyped, ?terminal: bool) -> untyped
end
module Addons
module Continue
include Solid::Output::Mixin::Methods
private
def Continue: (**untyped) -> Solid::Output::Success
end
module Given
include Solid::Output::Mixin::Methods
private
def Given: (*untyped) -> Solid::Output::Success
end
OPTIONS: Hash[Symbol, Module]
def self.options: (Hash[Symbol, Hash[Symbol, bool]]) -> Hash[Symbol, Module]
end
end
def self.mixin_module: -> singleton(Solid::Output::Mixin)
def self.result_factory: -> singleton(Solid::Output)
end
class Solid::Output::Expectations < Solid::Result::Expectations
def self.mixin_module: -> singleton(Solid::Output::Expectations::Mixin)
def self.result_factory_without_expectations: -> singleton(Solid::Result)
def Success: (Symbol, **untyped) -> Solid::Output::Success
def Failure: (Symbol, **untyped) -> Solid::Output::Failure
end
module Solid::Output::Expectations::Mixin
Methods: singleton(Solid::Result::Expectations::Mixin::Methods)
Factory: singleton(Solid::Result::Expectations::Mixin::Factory)
module Addons
module Continue
private def Continue: (**untyped) -> Solid::Output::Success
end
module Given
private def Given: (*untyped) -> Solid::Output::Success
end
OPTIONS: Hash[Symbol, Module]
def self.options: (Hash[Symbol, Hash[Symbol, bool]]) -> Hash[Symbol, Module]
end
end