4#ifndef _Stroika_Foundation_DataExchange_Variant_Reader_h_
5#define _Stroika_Foundation_DataExchange_Variant_Reader_h_ 1
7#include "Stroika/Foundation/StroikaPreComp.h"
33namespace Stroika::Foundation::Memory {
37namespace Stroika::Foundation::DataExchange::Variant {
53 explicit Reader (
const shared_ptr<_IRep>& rep);
58 nonvirtual optional<filesystem::path> GetDefaultFileSuffix ()
const;
70 nonvirtual _IRep& _GetRep ();
71 nonvirtual
const _IRep& _GetRep ()
const;
91 using _SharedPtrIRep = shared_ptr<_IRep>;
95 _SharedPtrIRep operator() (
const _IRep& t)
const;
103 class Reader::_IRep {
105 virtual ~_IRep () =
default;
106 virtual _SharedPtrIRep Clone ()
const = 0;
107 virtual optional<filesystem::path> GetDefaultFileSuffix ()
const = 0;
abstract class specifying interface for readers that map a source like XML or JSON to a VariantValue ...
static Streams::InputStream::Ptr< byte > _ToByteReader(const Streams::InputStream::Ptr< byte > &in)
simple helper so subclasses can more easily provide varied Read overloads
static Streams::InputStream::Ptr< Characters::Character > _ToCharacterReader(const Streams::InputStream::Ptr< Characters::Character > &in)
simple helper so subclasses can more easily provide varied Read overloads
Simple variant-value (case variant union) object, with (variant) basic types analogous to a value in ...
Iterable<T> is a base class for containers which easily produce an Iterator<T> to traverse them.