4#include "Stroika/Foundation/StroikaPreComp.h"
6#include "Stroika/Foundation/Streams/TextToBinary.h"
15using namespace Stroika::Foundation::Streams;
20using namespace DataExchange::Variant;
32 virtual _SharedPtrIRep Clone ()
const override
34 return make_shared<Rep_> ();
36 virtual optional<filesystem::path> GetDefaultFileSuffix ()
const override
42 Write (v, TextToBinary::Writer::New (out, UnicodeExternalEncodings::eUTF8, ByteOrderMark::eDontInclude));
46 Write (Convert (v), out);
50#if USE_NOISY_TRACE_IN_THIS_MODULE_
53 Write (nullopt, profile.fUnnamedSection, out);
54 for (
const auto& sectionKVP : profile.fNamedSections) {
55 Write (sectionKVP.fKey, sectionKVP.fValue, out);
62 sb <<
"["sv << *sectionName <<
"]"sv << Characters::kEOL<wchar_t>;
65 sb << kvp.fKey <<
"="sv << kvp.fValue << Characters::kEOL<wchar_t>;
72 : inherited{make_shared<Rep_> ()}
78 return Write (profile, Streams::TextToBinary::Writer::New (out));
83 Debug::UncheckedDynamicCast<Rep_&> (_GetRep ()).Write (profile, out);
86Memory::BLOB INI::Writer::WriteAsBLOB (
const Profile& profile)
91String INI::Writer::WriteAsString (
const Profile& profile)
conditional_t< qStroika_Foundation_Memory_PreferBlockAllocation and andTrueCheck, BlockAllocationUseHelper< T >, Common::Empty > UseBlockAllocationIfAppropriate
Use this to enable block allocation for a particular class. Beware of subclassing.
Similar to String, but intended to more efficiently construct a String. Mutable type (String is large...
nonvirtual String str() const
String is like std::u32string, except it is much easier to use, often much more space efficient,...
Simple variant-value (case variant union) object, with (variant) basic types analogous to a value in ...
OutputStream<>::Ptr is Smart pointer to a stream-based sink of data.
nonvirtual void WriteLn(ELT_2_WRITE &&arg) const
Iterable<T> is a base class for containers which easily produce an Iterator<T> to traverse them.
An Iterator<T> is a copyable object which allows traversing the contents of some container....