public override bool ConflictsWith(UserConfiguredItemBase otherItem) { if ((otherItem == this) || ((this == CacheNone) && (otherItem == CacheAll)) || ((this == CacheAll) && (otherItem == CacheNone))) { return(true); } if (base.ConflictsWith(otherItem)) { var otherSettings = (MappedObjectCachingSetting)otherItem; if ((this == CacheNone) || (otherSettings == CacheNone) || (this == CacheAll) || (otherSettings == CacheAll)) { return(otherSettings.Cache == Cache); } // Settings have overlapping, non-global source and target types return(true); } return(false); }
public string GetConflictMessage(UserConfiguredItemBase conflictingConfiguredItem) { if (conflictingConfiguredItem is ConfiguredDataSourceFactory conflictingDataSource) { return(GetConflictMessage(conflictingDataSource)); } return($"Member {TargetMember.GetPath()} has been ignored"); }
public override bool ConflictsWith(UserConfiguredItemBase otherConfiguredItem) { if (!base.ConflictsWith(otherConfiguredItem)) { return(false); } return(!WasAutoCreated || _factoryInfo.IsSameAs(((ConfiguredObjectFactory)otherConfiguredItem)._factoryInfo)); }
public virtual bool ConflictsWith(UserConfiguredItemBase otherConfiguredItem) { if (HasConfiguredCondition || otherConfiguredItem.HasConfiguredCondition) { return(false); } if (ConfigInfo.HasCompatibleTypes(otherConfiguredItem.ConfigInfo)) { return(TargetMember.Matches(otherConfiguredItem.TargetMember)); } return(false); }
protected override bool MembersConflict(UserConfiguredItemBase otherConfiguredItem) { if (HasNoMemberFilter) { return(base.MembersConflict(otherConfiguredItem)); } if ((otherConfiguredItem is ConfiguredIgnoredMember otherIgnoredMember) && otherIgnoredMember.HasMemberFilter) { return(otherIgnoredMember.TargetMemberFilter == TargetMemberFilter); } return(_memberFilter.Invoke(new TargetMemberSelector(otherConfiguredItem.TargetMember))); }
public override bool ConflictsWith(UserConfiguredItemBase otherItem) { if (!base.ConflictsWith(otherItem)) { return(false); } var otherSettings = (EntityKeyMappingSetting)otherItem; if ((this == MapAllKeys) || (otherSettings == MapAllKeys)) { return(otherSettings.MapKeys == MapKeys); } // Settings have overlapping, non-global source and target types return(true); }
public override bool ConflictsWith(UserConfiguredItemBase otherItem) { if (base.ConflictsWith(otherItem)) { var otherSettings = (DataSourceReversalSetting)otherItem; if ((this == ReverseAll) || (otherSettings == ReverseAll)) { return(otherSettings.Reverse == Reverse); } // Settings have overlapping, non-global source and target types return(true); } return(false); }
public override bool ConflictsWith(UserConfiguredItemBase otherConfiguredItem) { var otherCondition = (MapToNullCondition)otherConfiguredItem; return(otherCondition._targetType == _targetType); }
protected override bool HasOverlappingTypes(UserConfiguredItemBase otherConfiguredItem) { return(base.HasOverlappingTypes(otherConfiguredItem) && (((ConfiguredObjectFactory)otherConfiguredItem).ObjectType == ObjectType)); }
protected bool SourceAndTargetTypesAreTheSame(UserConfiguredItemBase otherConfiguredItem) { return(ConfigInfo.HasSameSourceTypeAs(otherConfiguredItem.ConfigInfo) && ConfigInfo.HasSameTargetTypeAs(otherConfiguredItem.ConfigInfo)); }
protected override bool HasReverseConflict(UserConfiguredItemBase otherItem) => false;
public bool HasSameSourceTypeAs(UserConfiguredItemBase userConfiguredItem) => HasSameSourceTypeAs(userConfiguredItem.ConfigInfo);
public bool HasSameTypesAs(UserConfiguredItemBase userConfiguredItem) => HasSameSourceTypeAs(userConfiguredItem) && HasSameTargetTypeAs(userConfiguredItem);
public bool HasSameTargetTypeAs(UserConfiguredItemBase userConfiguredItem) => TargetType == userConfiguredItem.TargetType;