示例#1
0
        private bool IsTypeMatch(PropertyTemplate template, string propertyType)
        {
            PropertyTemplateMatchCondition condition = template.MatchCondition;

            return(condition.PropertyTypeRule switch
            {
                PropertyTypeRule.Any => true,
                PropertyTypeRule.Specified => condition.Type == propertyType,
                _ => throw new NotImplementedException(condition.PropertyTypeRule.ToString())
            });