コード例 #1
0
 private string _FindException(OctopusFundingLineExceptionEnum exception)
 {
     string returned = String.Empty;
     switch (exception)
     {
         case OctopusFundingLineExceptionEnum.CodeIsEmpty:
             returned = "OctopusFundingLineExceptionCodeIsEmpty.Text";
             break;
         case OctopusFundingLineExceptionEnum.NameIsEmpty:
             returned = "OctopusFundingLineExceptionNameIsEmpty.Text";
             break;
         case OctopusFundingLineExceptionEnum.BeginDateGreaterEndDate:
             returned = "OctopusFundingLineExceptionBeginDateGreaterEndDate.Text";
             break;
         case OctopusFundingLineExceptionEnum.BadFundingLineID:
             returned = "OctopusFundingLineExceptionBadFundingLineId.Text";
             break;
         case OctopusFundingLineExceptionEnum.FundingLineNameExists:
             returned = "OctopusFundingLineExceptionFundingLineNameExists.Text";
             break;
         case OctopusFundingLineExceptionEnum.CurrencyIsEmpty:
             returned = "CurrencyIsEmpty.Text";
             break;
     }
     return returned;
 }
コード例 #2
0
 public OctopusFundingLineException(OctopusFundingLineExceptionEnum exception)
 {
     _code = _FindException(exception);
 }