Class: OrcaApi::SubjectiveService::Result

Inherits:
Result
  • Object
show all
Defined in:
lib/orca_api/subjective_service.rb

Overview

症状詳記APIの処理結果を表現したクラス

Constant Summary

Constants inherited from Result

Result::LOCKED_API_RESULT

Instance Attribute Summary

Attributes inherited from Result

#raw

Instance Method Summary collapse

Methods inherited from Result

#[], #body, def_info, #initialize, #message, #method_missing, parse, #respond_to_missing?, trim_response, #warning?

Constructor Details

This class inherits a constructor from OrcaApi::Result

Constructor Details

This class inherits a constructor from OrcaApi::Result

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class OrcaApi::Result

Instance Method Details

#locked?Boolean

Returns:

  • (Boolean)


17
18
19
# File 'lib/orca_api/subjective_service.rb', line 17

def locked?
  super || api_result == "90"
end

#ok?Boolean

Returns:

  • (Boolean)


13
14
15
# File 'lib/orca_api/subjective_service.rb', line 13

def ok?
  api_result.match?(/\A(?:0+|K[1234]|WK[123])\z/)
end