Android Question Best Solution for create a library to use HttpJob

Alberto Iglesias

Well-Known Member
Licensed User
Hello everyone,

I will create some library .b4xlib to make requests to make life easy on both platforms.

What's the best solution for create this?

In my mind, I think for to this is create a service on .b4xlib for B4A and Module for B4i, is that better option?

B4X:
Dim j As HttpJob
j.Initialize("", Me)
j.Download(strEndpoint)
       
Wait For (j) JobDone(j As HttpJob)
If j.Success Then
End If
 

Alberto Iglesias

Well-Known Member
Licensed User
Because we have some code sharing for both platforms and supose you have a method in this shared code to get informations from webservice.

for B4i is OK, you can put on the same shared code (module), but for B4A you need a activity to get the response.
 

Alberto Iglesias

Well-Known Member
Licensed User
Great! And thinking about this class, do you know if is a good idea to create a .b4xlib with this for using on both platforms?
 

Erel

Administrator
Staff member
Licensed User
Top