// START: global functions: // function bar public void bar() { DebugFunctions.enter( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "26,0,32,0", "bar"); try { DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "28,4,28,22"); // declaration statement User u = new User(); DebugFunctions.var( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "28,4,28,22", "u", u); DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "30,4,30,20"); u.foo("a", 1, u); DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "31,4,31,10"); return; } finally { DebugFunctions.exit( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "26,0,32,0", "bar"); } }
@ActionLanguageEntityFunction(name = "baz") // function baz public String baz() { DebugFunctions.enter( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "20,4,23,4", "baz"); try { DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "21,8,21,29"); SystemFunctions.print("User:"******"alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "22,8,22,20"); return "BAZ"; } finally { DebugFunctions.exit( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "20,4,23,4", "baz"); } }
// entity functions // function foo @ActionLanguageEntityFunction(name = "foo") public void foo(String arg1, Integer arg2, User arg3) { DebugFunctions.enter( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "9,4,18,4", "foo"); DebugFunctions.var( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "9,4,18,4", "arg1", arg1); DebugFunctions.var( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "9,4,18,4", "arg2", arg2); DebugFunctions.var( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "9,4,18,4", "arg3", arg3); try { DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "10,8,10,28"); // declaration statement Integer integer = 3; DebugFunctions.var( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "10,8,10,28", "integer", integer); DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "11,8,11,37"); // declaration statement Integer result = (integer * 5); DebugFunctions.var( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "11,8,11,37", "result", result); DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "12,8,12,26"); // declaration statement Boolean b = false; DebugFunctions.var( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "12,8,12,26", "b", b); DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "13,8,17,8"); // if-statement if (b) { DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "14,12,14,18"); return; } else { DebugFunctions.step( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "16,12,16,18"); return; } } finally { DebugFunctions.exit( "alng_scripts/testcases/programs/test004_entitywithmultiplereturn.alng", "9,4,18,4", "foo"); } }