/// <summary> /// Método de presentador que agrega implemento /// </summary> public bool agregarImplemento(Entidad implemento) { try { Comando<bool> comandoAgregar = FabricaComandos.ObtenerComandoAgregar(); comandoAgregar.LaEntidad = implemento; return comandoAgregar.Ejecutar(); } catch (ExcepcionPresentadorAgregarImplemento ex) { ex = new ExcepcionPresentadorAgregarImplemento(M15_RecursoInterfazPresentador.ErrorPAgregar, new Exception()); Logger.EscribirError(M15_RecursoInterfazPresentador.ErrorPAgregar, ex); throw ex; } catch (ExceptionSKD ex) { ex = new ExcepcionesSKD.ExceptionSKD(M15_RecursoInterfazPresentador.ErrorPOperacion, new Exception()); Logger.EscribirError(M15_RecursoInterfazPresentador.ErrorPAgregar, ex); throw ex; } catch (Exception ex) { Logger.EscribirError(M15_RecursoInterfazPresentador.ErrorPAgregar, ex); throw ex; } }
public Entidad obtenerDojoXId(Entidad dojo) { /// <summary> /// Método de presentador para obtener el dojo por Id /// </summary> try { Comando<Entidad> comando = FabricaComandos.ObtenerComandoDojo(); comando.LaEntidad = dojo; return comando.Ejecutar(); } catch (ExcepcionPresentadorAgregarImplemento ex) { ex = new ExcepcionPresentadorAgregarImplemento(M15_RecursoInterfazPresentador.ErrorPAgregar, new Exception()); Logger.EscribirError(M15_RecursoInterfazPresentador.ErrorPAgregar, ex); throw ex; } catch (ExceptionSKD ex) { ex = new ExcepcionesSKD.ExceptionSKD(M15_RecursoInterfazPresentador.ErrorPOperacion, new Exception()); Logger.EscribirError(M15_RecursoInterfazPresentador.ErrorPAgregar, ex); throw ex; } catch (Exception ex) { Logger.EscribirError(M15_RecursoInterfazPresentador.ErrorPAgregar, ex); throw ex; } }
public int usuarioDojo(Entidad usuario) { /// <summary> /// Método de presentador que con el usuario te devuelve el dojo /// </summary> try { Comando<int> comando = FabricaComandos.ObtenerComandoUsuarioDojo(); comando.LaEntidad = usuario; return comando.Ejecutar(); } catch (ExcepcionPresentadorAgregarImplemento ex) { ex = new ExcepcionPresentadorAgregarImplemento(M15_RecursoInterfazPresentador.ErrorPAgregar, new Exception()); Logger.EscribirError(M15_RecursoInterfazPresentador.ErrorPAgregar, ex); throw ex; } catch (ExceptionSKD ex) { ex = new ExcepcionesSKD.ExceptionSKD(M15_RecursoInterfazPresentador.ErrorPOperacion, new Exception()); Logger.EscribirError(M15_RecursoInterfazPresentador.ErrorPAgregar, ex); throw ex; } catch (Exception ex) { Logger.EscribirError(M15_RecursoInterfazPresentador.ErrorPAgregar, ex); throw ex; } }