Hyperspace::REST::PropertyCollection Class Reference

Convenience RESTful-compliant Collection based on QObject's properties. More...

Inheritance diagram for Hyperspace::REST::PropertyCollection:

Protected Member Functions

virtual void keyValuePut (const QByteArray &waveId, const ByteArrayHash &attributes, const QVariantMap &data) Q_DECL_OVERRIDE
 Implement Wave PUT method with a Key/Value pair. More...
 
virtual void keyValuePost (const QByteArray &waveId, const ByteArrayHash &attributes, const QVariantMap &data) Q_DECL_OVERRIDE
 Implement Wave POST method with a Key/Value pair. More...
 
virtual void keyValueGet (const QByteArray &waveId, const ByteArrayHash &attributes, const QVariantMap &data) Q_DECL_OVERRIDE
 Implement Wave GET method with a Key/Value pair. More...
 
- Protected Member Functions inherited from Hyperspace::REST::KeyValueCollection
void sendKeyValueRebound (const KeyValueRebound &rebound)
 Sends a rebound with a Key/Value payload. More...
 
virtual void keyValueDelete (const QByteArray &waveId, const ByteArrayHash &attributes, const QVariantMap &data)=0
 Implement Wave DELETE method with a Key/Value pair. More...
 
virtual void get (const QByteArray &waveId, const ByteArrayHash &attributes, const QByteArray &payload) Q_DECL_OVERRIDE Q_DECL_FINAL
 Implement Wave GET method. More...
 
virtual void httpDelete (const QByteArray &waveId, const ByteArrayHash &attributes, const QByteArray &payload) Q_DECL_OVERRIDE Q_DECL_FINAL
 Implement Wave DELETE method. More...
 
virtual void post (const QByteArray &waveId, const ByteArrayHash &attributes, const QByteArray &payload) Q_DECL_OVERRIDE Q_DECL_FINAL
 Implement Wave POST method. More...
 
virtual void put (const QByteArray &waveId, const ByteArrayHash &attributes, const QByteArray &payload) Q_DECL_OVERRIDE Q_DECL_FINAL
 Implement Wave PUT method. More...
 
- Protected Member Functions inherited from Hyperspace::REST::Collection
ResourceFactoryfactory () const
 
virtual ResourceloadResource (const QByteArray &id)=0
 

Additional Inherited Members

- Public Member Functions inherited from Hyperspace::REST::KeyValueCollection
 KeyValueCollection (const QByteArray &path, ResourceFactory *factory)
 
- Public Member Functions inherited from Hyperspace::REST::Collection
 Collection (const QByteArray &path, ResourceFactory *factory)
 
QByteArray path () const
 
void deleteResource (const QByteArray &waveId, const QByteArray &resourceId, const ByteArrayHash &attributes, const QByteArray &payload)
 
void getResource (const QByteArray &waveId, const QByteArray &resourceId, const ByteArrayHash &attributes, const QByteArray &payload)
 
void postResource (const QByteArray &waveId, const QByteArray &resourceId, const ByteArrayHash &attributes, const QByteArray &payload)
 
void putResource (const QByteArray &waveId, const QByteArray &resourceId, const ByteArrayHash &attributes, const QByteArray &payload)
 
void head (const QByteArray &waveId, const ByteArrayHash &attributes, const QByteArray &payload) Q_DECL_OVERRIDE
 Sends back a BadRequest Rebound by default. More...
 
- Protected Slots inherited from Hyperspace::AbstractWaveTarget
void sendRebound (const Hyperspace::Rebound &rebound)
 Send a rebound for a received wave. More...
 

Detailed Description

Convenience RESTful-compliant Collection based on QObject's properties.

PropertyCollection implements Wave's methods via its QObject properties. To learn more about the relationship between Hyperspace and QObject, please read Hyperspace and QObject.

See also
Hyperspace::REST::KeyValueCollection

Member Function Documentation

void Hyperspace::REST::PropertyCollection::keyValuePut ( const QByteArray &  waveId,
const ByteArrayHash &  attributes,
const QVariantMap &  data 
)
protectedvirtual

Implement Wave PUT method with a Key/Value pair.

Reimplement this method to act when a PUT Wave is sent.

waveId The internal waveId. Must be used to construct the Rebound. attributes The wave's attributes. data The payload as a Key/Value map.

Implements Hyperspace::REST::KeyValueCollection.

Reimplemented in Hyperspace::REST::FixedCachedCollection.

void Hyperspace::REST::PropertyCollection::keyValuePost ( const QByteArray &  waveId,
const ByteArrayHash &  attributes,
const QVariantMap &  data 
)
protectedvirtual

Implement Wave POST method with a Key/Value pair.

Reimplement this method to act when a POST Wave is sent.

waveId The internal waveId. Must be used to construct the Rebound. attributes The wave's attributes. data The payload as a Key/Value map.

Implements Hyperspace::REST::KeyValueCollection.

Reimplemented in Hyperspace::REST::FixedCachedCollection.

void Hyperspace::REST::PropertyCollection::keyValueGet ( const QByteArray &  waveId,
const ByteArrayHash &  attributes,
const QVariantMap &  data 
)
protectedvirtual

Implement Wave GET method with a Key/Value pair.

Reimplement this method to act when a GET Wave is sent.

waveId The internal waveId. Must be used to construct the Rebound. attributes The wave's attributes. data The payload as a Key/Value map.

Implements Hyperspace::REST::KeyValueCollection.