Ejemplo n.º 1
0
 public static void multiply()
 {
     population = (long)Math.Pow(population, 2);
     if (population > 10000)
     {
         MyExceptionArgs args = new MyExceptionArgs("It's enought of you");
         throw new MyException(args);
     }
 }
Ejemplo n.º 2
0
 public MyException(MyExceptionArgs args) : base(args.Message)
 {
     this.args = args;
 }
Ejemplo n.º 3
0
    private static void throwPopulationExeption()
    {
        MyExceptionArgs args = new MyExceptionArgs("It's enought of you");

        throw new MyException(args);
    }