3 import java.util.ArrayList;
5 public class TestClass implements TestClassInterface {
12 private String stringC;
13 private List<CallBackInterfaceWithCallBack> cblist;
26 public TestClass(int _int, float _float, String _string) {
35 //public void registerCallback(CallBackInterface _cb) {
36 public void registerCallback(CallBackInterfaceWithCallBack _cb) {
39 System.out.println("Registering callback object!");
43 /*public void registerCallback(CallBackInterfaceWithCallBack[] _cb) {
45 for (CallBackInterfaceWithCallBack cb : _cb) {
47 System.out.println("Registering callback object!");
52 public int callBack() {
55 for (CallBackInterfaceWithCallBack cb : cblist) {
56 sum = sum + cb.printInt();
63 public byte getByte(byte in) {
69 public short getShort(short in) {
75 public long getLong(long in) {
81 public float getFloat(float in) {
87 public double getDouble(double in) {
93 public boolean getBoolean(boolean in) {
99 public char getChar(char in) {
106 public byte[] getByteArray(byte[] in) {
112 public short[] getShortArray(short[] in) {
118 public long[] getLongArray(long[] in) {
124 public float[] getFloatArray(float[] in) {
130 public double[] getDoubleArray(double[] in) {
136 public boolean[] getBooleanArray(boolean[] in) {
142 public char[] getCharArray(char[] in) {
149 public List<Byte> getByteList(List<Byte> in) {
155 public List<Short> getShortList(List<Short> in) {
161 public List<Long> getLongList(List<Long> in) {
167 public List<Float> getFloatList(List<Float> in) {
173 public List<Double> getDoubleList(List<Double> in) {
179 public List<Boolean> getBooleanList(List<Boolean> in) {
185 public List<Character> getCharList(List<Character> in) {
198 public void setA(int _int) {
204 public void setB(float _float) {
210 public void setC(String _string) {
217 public Enum handleEnum(Enum en) {
219 System.out.println("Enum: " + en);
225 public Enum[] handleEnumArray(Enum[] en) {
228 System.out.println("Enum: " + e);
235 public List<Enum> handleEnumList(List<Enum> en) {
238 System.out.println("Enum: " + e);
246 public Struct handleStruct(Struct str) {
248 System.out.println("Name: " + str.name);
249 System.out.println("Value: " + str.value);
250 System.out.println("Year: " + str.year);
253 Struct test = new Struct();
254 test.name = "Anonymous";
264 /*public Struct[] handleStruct(Struct[] data) {
266 for (Struct str : data) {
267 System.out.println("Name: " + str.name);
268 System.out.println("Value: " + str.value);
269 System.out.println("Year: " + str.year);
272 Struct test = new Struct();
273 test.name = "Anonymous";
284 public String sumArray(String[] newA) {
287 for (String i : newA)
293 public int setAndGetA(int newA) {
300 public int setACAndGetA(String newC, int newA) {