mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: direct access to wrapped ifstream/ofstream with compression (#1805)
- previously hidden as Detail::[IO]FstreamAllocator, now exposed
directly as [io]fstreamPointer, which allows reuse for
std::ifstream, std::ofstream wrapping, without the additional
ISstream, OSstream layers.
These stream pointers have some characteristics similar to a
unique_ptr.
- restrict direct gzstream usage to two files (fstreamPointers.C,
gzstream.C) which improves localization and makes it simpler to
enable/disable with the `HAVE_LIBZ` define.
The HAVE_LIBZ define is currently simply hard-coded in the
Make/options.
If compiled WITHOUT libz support:
- reading gz files : FatalError
- writing gz files : emit warning and downgrade to uncompressed
- warn if compression is specified in the case controlDict
and downgrade to uncompressed
ENH: minor updates to gzstream interface for C++11
- support construct/open with std::string for the file names.
CONFIG: provisioning for have_libz detection as wmake/script
This commit is contained in:
3
applications/test/fstreamPointer/Make/files
Normal file
3
applications/test/fstreamPointer/Make/files
Normal file
@ -0,0 +1,3 @@
|
||||
Test-fstreamPointer.C
|
||||
|
||||
EXE = $(FOAM_USER_APPBIN)/Test-fstreamPointer
|
||||
2
applications/test/fstreamPointer/Make/options
Normal file
2
applications/test/fstreamPointer/Make/options
Normal file
@ -0,0 +1,2 @@
|
||||
/* EXE_INC = */
|
||||
/* EXE_LIBS = */
|
||||
Reference in New Issue
Block a user