0

I have a java class which contain some user basic information now I want to pass this class object from JSNI method

 private native void publish(UserInfo userinfo) /*-{
 [email protected]::helloMethod(userinfo;)();
 }-*/

how can I achive this task please help me guys .....

2

1 Answer 1

3
private native void publish(UserInfo userinfo) /*-{
    [email protected]::helloMethod(Lcom/example/shared/UserInfo;)(userinfo);
}-*/;

I hope this is what you are looking for. Make sure to replace example class names with your fully-qualified-class names. For additional information refer JSNI basic.

Sign up to request clarification or add additional context in comments.

2 Comments

ajax thanks for your response but its showing referencing method unable to resolve
It wont be possible to address your query without actual code. Make sure method with same signature present in provided scope.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.