Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing a guide for invoking Ballerina code from Java #23451

Open
kaviththiranga opened this issue May 23, 2020 · 1 comment
Open

Missing a guide for invoking Ballerina code from Java #23451

kaviththiranga opened this issue May 23, 2020 · 1 comment
Assignees
Labels
Area/JavaInterop Java interoperability in Ballerina Team/jBallerina All the issues related to BIR, JVM backend code generation and runtime Type/Docs Type/Task

Comments

@kaviththiranga
Copy link
Contributor

https://ballerina.io/learn/how-to-call-java-code-from-ballerina/

In Java interop guide, it is mentioned that we can invoke Ballerina code from Java side. But there is no any guide available for it.

@sameerajayasoma sameerajayasoma added the Area/JavaInterop Java interoperability in Ballerina label May 23, 2020
@manuranga
Copy link
Contributor

Yes we do need documentation on this. But since this will have both java and ballerina code, we'll have to do a Learn page instead a BBG.
Also just to clarify, we currently only provide an API to invoke instance methods, but not static functions.
Just in case there is an example .https://github.com/manuranga/ballerina/blob/6a5896b00116af71b1bb236177ab7c2fae61e5be/tests/jballerina-unit-test/src/test/java/org/ballerinalang/nativeimpl/jvm/tests/Timer.java#L38

@manuranga manuranga added the Team/jBallerina All the issues related to BIR, JVM backend code generation and runtime label Oct 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area/JavaInterop Java interoperability in Ballerina Team/jBallerina All the issues related to BIR, JVM backend code generation and runtime Type/Docs Type/Task
Projects
None yet
Development

No branches or pull requests

4 participants