0
我如何獲得分析查詢的第一行對象。然後我會將它顯示爲一個ImageView。Parse.com ParseQuery從ParseQuery中檢索圖像並獲得第一個對象
ParseQuery query = new ParseQuery("Collection");
query.getInBackground("AN_OBJECT_ID_HERE",new GetCallback() {
public void done(ParseObject object, ParseException e) {
if (object == null) {
Log.d("test", "The object was not found...");
} else {
Log.d("test", "Retrieved the object.");
ParseFile fileObject = (ParseFile)object.get("images");
fileObject.getDataInBackground(new GetDataCallback() {
public void done(byte[] data, ParseException e) {
if (e == null) {
Log.d("test", "We've got data in data.");
// use data for something
} else {
Log.d("test", "There was a problem downloading the data.");
}
}
});
}
}
});
預先感謝您