简体   繁体   English

如何获得由 Bitmap 形成的 ImageView 的初始 url

[英]How do I get the initial url of an ImageView formed from a Bitmap

Initially I created a bitmap from an external URL by using a bitmapFactory .最初,我使用 bitmapFactory 从外部 URL 创建了bitmapFactory I then put the bitmap in an Image view, like:然后我将 bitmap 放在图像视图中,例如:

 ImageView mim = (ImageView) findViewById(R.id.moviepix);
 String mi = "http://xxxxxxx.com/"+ result.movie_pix;
Bitmap bitmap = BitmapFactory.decodeStream((InputStream)new    URL(mi).getContent());
mim.setImageBitmap(bitmap);

Now I need to reverse engineer the url from the ImageView .现在我需要从ImageView对 url 进行逆向工程。

All help is appreciated.感谢所有帮助。

You can't, but you can however store the URL for later use with ImageView.setTag()您不能,但是您可以存储 URL 以供以后与 ImageView.setTag() 一起使用

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM