Android-code zu Holen Bild vom server und zeigt Sie in der Bildansicht

Hallo, ich weiß, wie zu Holen ein string aus jsonobject, aber meine Frage ist, wie zu Holen ein Bild aus der Rest-api und zeigt es an. Das Bild wird gespeichert als profile_image in jsonobject

Mein code:

 try {
                    JSONObject jsonObject = new JSONObject(response);
                    JSONObject object = jsonObject.getJSONObject("user");
                    String attr1 = object.getString("username");
                    data = "" + attr1;
                    textView15.setText(data);
                    if (object.has("profession")) {
                        String attr2 = object.getString("profession");
                        data2 = "" + attr2;
                        textView16.setText(data2);
                    }
                    if(object.has("company")){
                        String attr3 = object.getString("company");
                        data3 = "" + attr3;
                     textView38.setText(data3);
                    }

                    if(object.has("profile_image")) {
                        //what has to be done here
                    }
InformationsquelleAutor nikita Yalgi | 2016-02-18
Schreibe einen Kommentar