Class: ConvenientService::Examples::Standard::RequestParams::Entities::Source
- Inherits:
-
Object
- Object
- ConvenientService::Examples::Standard::RequestParams::Entities::Source
- Defined in:
- lib/convenient_service/examples/standard/request_params/entities/source.rb
Class Method Summary collapse
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(value:) ⇒ Source
constructor
A new instance of Source.
- #to_s ⇒ Object
Constructor Details
#initialize(value:) ⇒ Source
Returns a new instance of Source.
9 10 11 |
# File 'lib/convenient_service/examples/standard/request_params/entities/source.rb', line 9 def initialize(value:) @value = value end |
Class Method Details
.cast(value) ⇒ Object
14 15 16 17 18 19 |
# File 'lib/convenient_service/examples/standard/request_params/entities/source.rb', line 14 def cast(value) case value when ::String new(value: value.to_s) end end |
Instance Method Details
#==(other) ⇒ Object
22 23 24 25 26 |
# File 'lib/convenient_service/examples/standard/request_params/entities/source.rb', line 22 def ==(other) return unless other.instance_of?(self.class) value == other.value end |
#to_s ⇒ Object
28 29 30 |
# File 'lib/convenient_service/examples/standard/request_params/entities/source.rb', line 28 def to_s value end |