Example #1
0
        private Dictionary <Node, CRDT.Application.Commutative.Register.LWW_RegisterWithVCService <TestType> > CreateCommutativeReplicas(List <Node> nodes)
        {
            var dictionary = new Dictionary <Node, CRDT.Application.Commutative.Register.LWW_RegisterWithVCService <TestType> >();

            foreach (var node in nodes)
            {
                var repository = new LWW_RegisterWithVCRepository();
                var service    = new CRDT.Application.Commutative.Register.LWW_RegisterWithVCService <TestType>(repository);

                dictionary.Add(node, service);
            }

            return(dictionary);
        }
Example #2
0
        private Dictionary <Node, LWW_RegisterWithVCService <TestType> > CreateConvergentReplicas(List <Node> nodes)
        {
            var dictionary = new Dictionary <Node, LWW_RegisterWithVCService <TestType> >();

            foreach (var node in nodes)
            {
                var repository = new LWW_RegisterWithVCRepository();
                var service    = new LWW_RegisterWithVCService <TestType>(repository);

                dictionary.Add(node, service);
            }

            return(dictionary);
        }