Class: ConvenientService::Service::Plugins::HasJSendResult::Entities::Result::Plugins::HasJSendStatusAndAttributes::Entities::Status::Commands::IsStatus

Inherits:
ConvenientService::Support::Command
  • Object
show all
Defined in:
lib/convenient_service/service/plugins/has_j_send_result/entities/result/plugins/has_j_send_status_and_attributes/entities/status/commands/is_status.rb

Overview

Check whether status can be considered as Status instance.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from ConvenientService::Support::Command

[], call

Constructor Details

#initialize(status:) ⇒ void

Parameters:

  • status (Object)

    Can be any type.



28
29
30
# File 'lib/convenient_service/service/plugins/has_j_send_result/entities/result/plugins/has_j_send_status_and_attributes/entities/status/commands/is_status.rb', line 28

def initialize(status:)
  @status = status
end

Instance Attribute Details

#statusObject (readonly)

Returns the value of attribute status.



22
23
24
# File 'lib/convenient_service/service/plugins/has_j_send_result/entities/result/plugins/has_j_send_status_and_attributes/entities/status/commands/is_status.rb', line 22

def status
  @status
end

Instance Method Details

#callBoolean

Returns:

  • (Boolean)


35
36
37
# File 'lib/convenient_service/service/plugins/has_j_send_result/entities/result/plugins/has_j_send_status_and_attributes/entities/status/commands/is_status.rb', line 35

def call
  status.class.include?(Entities::Status::Concern)
end