取从BlackBerry设备所有图像名 [英] Fetch all Image names from blackberry Device

查看:136
本文介绍了取从BlackBerry设备所有图像名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法通过存储在BlackBerry设备的所有图像进行迭代。我已经看到了这例如它迭代整个文件系统扫描每个文件。我想知道有没有做同样的任何便宜的方式。一些直接眺望图像目录?
谢谢

Is there any way to iterate through all images stored in a blackberry device. I have seen this example which iterates over the whole file system and scans each file. I am wondering is there any cheaper way of doing the same. Something that directly looks into the image directory? Thanks

推荐答案

使用 System.getProperty(字符串键)就可以获取设备图像存储迪尔斯:

Using System.getProperty(String key) it is possible to get image storage dirs on device:


  1. 键fileconn.dir.memorycard.photos。返回在SD卡上存储照片默认目录。它应该是这样的file:/// SD卡/黑莓/图片/。

  1. Key "fileconn.dir.memorycard.photos". Returns default directory for storing photos on SD Card. It should be something like "file:///SDCard/BlackBerry/pictures/".

键fileconn.dir.photos。返回的设备内存存储的图片默认目录。它应该是这样的file:///存储/ home / user中/图片/。

Key "fileconn.dir.photos". Returns default directory for storing pictures on device memory. It should be something like "file:///store/home/user/pictures/".

了解这些地方您可以将它们的内部只是iterage图像,而不是扫描整个文件系统。它可以使用列出图像<一个href=\"http://www.blackberry.com/developers/docs/5.0.0api/javax/microedition/io/file/FileConnection.html\"相对=nofollow> 的FileConnection API。具体来看看 list(字符串过滤器,布尔includeHidden)方法。

Knowing these locations you can just iterage images inside of them, rather than scanning the whole file system. It is possible to list images using the FileConnection API. Specifically take a look at list(String filter, boolean includeHidden) method.

这篇关于取从BlackBerry设备所有图像名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆