OHyMoS.NET Class Library

OhError クラス

OHyMoS.NET の例外クラスです。

OHyMoS.NET error exception class. OhError is a derived class of the Exception class.

この型のすべてのメンバの一覧については、 OhError メンバを参照してください。

System.Object
   System.Exception
      OhymosNet.OhError

public class OhError : Exception

解説

例外を投げるにはコンストラクタでOhErrorオブジェクトを生成し、 それをthrowします。そして、同メソッド内、もしくは呼び出し元メソッドで catchするようにします。

以下に例を示します。

The OhError class object constructor is used as
.....
try 
{
    ...
    OhError e = new OhError(errorMessage1, errorMessage2);
    throw e;
}
catch (OhError e) 
{
    System.Console.WriteLine(e.Message);
}
.....
The example of the creation method of an error message is as follows.
.....
if(some error status was detected) 
{
    throw new OhError("Already exits \"_dataPackArray\".", oPrintString(" > "));
}
.....

必要条件

名前空間: OhymosNet

アセンブリ: OhymosNet (OhymosNet.dll 内)

参照

OhError メンバ | OhymosNet 名前空間