コード例 #1
0
        public void PropertyValueValidatorTest()
        {
            PropertyGroupConfigurationElementCollection groups = PropertyGroupSettings.GetConfig().Groups;

            foreach (PropertyGroupConfigurationElement group in groups)
            {
                PropertyDefineCollection propertiesDefinitions = new PropertyDefineCollection();

                propertiesDefinitions.LoadPropertiesFromConfiguration(group);

                PropertyValueCollection properties = new PropertyValueCollection();

                properties.AppendFromPropertyDefineCollection(propertiesDefinitions);

                ValidationResults results = properties.Validate();

                Console.WriteLine(results.ToString("\r\n"));
            }
        }
コード例 #2
0
		public void PropertyValueValidatorTest()
		{
			PropertyGroupConfigurationElementCollection groups = PropertyGroupSettings.GetConfig().Groups;

			foreach (PropertyGroupConfigurationElement group in groups)
			{
				PropertyDefineCollection propertiesDefinitions = new PropertyDefineCollection();

				propertiesDefinitions.LoadPropertiesFromConfiguration(group);

				PropertyValueCollection properties = new PropertyValueCollection();

				properties.AppendFromPropertyDefineCollection(propertiesDefinitions);

				ValidationResults results = properties.Validate();

				Console.WriteLine(results.ToString("\r\n"));
			}
		}