private void ImplementIsPkAuto(IClassBuilder entityClass, PropertyInfo pkProperty) { var value = PkHandlingHelper.IsPkAutogenerated(pkProperty); entityClass.HasPublicProperty <bool>(nameof(IEntity.IsPrimaryKeyAutogenerated)).Returns(p => p.Write(value)); }