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

Accessing Kotlin Extension from Java #6

Closed
akbarsha03 opened this issue May 4, 2017 · 1 comment
Closed

Accessing Kotlin Extension from Java #6

akbarsha03 opened this issue May 4, 2017 · 1 comment

Comments

@akbarsha03
Copy link

akbarsha03 commented May 4, 2017

Do I have to always pass an object from Java to access the kotlin extenion like below?

final ChatConversationsRealm F = new ChatConversationsRealm();
List<ChatConversationsRealm> xx = RealmExtensionsKt.queryAll(F);

Is there any way to access it without creating an object but just by specifying the type like RealmExtensionsKt.queryAll(ChatConversationsRealm.class)?

@vicpinm
Copy link
Owner

vicpinm commented May 4, 2017

I'm afraid it is not possible right now. You will need to create a new instance of your object to perform your query. I'm aware of this and I could find another way to perform the queries in the future if I have enough time. If you want to propose any solution, you are welcome to do a pull request.

@vicpinm vicpinm closed this as completed May 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants