示例#1
0
 public TRuleTypeShouldConjunction BeAssignableTo(IEnumerable <string> patterns,
                                                  bool useRegularExpressions = false)
 {
     _ruleCreator.AddCondition(
         TypeConditionsDefinition <TRuleType> .BeAssignableTo(patterns, useRegularExpressions));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#2
0
 public TRuleTypeShouldConjunction ImplementInterface(Type intf)
 {
     _ruleCreator.AddCondition(
         TypeConditionsDefinition <TRuleType> .ImplementInterface(intf));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#3
0
 public TRuleTypeShouldConjunction ImplementInterface(string pattern, bool useRegularExpressions = false)
 {
     _ruleCreator.AddCondition(
         TypeConditionsDefinition <TRuleType> .ImplementInterface(pattern, useRegularExpressions));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#4
0
 public TRuleTypeShouldConjunction BeAssignableTo(IEnumerable <Type> types)
 {
     _ruleCreator.AddCondition(TypeConditionsDefinition <TRuleType> .BeAssignableTo(types));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#5
0
 public TRuleTypeShouldConjunction BeAssignableTo(Type firstType, params Type[] moreTypes)
 {
     _ruleCreator.AddCondition(TypeConditionsDefinition <TRuleType> .BeAssignableTo(firstType, moreTypes));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#6
0
 public TRuleTypeShouldConjunction NotBeNested()
 {
     _ruleCreator.AddCondition(TypeConditionsDefinition <TRuleType> .NotBeNested());
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#7
0
        //Relation Condition Negations

        public ShouldRelateToTypesThat <TRuleTypeShouldConjunction, IType, TRuleType> NotBeAssignableToTypesThat()
        {
            _ruleCreator.BeginComplexCondition(ArchRuleDefinition.Types(),
                                               TypeConditionsDefinition <TRuleType> .NotBeAssignableToTypesThat());
            return(new ShouldRelateToTypesThat <TRuleTypeShouldConjunction, IType, TRuleType>(_ruleCreator));
        }
示例#8
0
 public TRuleTypeShouldConjunction NotHaveMemberWithName(string name)
 {
     _ruleCreator.AddCondition(TypeConditionsDefinition <TRuleType> .NotHaveMemberWithName(name));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#9
0
 public TRuleTypeShouldConjunction NotResideInAssembly(Assembly assembly, params Assembly[] moreAssemblies)
 {
     _ruleCreator.AddCondition(
         TypeConditionsDefinition <TRuleType> .NotResideInAssembly(assembly, moreAssemblies));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#10
0
 public TRuleTypeShouldConjunction NotResideInAssembly(string pattern, bool useRegularExpressions = false)
 {
     _ruleCreator.AddCondition(
         TypeConditionsDefinition <TRuleType> .NotResideInAssembly(pattern, useRegularExpressions));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#11
0
 public TRuleTypeShouldConjunction NotBeAssignableTo(IObjectProvider <IType> types)
 {
     _ruleCreator.AddCondition(TypeConditionsDefinition <TRuleType> .NotBeAssignableTo(types));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }
示例#12
0
 public TRuleTypeShouldConjunction AdhereToPlantUmlDiagram(Stream stream)
 {
     _ruleCreator.AddCondition(TypeConditionsDefinition <TRuleType> .AdhereToPlantUmlDiagram(stream));
     return(Create <TRuleTypeShouldConjunction, TRuleType>(_ruleCreator));
 }