3#include <iolink/IOLinkAPI.h>
5#include <iolink/storage/HTTPHeaders.h>
6#include <iolink/storage/RandomAccess.h>
7#include <iolink/storage/StreamAccess.h>
33 static std::shared_ptr<StreamAccess>
allocate(
size_t size = 0);
42 static std::shared_ptr<StreamAccess>
copyInMemory(std::shared_ptr<StreamAccess> streamAccess);
49 static std::shared_ptr<StreamAccess>
fromStdStream(std::shared_ptr<std::istream> stream);
56 static std::shared_ptr<StreamAccess>
fromStdStream(std::shared_ptr<std::ostream> stream);
63 static std::shared_ptr<StreamAccess>
fromStdStream(std::shared_ptr<std::iostream> stream);
71 static std::shared_ptr<std::istream>
toStdIStream(std::shared_ptr<StreamAccess> streamAccess);
79 static std::shared_ptr<std::ostream>
toStdOStream(std::shared_ptr<StreamAccess> streamAccess);
88 static std::shared_ptr<std::iostream>
toStdStream(std::shared_ptr<StreamAccess> streamAccess);
95 static std::shared_ptr<StreamAccess>
openFileRead(
const std::string& filePath);
102 static std::shared_ptr<StreamAccess>
openFileWrite(
const std::string& filePath);
110 static std::shared_ptr<StreamAccess>
openFile(
const std::string& filePath);
132 const std::string& method,
142 static std::shared_ptr<StreamAccess>
fromRandomAccess(std::shared_ptr<RandomAccess> randomAccess);
A factory to create StreamAccess instances from various ressources.
Definition: StreamAccessFactory.h:20
static std::shared_ptr< StreamAccess > openFileWrite(const std::string &filePath)
Create a stream that can write data to a file.
static std::shared_ptr< StreamAccess > openFileRead(const std::string &filePath)
Create a stream that can read data from a file.
static std::shared_ptr< StreamAccess > allocate(size_t size=0)
Create a stream in local memory.
static std::shared_ptr< StreamAccess > fromStdStream(std::shared_ptr< std::iostream > stream)
Create a stream storage from a standard I/O stream.
static std::shared_ptr< std::istream > toStdIStream(std::shared_ptr< StreamAccess > streamAccess)
Create a standard Input stream from a StreamAccess.
static std::shared_ptr< StreamAccess > openURIWrite(const Uri &uri)
Create a stream that can write data to an URI.
static std::shared_ptr< std::ostream > toStdOStream(std::shared_ptr< StreamAccess > streamAccess)
Create a standard Output stream from a StreamAccess.
static std::shared_ptr< StreamAccess > fromStdStream(std::shared_ptr< std::istream > stream)
Create a stream storage from a standard input stream.
static std::shared_ptr< StreamAccess > openHTTPWrite(const Uri &uri, const std::string &method, const HTTPHeaders &headers)
Create a stream that can post data to an HTTP URI.
static std::shared_ptr< StreamAccess > copyInMemory(std::shared_ptr< StreamAccess > streamAccess)
Load a stream into local memory.
static std::shared_ptr< std::iostream > toStdStream(std::shared_ptr< StreamAccess > streamAccess)
Create a standard Input/Output stream from a StreamAccess.
static std::shared_ptr< StreamAccess > fromRandomAccess(std::shared_ptr< RandomAccess > randomAccess)
Create a StreamAccess that will delegate to a RandomAccess.
static std::shared_ptr< StreamAccess > fromStdStream(std::shared_ptr< std::ostream > stream)
Create a stream storage from a standard output stream.
static std::shared_ptr< StreamAccess > openFile(const std::string &filePath)
Create a stream that can read and write data from/to a file.
Class modeling universal resource identifier.
Definition: Uri.h:14
All IOLink symbols are enclosed in this namespace.
Definition: ArrayX.h:8