Example #1
0
    private static int Main()
    {
        BaseException ex = new DerivedException();
        try
        {
            if (ex is DerivedException)
                throw (DerivedException)ex;
        }
        catch (DerivedException)
        {
            goto continue_1;
        }
        Console.WriteLine("failed(1)");
        return 101;

    continue_1:
        try
        {
            if (ex is DerivedException)
                throw (DerivedException)ex;
        }
        catch (DerivedException)
        {
            goto continue_2;
        }
        Console.WriteLine("failed(2)");
        return 102;

    continue_2:
        Console.WriteLine("Good");
        return 100;
    }
Example #2
0
 throwDerivedAsDerivedAsync(Ice.Current current)
 {
     var de = new DerivedException();
     de.sbe = "sbe";
     de.pb = new B();
     de.pb.sb = "sb1";
     de.pb.pb = de.pb;
     de.sde = "sde1";
     de.pd1 = new D1();
     de.pd1.sb = "sb2";
     de.pd1.pb = de.pd1;
     de.pd1.sd1 = "sd2";
     de.pd1.pd1 = de.pd1;
     throw de;
 }
Example #3
0
 public override Task throwDerivedAsBaseAsync(Ice.Current current)
 {
     DerivedException de = new DerivedException();
     de.sbe = "sbe";
     de.pb = new B();
     de.pb.sb = "sb1";
     de.pb.pb = de.pb;
     de.sde = "sde1";
     de.pd1 = new D1();
     de.pd1.sb = "sb2";
     de.pd1.pb = de.pd1;
     de.pd1.sd1 = "sd2";
     de.pd1.pd1 = de.pd1;
     throw de;
 }
Example #4
0
    public override void throwDerivedAsDerived_async(AMD_TestIntf_throwDerivedAsDerived cb, Ice.Current current)
    {
        DerivedException de = new DerivedException();

        de.sbe     = "sbe";
        de.pb      = new B();
        de.pb.sb   = "sb1";
        de.pb.pb   = de.pb;
        de.sde     = "sde1";
        de.pd1     = new D1();
        de.pd1.sb  = "sb2";
        de.pd1.pb  = de.pd1;
        de.pd1.sd1 = "sd2";
        de.pd1.pd1 = de.pd1;
        cb.ice_exception(de);
    }
Example #5
0
    void throwDerivedAsDerivedAsync(Action response, Action <Exception> exception, Ice.Current current)
    {
        var de = new DerivedException();

        de.sbe     = "sbe";
        de.pb      = new B();
        de.pb.sb   = "sb1";
        de.pb.pb   = de.pb;
        de.sde     = "sde1";
        de.pd1     = new D1();
        de.pd1.sb  = "sb2";
        de.pd1.pb  = de.pd1;
        de.pd1.sd1 = "sd2";
        de.pd1.pd1 = de.pd1;
        exception(de);
    }
Example #6
0
    public static int TestEntryPoint()
    {
        BaseException ex = new DerivedException();

        try
        {
            if (ex is DerivedException)
            {
                throw (DerivedException)ex;
            }
        }
        catch (DerivedException)
        {
            goto continue_1;
        }
        Console.WriteLine("failed(1)");
        return(101);

continue_1:
        try
        {
            if (ex is DerivedException)
            {
                throw (DerivedException)ex;
            }
        }
        catch (DerivedException)
        {
            goto continue_2;
        }
        Console.WriteLine("failed(2)");
        return(102);

continue_2:
        Console.WriteLine("Good");
        return(100);
    }
Example #7
0
 public override void throwDerivedAsDerived_async(AMD_TestIntf_throwDerivedAsDerived cb, Ice.Current current)
 {
     DerivedException de = new DerivedException();
     de.sbe = "sbe";
     de.pb = new B();
     de.pb.sb = "sb1";
     de.pb.pb = de.pb;
     de.sde = "sde1";
     de.pd1 = new D1();
     de.pd1.sb = "sb2";
     de.pd1.pb = de.pd1;
     de.pd1.sd1 = "sd2";
     de.pd1.pd1 = de.pd1;
     cb.ice_exception(de);
 }
Example #8
0
 public override void throwDerivedAsDerived(Ice.Current current)
 {
     DerivedException de = new DerivedException();
     de.sbe = "sbe";
     de.pb = new B();
     de.pb.sb = "sb1";
     de.pb.pb = de.pb;
     de.sde = "sde1";
     de.pd1 = new D1();
     de.pd1.sb = "sb2";
     de.pd1.pb = de.pd1;
     de.pd1.sd1 = "sd2";
     de.pd1.pd1 = de.pd1;
     throw de;
 }