Wish Just add java class directly, like we add a module or an Activity

abilio486software

Active Member
Licensed User
Why we can't just add a .java class to project?
When we open the src folder to inspect the generated java code, it's clear that a .java class could easly interoperate with all other b4x, just like inlie java.
It would a great plus for B4A
For those that doesn't need to extend with Java, nothing would change, but for those that need more complexity or to workaround with libraries... It would be great!!!
 

ilan

Expert
Licensed User
Longtime User
if you want to code in java why do you want to use b4x?
I chose b4x because I hate java but I do think that the java object is important and that we can use here and there a java inline code but start using classes does not make sense use b4x ide anymore.
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
 

abilio486software

Active Member
Licensed User
if you want to code in java why do you want to use b4x?
I chose b4x because I hate java but I do think that the java object is important and that we can use here and there a java inline code but start using classes does not make sense use b4x ide anymore.
Hi, I don't hate Java but I confess that it's not my base language. I coded for years in C, now Objective-C for iOS, php for the web and B4A for Android.

But when I need to extend B4A and include a lot of external libraries and Sdk's, I need to rebuild libraries, I need to wrap and sometimes to use inline Java.

All of those tecnhics coud be easier, without the need of Android Studio or any other 3rd part java compiler.

Since the android world and development tools and libraries are mostly Java, we cannot ignore it, even wen you hate the Java language.

In my humild opinion, B4A have been workingin last years to turn easy the interopability with Java, giving us the ability to use inline Java, to have external Sdk's, so, consider that B4A has finished the job is pure ingenuity. And B4a leaders have done it because it was needed. Now it's time to improve, to continue that simplification in the process of integration of external Java code. It's not anything stange or new to B4A, It's exactly what's have being done for those users that need to work with external java resources.

B4A must continue it's path simplifying the interopability with Java and reducing the number of operations to 'just use Java' when you need or wish.

And why? Because B4A it's the best java tool, it compiles to a sandartized java, reducing the erros and the entropy of that language, so, productivity is very high when we use B4A but it's not productive when we need to work with external sdk's integrate it.

My wish is not only mine, everyone that needs to integrate external sdk's could have it's live easier.

Erel could create some preprocessor directives to guarantee the compatibilization with compiled java that B4A produces.

So, for me it's something possible and that would benefict the B4A comunity. All of them, because one day you will need that aditionaljar directive that a fool once have required to Erel.
 

Tobias Leininger

Member
Licensed User
Longtime User
I agree, that would actually be really useful. Right now I'm using JavaObject to interface with external libraries, but it's not the most convenient way.
Mixing Java and B4J would be perfect for me, as I like the Basic syntax for coding but not having an easy way to use SDKs is quite limiting.
 
Top