public bool IsAuditedProperty(EntityEntry entry, string propertyName)
#endif
        {
            if (ExcludeIncludePropertyPredicates.Count == 0)
            {
                return(true);
            }

            var  type = entry.Entity.GetType();
            var  key  = string.Concat(type.FullName, ";", propertyName);
            bool value;

            if (!IsAuditedDictionary.TryGetValue(key, out value))
            {
                value = true;

                foreach (var excludeIncludePropertyFuncs in ExcludeIncludePropertyPredicates)
                {
                    var maybeIncluded = excludeIncludePropertyFuncs(entry.Entity, propertyName);
                    if (maybeIncluded.HasValue)
                    {
                        value = maybeIncluded.Value;
                    }
                }

                IsAuditedDictionary.TryAdd(key, value);
            }

            return(value);
        }
        public bool IsAuditedEntity(EntityEntry entry)
#endif
        {
            if (ExcludeIncludeEntityPredicates.Count == 0 || entry.Entity == null)
            {
                return(true);
            }

            var  type = entry.Entity.GetType();
            var  key  = type.FullName;
            bool value;

            if (!IsAuditedDictionary.TryGetValue(key, out value))
            {
                value = true;

                foreach (var excludeIncludeEntityFunc in ExcludeIncludeEntityPredicates)
                {
                    var maybeIncluded = excludeIncludeEntityFunc(entry.Entity);
                    if (maybeIncluded.HasValue)
                    {
                        value = maybeIncluded.Value;
                    }
                }

                IsAuditedDictionary.TryAdd(key, value);
            }

            return(value);
        }