Ejemplo n.º 1
0
        public static IEnumerable <object[]> GetTypeRecognitionTestCases()
        {
            var baseStrategy    = new PropertyTypeSelectionStrategy();
            var wrappedStrategy = new WrappedPropertyTypeSelectionStrategy();

            foreach (var testCase in GetCommonTypeRecognitionTestCases(baseStrategy))
            {
                yield return(testCase);
            }
            foreach (var testCase in GetCommonTypeRecognitionTestCases(wrappedStrategy))
            {
                yield return(testCase);
            }
        }
Ejemplo n.º 2
0
        public IEnumerable <Property> GetFilteredProperties()
        {
            if (PropertyTypeSelectionStrategy == null)
            {
                return(base.Properties);
            }

            try
            {
                var properties         = base.Properties.ToArray();
                var filteredProperties = PropertyTypeSelectionStrategy.FilterProperties(properties).ToArray();
                return(filteredProperties);
            }
            catch (Exception ex)
            {
                throw;
            }
        }
Ejemplo n.º 3
0
 public virtual IEnumerable <Property> GetPropertiesWhichRequireInitialization()
 {
     return(PropertyTypeSelectionStrategy.GetPropertiesWhichRequireInitialization(this));
 }