6 function create_iface
() {
8 echo "public interface Iface_$COUNT {"
9 for i
in `seq 1 $COUNT`;
11 echo " int Method_$i (int a, int b, int c, int d);"
18 function create_impl
() {
20 echo "public class Impl_$COUNT : Iface_$COUNT {"
21 for i
in `seq 1 $COUNT`;
23 echo " public virtual int Method_$i (int a, int b, int c, int d) { return a - b - c - d + ${i}; }"
30 function create_static_part
() {
32 echo " static Iface_$IFACE var_$IFACE = new Impl_$IFACE ();"
33 echo " static int Test_$IFACE () {
38 for i
in `seq 1 $IFACE`;
40 echo " if ((r = var_${IFACE}.Method_$i (10,5,3,2)) != ${i}) {
41 Console.WriteLine(\"iface $IFACE method $i returned {0}\", r);
52 function test_iface
() {
54 echo " res |= Test_$IFACE ();"
58 ####Part that split the output
64 for i
in `seq $LOW $HIGH`;
78 for i
in `seq $LOW $HIGH`;
85 public static int Main ()
90 for i
in `seq $LOW $HIGH`;