Example #1
0
        public UnaryCollectionShard(string name, CollectionShard <T1> source1, Channel <T1> channel1)
            : base(name)
        {
            input1 = channel1;

            if (source1 != null)
            {
                source1.Subscribe(channel1, this);
            }
        }
Example #2
0
        public BinaryCollectionShard(string name, CollectionShard <T1> source1, Channel <T1> channel1, CollectionShard <T2> source2, Channel <T2> channel2)
            : base(name)
        {
            input1 = channel1;
            input2 = channel2;

            if (source1 != null)
            {
                source1.Subscribe(channel1, this);
            }
            if (source2 != null)
            {
                source2.Subscribe(channel2, this);
            }
        }