|
typedef jau::function< bool(AsyncStreamResponse &, const uint8_t *, size_t, bool)> | AsyncStreamConsumerFunc |
| Asynchronous stream consumer function.
|
|
using | AsyncStreamResponseRef = std::shared_ptr<AsyncStreamResponse> |
|
typedef jau::ringbuffer< uint8_t, size_t > | ByteRingbuffer |
|
using | net_tk_handle = void* |
|
typedef jau::ordered_atomic< io_result_t, std::memory_order_relaxed > | relaxed_atomic_io_result_t |
|
typedef std::basic_string< char, std::char_traits< char >, jau::callocator_sec< char > > | secure_string |
|
template<typename T> |
using | secure_vector = std::vector<T, jau::callocator_sec<T>> |
|
typedef jau::function< bool(secure_vector< uint8_t > &, bool)> | StreamConsumerFunc |
| Stream consumer function.
|
|
typedef jau::function< bool(SyncStreamResponse &, const uint8_t *, size_t, bool)> | SyncStreamConsumerFunc |
| Synchronous stream consumer function.
|
|
using | SyncStreamResponseRef = std::shared_ptr<SyncStreamResponse> |
|
|
net_tk_handle | create_net_tk_handle () noexcept |
| creates a reusable handle, free with free_net_tk_handle() after use.
|
|
void | free_net_tk_handle (net_tk_handle handle) noexcept |
| frees a handle after use created by create_net_tk_handle()
|
|
| JAU_MAKE_BITFIELD_ENUM_STRING (iostate, goodbit, badbit, eofbit, failbit, timeout) |
|
std::ostream & | operator<< (std::ostream &os, io_result_t v) |
|
void | print_stats (const std::string &prefix, const uint64_t &out_bytes_total, const jau::fraction_i64 &td) noexcept |
|
uint64_t | read_file (const std::string &input_file, secure_vector< uint8_t > &buffer, const StreamConsumerFunc &consumer_fn) noexcept |
| Synchronous byte input stream reader from given file path using the given StreamConsumerFunc consumer_fn.
|
|
uint64_t | read_stream (ByteInStream &in, secure_vector< uint8_t > &buffer, const StreamConsumerFunc &consumer_fn) noexcept |
| Synchronous byte input stream reader using the given StreamConsumerFunc consumer_fn.
|
|
uint64_t | read_stream (ByteInStream &in, secure_vector< uint8_t > &buffer1, secure_vector< uint8_t > &buffer2, const StreamConsumerFunc &consumer_fn) noexcept |
| Synchronous double-buffered byte input stream reader using the given StreamConsumerFunc consumer_fn.
|
|
uint64_t | read_url_stream (const std::string &url, secure_vector< uint8_t > &buffer, const StreamConsumerFunc &consumer_fn) noexcept |
| Synchronous URL stream reader using the given StreamConsumerFunc consumer_fn.
|
|
AsyncStreamResponseRef | read_url_stream_async (net_tk_handle handle, const std::string &url, http::PostRequestPtr httpPostReq, ByteRingbuffer *buffer, const AsyncStreamConsumerFunc &consumer_fn) noexcept |
| Asynchronous URL stream reader using the given AsyncStreamConsumerFunc consumer_fn.
|
|
SyncStreamResponseRef | read_url_stream_sync (net_tk_handle handle, const std::string &url, http::PostRequestPtr httpPostReq, ByteRingbuffer *buffer, const SyncStreamConsumerFunc &consumer_fn) noexcept |
| Synchronous URL stream reader using the given SyncStreamConsumerFunc consumer_fn.
|
|
std::unique_ptr< ByteInStream > | to_ByteInStream (const std::string &path_or_uri, jau::fraction_i64 timeout=20_s) noexcept |
| Parses the given path_or_uri, if it matches a supported protocol, see jau::io::uri::protocol_supported(), but is not a local file, see jau::io::uri::is_local_file_protocol(), ByteInStream_URL is being attempted.
|
|
std::string | toString (io_result_t v) noexcept |
|