Exception: Miyako::MiyakoIOError

Inherits:
MiyakoError show all
Defined in:
lib/Miyako/API/exceptions.rb

Overview

Miyakoの入出力例外クラス

Direct Known Subclasses

MiyakoFileFormatError

Class Method Summary collapse

Class Method Details

.illegal_file_foramt(path) ⇒ Object

ファイルが見つからなかったときの例外を生成する

「ファイルが見つからない」というエラーメッセージを発する 例外インスタンスを生成する

path

見つからなかったファイルパス

返却値

生成した例外インスタンス



49
50
51
# File 'lib/Miyako/API/exceptions.rb', line 49

def MiyakoIOError.illegal_file_foramt(path)
  MiyakoIOError.exception("Illegal file format.: #{path}")
end

.no_file(path) ⇒ Object

ファイルが見つからなかったときの例外を生成する

「ファイルが見つからない」というエラーメッセージを発する 例外インスタンスを生成する

path

見つからなかったファイルパス

返却値

生成した例外インスタンス



37
38
39
# File 'lib/Miyako/API/exceptions.rb', line 37

def MiyakoIOError.no_file(path)
  MiyakoIOError.exception("Not found file: #{path}")
end