private string _FindException(OctopusInstallmentsExceptionsEnum exceptionId) { string returned = String.Empty; switch(exceptionId) { case OctopusInstallmentsExceptionsEnum.InstallmentIsNull: returned = "InstallmentExceptionInstallmentIsNull.Text"; break; case OctopusInstallmentsExceptionsEnum.InstallmentAlreadyRepaid: returned = "InstallmentExceptionInstallmentAlreadyRepaid.Text"; break; case OctopusInstallmentsExceptionsEnum.NotFirstInstallmentToRepay: returned = "InstallmentExceptionNotFirstInstallmentToRepay.Text"; break; case OctopusInstallmentsExceptionsEnum.NotFirstInstallmentToCancelRepay: returned = "InstallmentExceptionNotFirstInstallmentToCancelRepay.Text"; break; } return returned; }
public OctopusInstallmentsException(OctopusInstallmentsExceptionsEnum exceptionCode) { _code = _FindException(exceptionCode); }