Having the ability to write inline java code and its simple access mechanism, via JavaObject, is a wonderful addition to the language.
However, whatever code you have within the hash tags [#If Java ... #End if] is added to the bottom end of the class in the Java generated source.
I would like to see the ability to add java code in situ, ie the code would stay where it is by using hash tags like these, for example.
#If JavaInSitu
#End if
BA4 would ignore the code within those tags. They would be removed by the pre-processor (as it is now for #If Java tags) and therefore the Java code would be then part of the source and compiled by the Java compiler.
It would be a tremendous help to be able to mix this way, within the same sub, b4a code and Java.
However, whatever code you have within the hash tags [#If Java ... #End if] is added to the bottom end of the class in the Java generated source.
I would like to see the ability to add java code in situ, ie the code would stay where it is by using hash tags like these, for example.
#If JavaInSitu
#End if
BA4 would ignore the code within those tags. They would be removed by the pre-processor (as it is now for #If Java tags) and therefore the Java code would be then part of the source and compiled by the Java compiler.
It would be a tremendous help to be able to mix this way, within the same sub, b4a code and Java.