thiagolocatelli / parse4j

Java Library to deal with Parse (parse.com) REST API
http://thiagolocatelli.github.io/parse4j
143 stars 117 forks source link

ParseQuery: whereMatchesKeyInQuery method #26

Closed Jinoooo closed 9 years ago

Jinoooo commented 9 years ago

First thanks for building this library! Works well so far, however it seems the whereMatchesKeyInQuery doesn't work, throwing the following exception. I tried with class types other than User & Installation having the same outcome. Here is my code: public void queryUserWithInstallation() {
ParseQuery query = ParseQuery.getQuery("_Installation"); ParseQuery userQuery = ParseQuery.getQuery("_User"); query.whereMatchesKeyInQuery("user", "objectId", userQuery); query.findInBackground(new FindCallback() { @Override public void done(List list, ParseException parseException) { // TODO Auto-generated method stub } }); } 03:24:30.243 [pool-1-thread-1] ERROR org.parse4j.util.ParseEncoder - Object type not decoded: org.parse4j.ParseQuery Exception in thread "pool-1-thread-1" java.lang.IllegalArgumentException: Invalid type for ParseObject: class org.parse4j.ParseQuery at org.parse4j.util.ParseEncoder.encode(ParseEncoder.java:128) at org.parse4j.util.ParseEncoder.encode(ParseEncoder.java:64) at org.parse4j.util.ParseEncoder.encode(ParseEncoder.java:82) at org.parse4j.util.ParseEncoder.encode(ParseEncoder.java:82) at org.parse4j.ParseQuery.toREST(ParseQuery.java:334) at org.parse4j.ParseQuery.find(ParseQuery.java:470) at org.parse4j.ParseQuery$FindInBackgroundThread.run(ParseQuery.java:591) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) at java.lang.Thread.run(Thread.java:695)

thiagolocatelli commented 9 years ago

Fixed in 1.4