|
C++ edjLibrary SDK
|
Classes | |
| struct | FileAttributes |
| Represents the attributes associated with a stored file. More... | |
| struct | StorageResponse |
Response to the [edjx::storage::get] request. More... | |
| struct | StorageResponsePending |
| Placeholder for storage response used in streaming methods when the response is not available immediately. More... | |
Functions | |
| edjx::error::StorageError | get (StorageResponse &result, const std::string &bucket_id, const std::string &file_name) |
| Returns a file from the EDJX Object Store. More... | |
| edjx::error::StorageError | put (StorageResponse &result, const std::string &bucket_id, const std::string &file_name, const std::string &properties, const std::vector< uint8_t > contents) |
| Uploads a file to the EDJX Object Store. More... | |
| edjx::error::StorageError | put_streaming (StorageResponsePending &response_streaming, edjx::stream::WriteStream &write_stream, const std::string &bucket_id, const std::string &file_name, const std::string &properties) |
| Starts streaming a file to the EDJX Object Store. More... | |
| edjx::error::StorageError | remove (StorageResponse result, const std::string &bucket_id, const std::string &file_name) |
| Deletes the given file from the EDJX Object Store. More... | |
| edjx::error::StorageError | get_attributes (FileAttributes &result, const std::string &bucket_id, const std::string &file_name) |
| Returns attributes associated with the given file from the EDJX Object Store. More... | |
| edjx::error::StorageError | set_attributes (StorageResponse &result, const std::string &bucket_id, const std::string &file_name, const FileAttributes &attributes) |
| Sets the attributes associated with the given file. More... | |
| edjx::error::StorageError edjx::storage::get | ( | StorageResponse & | result, |
| const std::string & | bucket_id, | ||
| const std::string & | file_name | ||
| ) |
Returns a file from the EDJX Object Store.
| result | Result File |
| bucket_id | Bucket ID |
| file_name | File name |
| edjx::error::StorageError edjx::storage::get_attributes | ( | FileAttributes & | result, |
| const std::string & | bucket_id, | ||
| const std::string & | file_name | ||
| ) |
Returns attributes associated with the given file from the EDJX Object Store.
| result | Result of the operation |
| bucket_id | Bucket ID |
| file_name | File name |
| edjx::error::StorageError edjx::storage::put | ( | StorageResponse & | result, |
| const std::string & | bucket_id, | ||
| const std::string & | file_name, | ||
| const std::string & | properties, | ||
| const std::vector< uint8_t > | contents | ||
| ) |
Uploads a file to the EDJX Object Store.
| result | Result of the operation |
| bucket_id | Bucket ID |
| file_name | File name |
| properties | Properties |
| contents | File content |
| edjx::error::StorageError edjx::storage::put_streaming | ( | StorageResponsePending & | response_streaming, |
| edjx::stream::WriteStream & | write_stream, | ||
| const std::string & | bucket_id, | ||
| const std::string & | file_name, | ||
| const std::string & | properties | ||
| ) |
Starts streaming a file to the EDJX Object Store.
This method returns two objects, an edjx::stream::WriteStream and a StorageResponsePending. The edjx::stream::WriteStream is used to stream data, and the StorageResponsePending is a placeholder to retreive the StorageResponse response from the storage.
| response_streaming | If successful, this method will populate this argument with a placeholder for the storage response. |
| write_stream | If successful, this method will populate this argument with a write stream to be used for streaming the data. |
| bucket_id | Bucket ID (where to put the file) |
| file_name | File name |
| properties | Properties of the file |
| edjx::error::StorageError edjx::storage::remove | ( | StorageResponse | result, |
| const std::string & | bucket_id, | ||
| const std::string & | file_name | ||
| ) |
Deletes the given file from the EDJX Object Store.
| result | Result of the operation |
| bucket_id | Bucket ID |
| file_name | File Name |
| edjx::error::StorageError edjx::storage::set_attributes | ( | StorageResponse & | result, |
| const std::string & | bucket_id, | ||
| const std::string & | file_name, | ||
| const FileAttributes & | attributes | ||
| ) |
Sets the attributes associated with the given file.
This setting replaces the existing attributes.
| result | Result of the operation |
| bucket_id | Bucket ID |
| file_name | File name |
| attributes | File attributes |