org.jclouds.openstack.swift.domain.internal
Class SwiftObjectImpl

java.lang.Object
  extended by org.jclouds.http.internal.PayloadEnclosingImpl
      extended by org.jclouds.openstack.swift.domain.internal.SwiftObjectImpl
All Implemented Interfaces:
Comparable<SwiftObject>, PayloadEnclosing, SwiftObject

public class SwiftObjectImpl
extends PayloadEnclosingImpl
implements SwiftObject, Comparable<SwiftObject>

Default Implementation of SwiftObject.

Author:
Adrian Cole

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.jclouds.openstack.swift.domain.SwiftObject
SwiftObject.Factory
 
Field Summary
 
Fields inherited from class org.jclouds.http.internal.PayloadEnclosingImpl
payload
 
Constructor Summary
SwiftObjectImpl(MutableObjectInfoWithMetadata info)
           
 
Method Summary
 int compareTo(SwiftObject o)
          
 boolean equals(Object obj)
           
 com.google.common.collect.Multimap<String,String> getAllHeaders()
          
 MutableObjectInfoWithMetadata getInfo()
          
 int hashCode()
           
 void setAllHeaders(com.google.common.collect.Multimap<String,String> allHeaders)
          
 void setPayload(Payload data)
          Sets payload for the request or the content from the response.
 String toString()
           
 
Methods inherited from class org.jclouds.http.internal.PayloadEnclosingImpl
getPayload, setPayload, setPayload, setPayload, setPayload
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.jclouds.io.PayloadEnclosing
getPayload, setPayload, setPayload, setPayload, setPayload
 

Constructor Detail

SwiftObjectImpl

@Inject
public SwiftObjectImpl(MutableObjectInfoWithMetadata info)
Method Detail

getInfo

public MutableObjectInfoWithMetadata getInfo()

Specified by:
getInfo in interface SwiftObject
Returns:
System and User metadata relevant to this object.

getAllHeaders

public com.google.common.collect.Multimap<String,String> getAllHeaders()

Specified by:
getAllHeaders in interface SwiftObject

setAllHeaders

public void setAllHeaders(com.google.common.collect.Multimap<String,String> allHeaders)

Specified by:
setAllHeaders in interface SwiftObject

compareTo

public int compareTo(SwiftObject o)

Specified by:
compareTo in interface Comparable<SwiftObject>

hashCode

public int hashCode()
Overrides:
hashCode in class PayloadEnclosingImpl

equals

public boolean equals(Object obj)
Overrides:
equals in class PayloadEnclosingImpl

toString

public String toString()
Overrides:
toString in class Object

setPayload

public void setPayload(Payload data)
Description copied from class: PayloadEnclosingImpl
Sets payload for the request or the content from the response. If size isn't set, this will attempt to discover it.

Specified by:
setPayload in interface PayloadEnclosing
Overrides:
setPayload in class PayloadEnclosingImpl
Parameters:
data - typically InputStream for downloads, or File, byte [], String, or InputStream for uploads.


Copyright © 2009-2011 jclouds. All Rights Reserved.