Пример #1
0
        public static List <BaseOperator> CreateListOperator(List <Relationship> relationshipKeyJoins)
        {
            var operators = new List <BaseOperator>();
            var factory   = new OperatorFactory();

            relationshipKeyJoins.ForEach(join =>
            {
                if (join.OperatorName != null)
                {
                    operators.Add(factory.CreateOperator(join.OperatorName));
                }
                if (join.UnaryOperator != null)
                {
                    operators.Add(factory.CreateOperator(join.UnaryOperator));
                }
                if (join.Value.HasValue)
                {
                    operators.Add(factory.CreateValueOperator(join.Value.Value));
                }
            });
            return(operators);
        }