This commit is contained in:
skidoodle 2024-03-13 00:33:46 +01:00
commit e124a47765
19374 changed files with 9806149 additions and 0 deletions

View file

@ -0,0 +1,39 @@
using System.Collections.Generic;
using Kreta.Framework.Collections.Generic;
namespace Kreta.Framework.Entities.Generic
{
public interface IEntityDBHelper<EntityType>
where EntityType : Kreta.Framework.Entities.Entity
{
string EmptyQueryCommandText { get; }
SDA.DataProvider.SDACommand CreateEmptyQueryCommand();
SDA.DataProvider.SDACommand CreateDynamicQueryCommand(ColumnFilterMode columnFilterMode, IEnumerable<string> columns);
void LoadEntityFields(EntityType entity, SDA.DataProvider.SDADataReader reader, ColumnFilterMode columnFilterMode, IEnumerable<string> columns);
void LoadFromReader(EntityType entity, SDA.DataProvider.SDADataReader reader, ColumnFilterMode columnFilterMode, IEnumerable<string> columns);
bool LoadEntityCollection(IEntityCollection<EntityType> collection, SDA.DataProvider.SDACommand command);
bool LoadEntityCollection(IEntityCollection<EntityType> collection, SDA.DataProvider.SDACommand command, ColumnFilterMode columnFilterMode, IEnumerable<string> columns);
bool LoadSingleEntity(EntityType entity, SDA.DataProvider.SDACommand command);
bool LoadSingleEntity(EntityType entity, SDA.DataProvider.SDACommand command, ColumnFilterMode columnFilterMode, IEnumerable<string> columns);
bool LoadByPartnerId(EntityType entity, string filterText, int partnerId);
bool LoadByPartnerId(IEntityCollection<EntityType> collection, string filterText, int partnerId);
void BindAttributes(EntityType entity, SDA.DataProvider.SDACommand command);
void DynamicBindAttributes(EntityType entity, SDA.DataProvider.SDACommand command);
void BindAssociations(EntityType entity, SDA.DataProvider.SDACommand command);
void CreateParameterBinding(SDA.DataProvider.SDACommand command, Dictionary<string, object> commandParameters);
}
}