Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Bump v0.13.0: jau::io changes for robust and simplified ByteInStream usage ↵v0.13.0 | Sven Gothel | 2022-06-04 | 9 | -77/+595 |
| | | | | | | | | | | | | | | | | | | sourced as file or via remote URL * `string_util.hpp`: Add `jau::to_string()` support for `std::string` and `std::string_view` as well as for `std::vector<T>` lists * Add namespace `jau::io::uri`, limited URI scheme functionality to query whether implementation may handle the protocol. - Query *libcurl* supported protocols at runtime - Test for local file protocol - Test whether protocol in given uri is supported by *libcurl* * `jau::io::read_url_stream()`, sync and async, return immediately if protocol in given url is not supportet - async variant returns `std::unique_ptr<std::thread>`, where a nullptr is used for no support * `jau::io::ByteInStream_File` recognizes the local file protocol and cuts off `file://` is used. - Fix: Recognition of a non-existing path, unaccessbile path or non-file case properly * `jau::io::ByteInStream_URL` recognizes a non supported protocol via async `jau::io::read_url_stream()`. * Added convenient `jau::io::std::unique_ptr<ByteInStream> to_ByteInStream()` - Returning either a `jau::io::ByteInStream_File`, `jau::io::ByteInStream_URL` or nullptr if `path_or_url` is not supported * Make Java class `org.jau.ney.Uri` standalone, drop dependencies for easier reusage. | ||||
* | Fix ByteInStream_Recorder::start_recording(): Always reset m_buffer, ↵ | Sven Gothel | 2022-06-03 | 1 | -3/+1 |
| | | | | regardless whether its recording or not. | ||||
* | README v0.12.0v0.12.0 | Sven Gothel | 2022-06-03 | 1 | -0/+8 |
| | |||||
* | JNI: Add convert_jlist_string_to_vector(), the reverse function of ↵ | Sven Gothel | 2022-06-03 | 2 | -0/+23 |
| | | | | convert_vector_string_to_jarraylist() | ||||
* | helper_jni.*: Add getObjectFieldValue(), getStringFieldValue(), ↵ | Sven Gothel | 2022-06-02 | 2 | -0/+52 |
| | | | | getLongFieldValue() and convert_vector_string_to_jarraylist() | ||||
* | ByteInStream_URL, ByteInStream_Feed: Pass fraction by reference | Sven Gothel | 2022-06-02 | 2 | -4/+4 |
| | |||||
* | DONT_USE_RTTI: Explicitly set '-frtti' option if enabled to be sure | Sven Gothel | 2022-05-30 | 1 | -0/+5 |
| | | | | Note: STATIC_LINKER_FLAG is unused, as it uses 'ar' and should just obey the object files setup. | ||||
* | io::read_url_stream(): Fix using std::string -> char * in ERR_PRINT | Sven Gothel | 2022-05-30 | 1 | -4/+4 |
| | |||||
* | ByteInStream_[URL|Feed]::close(): Only change m_result if still NONE, then ↵v0.11.2 | Sven Gothel | 2022-05-29 | 1 | -2/+6 |
| | | | | write SUCCESS (close success, no error) | ||||
* | README: v0.11.1v0.11.1 | Sven Gothel | 2022-05-29 | 1 | -0/+9 |
| | |||||
* | test_bytestream01: test22_copy_fed_irq(): interrupt early after 1024 bytes ↵ | Sven Gothel | 2022-05-29 | 1 | -6/+3 |
| | | | | already, so we have 2 different irq points. | ||||
* | io::read_url_stream: Fix content_length (-1 == unknown), add consume_header ↵ | Sven Gothel | 2022-05-29 | 5 | -58/+428 |
| | | | | | | | | | | | | | | | | | | | | | | w/ response_code for errors >= 400 and buffer.interruptReader() - curl replies -1 for unknown content_length - also consume the curl header to detect response_code errors >= 400 (404 not found) - in case of an error, we need to interrupt the ringbuffer-reader thread -> buffer.interruptReader(), otherwise the thread would be blocked until timeout and renders application to not be responsive. - interruptReader() has been added for the synchronous- and asynchronous read_url_stream() functions - interruptReader() has been exposed as ByteInStream_Feed::interruptReader() and added to ByteInStream_Feed::set_eof(). - the above is tested via test_iostream01 for synchronous- and asynchronous read_url_stream() functions using a non-existing URL entity - the above is tested via test_bytestream01 for ByteInStream_URL using a non-existing URL entity and for and ByteInStream_Feed having the feeder thread prematurely end transmission. | ||||
* | ringbuffer: Add interruptReader() if intended to abort writing and to ↵ | Sven Gothel | 2022-05-29 | 1 | -5/+41 |
| | | | | interrupt the reader thread's potentially blocked read-access call | ||||
* | scripts/rebuild-doc.sh: Remove target before rebuilding doc | Sven Gothel | 2022-05-29 | 1 | -0/+1 |
| | |||||
* | README: Add IOUtils to directory | Sven Gothel | 2022-05-29 | 1 | -0/+1 |
| | |||||
* | README.md: tag v0.11.0v0.11.0 | Sven Gothel | 2022-05-29 | 1 | -1/+1 |
| | |||||
* | Bump README for v0.11.0 | Sven Gothel | 2022-05-29 | 1 | -1/+4 |
| | |||||
* | ByteInStream: Add content_size methods and replace exp_size, mark/implement ↵ | Sven Gothel | 2022-05-29 | 6 | -314/+739 |
| | | | | all methods noexcept, see Botan related notes; Add test_bytestream01 unit tests. | ||||
* | test_fileutils01: Add 2nd project_root location for unit tests hosted as ↵ | Sven Gothel | 2022-05-29 | 1 | -4/+19 |
| | | | | submodule | ||||
* | io::read*(): Document API and have 'em all noexcept while catching potential ↵ | Sven Gothel | 2022-05-29 | 2 | -32/+55 |
| | | | | exception on consumer_fn call | ||||
* | file_stats: Retrieve symlink data and have fmode_bits::LINK additionally ↵ | Sven Gothel | 2022-05-29 | 11 | -48/+197 |
| | | | | set; Add follow_sym_link_dirs to visit() and remove() | ||||
* | Add IOUtils Module/Group; Rename Byte{->In}Stream interface and implementations | Sven Gothel | 2022-05-28 | 5 | -172/+201 |
| | |||||
* | Add unit test for jau::fs::get_cwd() | Sven Gothel | 2022-05-28 | 1 | -0/+16 |
| | |||||
* | test_iostream01: Test w/ actual file_size | Sven Gothel | 2022-05-28 | 1 | -0/+6 |
| | |||||
* | Fix to_integer(): Clear errno before std::strtoll() | Sven Gothel | 2022-05-28 | 1 | -0/+1 |
| | |||||
* | README: Update and fix | Sven Gothel | 2022-05-28 | 1 | -3/+12 |
| | |||||
* | Integrating byte_stream.* and io_util.* incl. unit test from Elevator ↵ | Sven Gothel | 2022-05-28 | 7 | -0/+1791 |
| | | | | | | | | | | project for better encapsulation, test and generic use Fixed: ByteStream_File::check_available(): 'm_bytes_consumed - m_content_size >= n', missed subtracting m_content_size (duh) test_iostream01 uses the fragile std::system() call to start/stop mini_httpd as the http server for testing streaming with curl. | ||||
* | Add jau::fs::get_cwd() | Sven Gothel | 2022-05-28 | 2 | -0/+15 |
| | |||||
* | Add callocator_sec, a secure callocator variant w/ scrubbing before free and ↵ | Sven Gothel | 2022-05-28 | 1 | -0/+174 |
| | | | | | | w/o realloc To scrub memory, we use `::explicit_bzero(p, n)`, i.e. non-optomized away bzero. | ||||
* | callocator: Call anonymous c-func w/ '::', e.g. ::free(..) | Sven Gothel | 2022-05-28 | 1 | -10/+7 |
| | |||||
* | Add RuntimeException types: NotImplementedError and IOError | Sven Gothel | 2022-05-28 | 1 | -0/+13 |
| | |||||
* | function_def: Doc: Remove repetitive 'only' | Sven Gothel | 2022-05-23 | 1 | -1/+1 |
| | |||||
* | FunctionDef: Complete documentation, refine names | Sven Gothel | 2022-05-23 | 2 | -92/+347 |
| | |||||
* | Add Module/Group SysUtilsv0.10.1 | Sven Gothel | 2022-05-22 | 2 | -0/+9 |
| | |||||
* | Add default ctor to file_stats and dir_item; file_stats::to_string() uses ↵ | Sven Gothel | 2022-05-20 | 2 | -1/+13 |
| | | | | decimal string for file size in bytes | ||||
* | Make `DONT_USE_RTTI` optional CMake flag, default enabled. | Sven Gothel | 2022-05-18 | 2 | -9/+17 |
| | |||||
* | fraction_timespec::normalize(): Fix underflow case, allow multiple of ns_per_sec | Sven Gothel | 2022-05-18 | 2 | -4/+37 |
| | |||||
* | fraction*: move test 04.00 -> 03.00 `struct timespec type validation Test 03.00` | Sven Gothel | 2022-05-18 | 2 | -52/+53 |
| | |||||
* | fraction*: Use pass by reference consistently | Sven Gothel | 2022-05-18 | 1 | -4/+4 |
| | |||||
* | Bump README.md | Sven Gothel | 2022-05-18 | 1 | -0/+5 |
| | |||||
* | Add file_util.hpp: File Utilities for platform agnostic C++ handling of file ↵ | Sven Gothel | 2022-05-18 | 5 | -0/+795 |
| | | | | stats and directory traversal, etc | ||||
* | Refining fraction_timespec: Add notion of 'struct timespec' year 2038 issue, ↵ | Sven Gothel | 2022-05-18 | 3 | -9/+112 |
| | | | | to_timespec() conversion, to_iso8601_string() | ||||
* | README: v0.10.0v0.10.0 | Sven Gothel | 2022-05-16 | 1 | -1/+1 |
| | |||||
* | JaulibSetup.cmake: Also use 'no-rtti' for DEBUG build | Sven Gothel | 2022-05-16 | 1 | -0/+3 |
| | |||||
* | Bump README.md | Sven Gothel | 2022-05-15 | 1 | -0/+2 |
| | |||||
* | jau::latch: Extend functionality with count_up(), allowing to dynamically ↵ | Sven Gothel | 2022-05-15 | 2 | -7/+71 |
| | | | | add *events* to required to complete | ||||
* | debug.hpp: Fix API doc: Mention 'function name' in output | Sven Gothel | 2022-05-15 | 1 | -8/+8 |
| | |||||
* | Fix call_on_release: Skip calling `release_func` if resource has been marked ↵ | Sven Gothel | 2022-05-13 | 2 | -3/+15 |
| | | | | | | orderly released, avoid use after free. Detected via valgrind. | ||||
* | Use `std::shared_ptr<T>` instead of a `naked pointer` for sane lifcycle, see ↵ | Sven Gothel | 2022-05-09 | 3 | -180/+387 |
| | | | | | | | | | | shared_ptr_ref<>; Drop all unique_ptr<> funcs; - Store `std::shared_ptr<T>*` in `long nativeInstance` - Introduced `shared_ptr_ref<T>`, managing the `std::shared_ptr<T>*` preserved instances. - All historic TinyB code removed | ||||
* | ~JNIGlobalRef(): Only show brief error message if ↵ | Sven Gothel | 2022-05-09 | 1 | -7/+24 |
| | | | | root_environment::is_terminating() at exit: Reason is that we can't attach to JVM after shutdown initiated. |