Exemplo n.º 1
0
 public MiClase(int n)
 {
     try
     {
         MiClase miClase = new MiClase();
     }
     catch (Exception e)
     {
         throw new UnaExcepcion("mensaje", e);
     }
 }
Exemplo n.º 2
0
 public void metodo()
 {
     try
     {
         MiClase mc = new MiClase();
     }
     catch (UnaExcepcion ex)
     {
         throw new MiExcepcion("una excepcion cazada", ex);
     }
 }
Exemplo n.º 3
0
 public MiClase()
 {
     try
     {
         MiClase.MiMetodo();
     }
     catch (DivideByZeroException e)
     {
         throw e;
     }
 }
Exemplo n.º 4
0
 public MiClase()
 {
     try
     {
         MiClase.MetodoEstatico();
     }
     catch (Exception e)
     {
         throw e;
     }
 }
Exemplo n.º 5
0
 public MiClase(int a)
 {
     try
     {
         MiClase mc = new MiClase();
     }
     catch (DivideByZeroException e)
     {
         throw new UnaExcepcion("Se ha lanzado una excepcion", e);
     }
 }
Exemplo n.º 6
0
 public void MetodoInstancia()
 {
     try
     {
         MiClase miClase = new MiClase(2);
     }
     catch (Exception e)
     {
         throw new MiExcepcion("mensaje2", e);
     }
 }
 public MiClase()
 {
     try
     {
         MiClase.Lanzar();
     }
     catch (DivideByZeroException ex)
     {
         throw ex;
     }
 }
Exemplo n.º 8
0
 public void MetodoInstancia()
 {
     try
     {
         MiClase miClase = new MiClase(2);
     }
     catch (DivideByZeroException b)
     {
         throw new MiException("Mensaje2", b);
     }
 }
Exemplo n.º 9
0
 public MiClase(int i)
 {
     try
     {
         MiClase miClase = new MiClase();
     }
     catch (Exception b)
     {
         throw new UnaException("mensaje", b);
     }
 }
Exemplo n.º 10
0
 public OtraClase()
 {
     try
     {
         MiClase mc = new MiClase(0);
     }
     catch (UnaExcepcion e)
     {
         throw new MiExcepcion("Constructor OtraClase", e);
     }
 }
Exemplo n.º 11
0
 public MiClase()
 {
     try
     {
         MiClase.MetodEstat();
         Console.WriteLine("hoola5");
     }
     catch (DivideByZeroException)
     {
         throw;
     }
     Console.WriteLine("hoola6");
 }