diff --git a/Examples/test-suite/java/director_abstract_runme.java b/Examples/test-suite/java/director_abstract_runme.java index f694e9740..0453fb7f0 100644 --- a/Examples/test-suite/java/director_abstract_runme.java +++ b/Examples/test-suite/java/director_abstract_runme.java @@ -14,17 +14,17 @@ public class director_abstract_runme { public static void main(String argv[]) { - MyFoo a = new MyFoo(); + director_abstract_MyFoo a = new director_abstract_MyFoo(); - if (!a.ping().equals("MyFoo::ping()")) { + if (!a.ping().equals("director_abstract_MyFoo::ping()")) { throw new RuntimeException ( "a.ping()" ); } - if (!a.pong().equals("Foo::pong();MyFoo::ping()")) { + if (!a.pong().equals("Foo::pong();director_abstract_MyFoo::ping()")) { throw new RuntimeException ( "a.pong()" ); } - BadFoo b = new BadFoo(); + director_abstract_BadFoo b = new director_abstract_BadFoo(); try { b.ping(); System.out.println( "Test failed. An attempt to call a pure virtual method should throw an exception" ); @@ -35,12 +35,12 @@ public class director_abstract_runme { } } -class MyFoo extends Foo { +class director_abstract_MyFoo extends Foo { public String ping() { - return "MyFoo::ping()"; + return "director_abstract_MyFoo::ping()"; } } -class BadFoo extends Foo { +class director_abstract_BadFoo extends Foo { } diff --git a/Examples/test-suite/java/director_basic_runme.java b/Examples/test-suite/java/director_basic_runme.java index 3210cd086..eafe20bec 100644 --- a/Examples/test-suite/java/director_basic_runme.java +++ b/Examples/test-suite/java/director_basic_runme.java @@ -14,13 +14,13 @@ public class director_basic_runme { public static void main(String argv[]) { - MyFoo a = new MyFoo(); + director_basic_MyFoo a = new director_basic_MyFoo(); - if (!a.ping().equals("MyFoo::ping()")) { + if (!a.ping().equals("director_basic_MyFoo::ping()")) { throw new RuntimeException ( "a.ping()" ); } - if (!a.pong().equals("Foo::pong();MyFoo::ping()")) { + if (!a.pong().equals("Foo::pong();director_basic_MyFoo::ping()")) { throw new RuntimeException ( "a.pong()" ); } @@ -39,9 +39,9 @@ public class director_basic_runme { } } -class MyFoo extends Foo { +class director_basic_MyFoo extends Foo { public String ping() { - return "MyFoo::ping()"; + return "director_basic_MyFoo::ping()"; } } diff --git a/Examples/test-suite/java/director_default_runme.java b/Examples/test-suite/java/director_default_runme.java index 6713fc550..b71e45e25 100644 --- a/Examples/test-suite/java/director_default_runme.java +++ b/Examples/test-suite/java/director_default_runme.java @@ -14,15 +14,15 @@ public class director_default_runme { public static void main(String argv[]) { { - MyFoo a = new MyFoo(); - a = new MyFoo(10); + director_default_MyFoo a = new director_default_MyFoo(); + a = new director_default_MyFoo(10); } - MyFoo a = new MyFoo(); - if (!a.GetMsg().equals("MyFoo-default")) { + director_default_MyFoo a = new director_default_MyFoo(); + if (!a.GetMsg().equals("director_default_MyFoo-default")) { throw new RuntimeException ( "Test 1 failed" ); } - if (!a.GetMsg("boo").equals("MyFoo-boo")) { + if (!a.GetMsg("boo").equals("director_default_MyFoo-boo")) { throw new RuntimeException ( "Test 2 failed" ); } @@ -37,15 +37,15 @@ public class director_default_runme { } } -class MyFoo extends Foo { - public MyFoo() { +class director_default_MyFoo extends Foo { + public director_default_MyFoo() { super(); } - public MyFoo(int i) { + public director_default_MyFoo(int i) { super(i); } public String Msg(String msg) { - return "MyFoo-" + msg; + return "director_default_MyFoo-" + msg; } } diff --git a/Examples/test-suite/java/director_enum_runme.java b/Examples/test-suite/java/director_enum_runme.java index 50741b3f3..9abfa3174 100644 --- a/Examples/test-suite/java/director_enum_runme.java +++ b/Examples/test-suite/java/director_enum_runme.java @@ -14,7 +14,7 @@ public class director_enum_runme { public static void main(String argv[]) { - MyFoo a = new MyFoo(); + director_enum_MyFoo a = new director_enum_MyFoo(); if (a.ping(Hallo.awright) != Hallo.yo) { throw new RuntimeException ( "a.ping()" ); @@ -40,7 +40,7 @@ public class director_enum_runme { } } -class MyFoo extends Foo { +class director_enum_MyFoo extends Foo { public Hallo say_hi(Hallo h) { return Hallo.yo; } diff --git a/Examples/test-suite/java/director_exception_runme.java b/Examples/test-suite/java/director_exception_runme.java index 90ff89f94..3d2958abb 100644 --- a/Examples/test-suite/java/director_exception_runme.java +++ b/Examples/test-suite/java/director_exception_runme.java @@ -14,7 +14,7 @@ public class director_exception_runme { public static void main(String argv[]) { - MyFoo a = new MyFoo(); + director_exception_MyFoo a = new director_exception_MyFoo(); Foo b = director_exception.launder(a); try { @@ -26,7 +26,7 @@ public class director_exception_runme { } } -class MyFoo extends Foo { +class director_exception_MyFoo extends Foo { public String ping() { throw new UnsupportedOperationException("Foo::ping not implemented"); } diff --git a/Examples/test-suite/java/director_protected_runme.java b/Examples/test-suite/java/director_protected_runme.java index 9c2280b01..464b4d4d9 100644 --- a/Examples/test-suite/java/director_protected_runme.java +++ b/Examples/test-suite/java/director_protected_runme.java @@ -17,19 +17,19 @@ public class director_protected_runme { Bar b = new Bar(); Foo f = b.create(); - FooBar fb = new FooBar(); - FooBar2 fb2 = new FooBar2(); + director_protected_FooBar fb = new director_protected_FooBar(); + director_protected_FooBar2 fb2 = new director_protected_FooBar2(); { String s = fb.used(); - if (!s.equals("Foo::pang();Bar::pong();Foo::pong();FooBar::ping();")) - throw new RuntimeException( "bad FooBar::used" ); + if (!s.equals("Foo::pang();Bar::pong();Foo::pong();director_protected_FooBar::ping();")) + throw new RuntimeException( "bad director_protected_FooBar::used" ); } { String s = fb2.used(); - if (!s.equals("FooBar2::pang();Bar::pong();Foo::pong();FooBar2::ping();")) - throw new RuntimeException( "bad FooBar2::used" ); + if (!s.equals("director_protected_FooBar2::pang();Bar::pong();Foo::pong();director_protected_FooBar2::ping();")) + throw new RuntimeException( "bad director_protected_FooBar2::used" ); } { @@ -46,8 +46,8 @@ public class director_protected_runme { { String s3 = fb.pong(); - if (!s3.equals("Bar::pong();Foo::pong();FooBar::ping();")) - throw new RuntimeException(" bad FooBar::pong" ); + if (!s3.equals("Bar::pong();Foo::pong();director_protected_FooBar::ping();")) + throw new RuntimeException(" bad director_protected_FooBar::pong" ); } try { @@ -68,18 +68,18 @@ public class director_protected_runme { } } -class FooBar extends Bar { +class director_protected_FooBar extends Bar { public String ping() { - return "FooBar::ping();"; + return "director_protected_FooBar::ping();"; } } -class FooBar2 extends Bar { +class director_protected_FooBar2 extends Bar { public String ping() { - return "FooBar2::ping();"; + return "director_protected_FooBar2::ping();"; } public String pang() { - return "FooBar2::pang();"; + return "director_protected_FooBar2::pang();"; } } diff --git a/Examples/test-suite/java/director_string_runme.java b/Examples/test-suite/java/director_string_runme.java index f553cdd84..e44ec0b1b 100644 --- a/Examples/test-suite/java/director_string_runme.java +++ b/Examples/test-suite/java/director_string_runme.java @@ -14,28 +14,28 @@ public class director_string_runme { public static void main(String argv[]) { - B b = new B("hello"); + director_string_B b = new director_string_B("hello"); String s; s = b.call_get_first(); - if (!s.equals("B.get_first")) throw new RuntimeException("call_get_first() failed"); + if (!s.equals("director_string_B.get_first")) throw new RuntimeException("call_get_first() failed"); s = b.call_get(0); - if (!s.equals("B.get: hello")) throw new RuntimeException("get(0) failed"); + if (!s.equals("director_string_B.get: hello")) throw new RuntimeException("get(0) failed"); } } -class B extends A { - public B(String first) { +class director_string_B extends A { + public director_string_B(String first) { super(first); } public String get_first() { - return "B.get_first"; + return "director_string_B.get_first"; } public String get(int n) { - return "B.get: " + super.get(n); + return "director_string_B.get: " + super.get(n); } } diff --git a/Examples/test-suite/java/director_unroll_runme.java b/Examples/test-suite/java/director_unroll_runme.java index e302ec7a3..9ae7edd62 100644 --- a/Examples/test-suite/java/director_unroll_runme.java +++ b/Examples/test-suite/java/director_unroll_runme.java @@ -14,21 +14,21 @@ public class director_unroll_runme { public static void main(String argv[]) { - MyFoo a = new MyFoo(); + director_unroll_MyFoo a = new director_unroll_MyFoo(); Bar b = new Bar(); b.set(a); Foo c = b.get(); - if (!c.ping().equals("MyFoo::ping()")) + if (!c.ping().equals("director_unroll_MyFoo::ping()")) throw new RuntimeException ( "c.ping()" ); } } -class MyFoo extends Foo { +class director_unroll_MyFoo extends Foo { public String ping() { - return "MyFoo::ping()"; + return "director_unroll_MyFoo::ping()"; } } diff --git a/Examples/test-suite/java/director_wombat_runme.java b/Examples/test-suite/java/director_wombat_runme.java index 8e88d6d3b..7a0bb6677 100644 --- a/Examples/test-suite/java/director_wombat_runme.java +++ b/Examples/test-suite/java/director_wombat_runme.java @@ -24,28 +24,28 @@ public class director_wombat_runme a.delete(); - a = new Foo_integers_derived(); + a = new director_wombat_Foo_integers_derived(); if ((retval = a.meth(62)) != 62 + 2) { throw new RuntimeException ("Test failed: retval = " + retval + ", expected 62 + 2"); } a.delete(); - a = new Foo_integers_derived_2(); + a = new director_wombat_Foo_integers_derived_2(); if ((retval = a.meth(37)) != 37) { throw new RuntimeException ("Test failed: retval = " + retval + ", expected 37"); } b.delete(); - b = new Bar_derived_1(); + b = new director_wombat_Bar_derived_1(); b.foo_meth(a, 0); } } -class Foo_integers_derived extends Foo_integers +class director_wombat_Foo_integers_derived extends Foo_integers { - public Foo_integers_derived() + public director_wombat_Foo_integers_derived() { super(); } @@ -56,25 +56,25 @@ class Foo_integers_derived extends Foo_integers } } -class Foo_integers_derived_2 extends Foo_integers +class director_wombat_Foo_integers_derived_2 extends Foo_integers { - public Foo_integers_derived_2() + public director_wombat_Foo_integers_derived_2() { super(); } } -class Bar_derived_1 extends Bar +class director_wombat_Bar_derived_1 extends Bar { - public Bar_derived_1() + public director_wombat_Bar_derived_1() { super(); } public void foo_meth(Foo_integers foo_obj, int param) { - if (!(foo_obj instanceof Foo_integers_derived_2)) { - throw new RuntimeException ("Test failed: foo_obj is not Foo_integers_derived_2, got " + foo_obj); + if (!(foo_obj instanceof director_wombat_Foo_integers_derived_2)) { + throw new RuntimeException ("Test failed: foo_obj is not director_wombat_Foo_integers_derived_2, got " + foo_obj); } } } diff --git a/Examples/test-suite/java/java_director_runme.java b/Examples/test-suite/java/java_director_runme.java index 850bf8bf3..dffba0ea5 100644 --- a/Examples/test-suite/java/java_director_runme.java +++ b/Examples/test-suite/java/java_director_runme.java @@ -56,20 +56,20 @@ public class java_director_runme { QuuxContainer qc = new QuuxContainer(); qc.push(new Quux("element 1")); - qc.push(new MyQuux("element 2")); - qc.push(new MyQuux("element 3")); + qc.push(new java_director_MyQuux("element 2")); + qc.push(new java_director_MyQuux("element 3")); qc.push(new Quux("element 4")); return qc; } } -class MyQuux extends Quux { - public MyQuux(String arg) { +class java_director_MyQuux extends Quux { + public java_director_MyQuux(String arg) { super(arg); } public String director_method() { - return "MyQuux:" + member(); + return "java_director_MyQuux:" + member(); } }