* Returns a map containing all key-value pairs for the given FQN, or null
* if the node is not present.
*/
public Map get(Fqn name) throws Exception
{
GetStreamResponse response = connection.getStream(getBucket(), key(name));
try
{
if (trace)
{
log.trace("get " + name + " response=" + response);
}
if (response.isNotFound())
return null;
if (!response.isOk())
throw new S3Exception("get failed " + response);
BufferedInputStream is = new BufferedInputStream(response.getInputStream());
Map map = (Map) getMarshaller().objectFromStream(is);
response.release();
return map;
}
finally
{
response.release();
}
}