private string _FindException(OpenCbsBookingExceptionsEnum exceptionId) { string returned = String.Empty; switch(exceptionId) { case OpenCbsBookingExceptionsEnum.NameIsEmpty: returned = "OpenCbsBookingExceptionsNameIsEmpty.Text"; break; case OpenCbsBookingExceptionsEnum.CreditAccountIsEmpty: returned = "OpenCbsBookingExceptionsCreditAccountIsEmpty.Text"; break; case OpenCbsBookingExceptionsEnum.DebitAccountIsEmpty: returned = "OpenCbsBookingExceptionsDebitAccountIsEmpty.Text"; break; case OpenCbsBookingExceptionsEnum.DebitAndCreditAccountAreIdentical: returned = "OpenCbsBookingExceptionDebitAndCreditAccountAreIdentical.Text"; break; case OpenCbsBookingExceptionsEnum.BookingIsEmpty: returned = "BookingIsEmpty.Text"; break; case OpenCbsBookingExceptionsEnum.NotDeletableClosure: returned = "OpenCbsNotDeletableClosure.Text"; break; } return returned; }
private string _FindException(OpenCbsBookingExceptionsEnum exceptionId) { string returned = String.Empty; switch (exceptionId) { case OpenCbsBookingExceptionsEnum.NameIsEmpty: returned = "OpenCbsBookingExceptionsNameIsEmpty.Text"; break; case OpenCbsBookingExceptionsEnum.CreditAccountIsEmpty: returned = "OpenCbsBookingExceptionsCreditAccountIsEmpty.Text"; break; case OpenCbsBookingExceptionsEnum.DebitAccountIsEmpty: returned = "OpenCbsBookingExceptionsDebitAccountIsEmpty.Text"; break; case OpenCbsBookingExceptionsEnum.DebitAndCreditAccountAreIdentical: returned = "OpenCbsBookingExceptionDebitAndCreditAccountAreIdentical.Text"; break; case OpenCbsBookingExceptionsEnum.BookingIsEmpty: returned = "BookingIsEmpty.Text"; break; case OpenCbsBookingExceptionsEnum.NotDeletableClosure: returned = "OpenCbsNotDeletableClosure.Text"; break; } return(returned); }
public OpenCbsBookingException(OpenCbsBookingExceptionsEnum exceptionCode) { _code = _FindException(exceptionCode); }