Jaykishan
Jaykishan

Reputation: 1499

How to use java on client-side code of Worklight?

I'm working with a worklight project (Hybrid application),
Currently i'm calling server-side adapter with JavaScript and handling fetched data with JavaScript and having many problem of parsing data.
Can anybody help me to use JAVA at client-side programming(Anyhow if possible)?

Upvotes: 0

Views: 605

Answers (2)

jnortey
jnortey

Reputation: 1625

You cannot use Java for client side programming. If you're creating an Android application, then of course you can implement whatever you want in java and then use cordova to pass your data down, but it doesn't look like thats what you want to do.

I would take a different approach though. You say you're using a server side adapter, and adapters can use custom Java code. You should use your server side adapter to get your data from the backend, then add your custom java code and parse the data in the adapter. Once your data is parsed and in a consumable format, then you can pass the data from the adapter to the client.

Here is the documentation for using java in an adapter.

Upvotes: 1

Ken Vernaillen
Ken Vernaillen

Reputation: 859

In Worklight you can develop by using different APIs: JavaScript client-side API for hybrid apps Objective-C client-side API for native iOS apps Java™ client-side API for native Android apps Java client-side API for Java Platform, Micro Edition (Java ME) apps You can also use your own custom libraries or third-party libraries when you create mobile applications in Worklight Studio.

src: http://pic.dhe.ibm.com/infocenter/wrklight/v5r0m6/index.jsp?topic=%2Fcom.ibm.worklight.help.doc%2Fdevref%2Fc_creating_client_side_of_app.html

More information about Java client-side programming:

Upvotes: 1

Related Questions