Пример #1
0
        /// <summary>
        /// Validates the specified modelNode.
        /// </summary>
        /// <param name="modelNode">The model.</param>
        /// <returns></returns>
        public static IList <IValidationResult> Validate(this IModelNode modelNode)
        {
            var visitor = new ValidationVisitor();

            modelNode.Accept(visitor);
            return(visitor.Result);
        }
Пример #2
0
 public virtual IModelNode Visit(IModelNode modelNode)
 {
     if (modelNode != null)
     {
         return(modelNode.Accept(this));
     }
     return(null);
 }
Пример #3
0
 public IModelNode Visit(IModelNode modelNode)
 {
     return(modelNode?.Accept(this));
 }