2016-07-14 7 views
-2

私は1つのAPIを持っている、それはこれを使用すると、URLのウッシングからの画像を設定することができる方法である、あなたはImageView.Thanksにそのイメージを設定することができますどのように私を示唆response.Canとして `AndroidでVolleyを使用してImageViewまたはNetworkImageViewに画像ファイルを設定するにはどうすればよいですか?

private static final String URL = "http://someapi"; 
setting images from api 
person.setThumbnailUrl(Picasso.with(getApplicationContext()).load((File) items.get("profileImageLargeUrl"))); 
+2

ご質問は明確ではありません。 –

+0

ご質問を明確にする – Jas

答えて

0

をイメージを与えますピカソ(あなたがボレーを必要としない):

ImageView picture = (ImageView) findViewById(R.id.my_image); 

String urlImage = "https://..."; 
... 

Picasso.with(this) 
       .load(urlImage) 
       .into(picture); 

また、あなたはスピナー、フィット、またはerrorImageのように、他のオプションを設定することができます。

.placeholder(R.drawable.progress_animation) 
.error(R.drawable.error_image) 
.fit() 
関連する問題