Module: ConvenientService::Service::Plugins::HasJSendResult::Entities::Result::Plugins::HasJSendStatusAndAttributes::Entities::Status::Concern::ClassMethods
- Defined in:
- lib/convenient_service/service/plugins/has_j_send_result/entities/result/plugins/has_j_send_status_and_attributes/entities/status/concern/class_methods.rb
Instance Method Summary collapse
- #===(other) ⇒ Boolean?
- #cast(other) ⇒ ConvenientService::Service::Plugins::HasJSendResult::Entities::Result::Plugins::HasJSendStatusAndAttributes::Entities::Status?
Instance Method Details
#===(other) ⇒ Boolean?
38 39 40 |
# File 'lib/convenient_service/service/plugins/has_j_send_result/entities/result/plugins/has_j_send_status_and_attributes/entities/status/concern/class_methods.rb', line 38 def ===(other) Commands::IsStatus.call(status: other) || super end |
#cast(other) ⇒ ConvenientService::Service::Plugins::HasJSendResult::Entities::Result::Plugins::HasJSendStatusAndAttributes::Entities::Status?
19 20 21 22 23 24 25 26 27 28 |
# File 'lib/convenient_service/service/plugins/has_j_send_result/entities/result/plugins/has_j_send_status_and_attributes/entities/status/concern/class_methods.rb', line 19 def cast(other) case other when ::String new(value: other.to_sym) when ::Symbol new(value: other) when Status new(value: other.value) end end |