Esempio n. 1
0
        /// <summary>
        /// Write a description of the constraint to a MessageWriter
        /// </summary>
        /// <param name="writer"></param>
        public override void WriteDescriptionTo(MessageWriter writer)
        {
            if (Command != null)
            {
                var description       = new DescriptionStructureHelper();
                var notExpression     = description.GetNotExpression(true);
                var targetExpression  = description.GetTargetExpression(Command.Description.Target);
                var captionExpression = Expected;
                var filterExpression  = description.GetFilterExpression(Command.Description.Filters.Where(f => f.Target != Command.Description.Target)).Remove(0, 3);

                writer.WritePredicate(string.Format("find {0} {1} named '{2}' linked to {3}"
                                                    , notExpression
                                                    , targetExpression
                                                    , captionExpression
                                                    , filterExpression));
            }
        }
Esempio n. 2
0
        /// <summary>
        /// Write a description of the constraint to a MessageWriter
        /// </summary>
        /// <param name="writer"></param>
        public override void WriteDescriptionTo(MessageWriter writer)
        {
            if (Request != null)
            {
                var description       = new DescriptionStructureHelper();
                var filterExpression  = description.GetFilterExpression(Request.GetAllFilters().Where(f => f.Target != Request.Target));
                var notExpression     = description.GetNotExpression(true);
                var targetExpression  = description.GetTargetExpression(Request.Target);
                var captionExpression = Expected;

                writer.WritePredicate(string.Format("find {0} {1} named '{2}' {3}"
                                                    , notExpression
                                                    , targetExpression
                                                    , captionExpression
                                                    , filterExpression));
            }
        }
Esempio n. 3
0
        /// <summary>
        /// Write a description of the constraint to a MessageWriter
        /// </summary>
        /// <param name="writer"></param>
        public override void WriteDescriptionTo(MessageWriter writer)
        {
            if (Command != null)
            {
                var description = new DescriptionStructureHelper();
                var filterExpression = description.GetFilterExpression(Command.Description.Filters.Where(f => f.Target != Command.Description.Target));
                var notExpression = description.GetNotExpression(true);
                var targetExpression = description.GetTargetExpression(Command.Description.Target);
                var captionExpression = Expected;

                writer.WritePredicate(string.Format("find {0} {1} named '{2}' {3}"
                            , notExpression
                            , targetExpression
                            , captionExpression
                            , filterExpression));
            }
        }