Beispiel #1
0
        public Tangle(
            TaskScheduler scheduler,
            StreamSource storage,
            Serializer <T> serializer     = null,
            Deserializer <T> deserializer = null,
            bool ownsStorage = true
            )
        {
            Scheduler   = scheduler;
            Storage     = storage;
            OwnsStorage = ownsStorage;

            Serializer   = serializer ?? Defaults <T> .Serializer;
            Deserializer = deserializer ?? Defaults <T> .Deserializer;

            BTree = new BTree(Storage, "");
        }
Beispiel #2
0
 public SubStreamSource(StreamSource inner, string prefix, bool ownsInnerSource = true)
 {
     Inner           = inner;
     Prefix          = prefix;
     OwnsInnerSource = ownsInnerSource;
 }