Ejemplo n.º 1
0
        private void RemoveValidationErrors(IValidationErrorFilter filter)
        {
            ArrayList   newList = new ArrayList();
            ICollection col     = nodeInfo.GetDetails(filter.Node);

            foreach (ValidationError ve in col)
            {
                if (!filter.IsMatch(ve))
                {
                    newList.Add(ve);
                }
                else
                {
                    Console.WriteLine("Removing validation error {0}", ve.Message);
                }
            }
            nodeInfo.SetDetails(filter.Node, (ValidationError[])newList.ToArray(typeof(ValidationError)));
        }
Ejemplo n.º 2
0
 private void RemoveValidationErrors(IValidationErrorFilter filter)
 {
     ArrayList newList=new ArrayList();
     ICollection col=nodeInfo.GetDetails(filter.Node);
     foreach ( ValidationError ve in col )
     {
         if ( !filter.IsMatch(ve) )
             newList.Add(ve);
         else
             Console.WriteLine("Removing validation error {0}", ve.Message);
     }
     nodeInfo.SetDetails(filter.Node, (ValidationError[]) newList.ToArray(typeof(ValidationError)));
 }