mirror of https://github.com/apache/jclouds.git
changed entrySet to use more tested logic
git-svn-id: http://jclouds.googlecode.com/svn/trunk@476 3d8758e0-26b5-11de-8745-db77d3ebf521
This commit is contained in:
parent
1c16caa6f0
commit
412fb3a816
|
@ -115,10 +115,9 @@ public class LiveS3InputStreamMap extends BaseS3Map<InputStream> implements
|
|||
*/
|
||||
public Set<Map.Entry<String, InputStream>> entrySet() {
|
||||
Set<Map.Entry<String, InputStream>> entrySet = new HashSet<Map.Entry<String, InputStream>>();
|
||||
for (String key : keySet()) {
|
||||
InputStream input = get(key);
|
||||
if (input != null)
|
||||
entrySet.add(new Entry(key, input));
|
||||
for (S3Object object : getAllObjects()) {
|
||||
entrySet.add(new Entry(object.getKey(), (InputStream) object
|
||||
.getData()));
|
||||
}
|
||||
return entrySet;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue