|
@@ -15,7 +15,7 @@ namespace InABox.Core
|
|
|
}
|
|
|
|
|
|
public abstract class EntityFormUtils<TForm, TEntity, TEntityLink> : IEntityFormUtils
|
|
|
- where TForm : EntityForm<TEntity, TEntityLink>
|
|
|
+ where TForm : EntityForm<TEntity, TEntityLink, TForm>
|
|
|
where TEntity : Entity, new()
|
|
|
where TEntityLink : EntityLink<TEntity>, new()
|
|
|
{
|
|
@@ -31,7 +31,7 @@ namespace InABox.Core
|
|
|
}
|
|
|
|
|
|
public class DelegateEntityFormUtils<TForm, TEntity, TEntityLink> : EntityFormUtils<TForm, TEntity, TEntityLink>
|
|
|
- where TForm : EntityForm<TEntity, TEntityLink>
|
|
|
+ where TForm : EntityForm<TEntity, TEntityLink, TForm>
|
|
|
where TEntity : Entity, new()
|
|
|
where TEntityLink : EntityLink<TEntity>, new()
|
|
|
{
|
|
@@ -118,7 +118,7 @@ namespace InABox.Core
|
|
|
DelegateEntityFormUtils<TForm, TEntity, TEntityLink>.CanEditEvent editFormFunc,
|
|
|
DelegateEntityFormUtils<TForm, TEntity, TEntityLink>.NewEntityEvent? newEntityFunc = null,
|
|
|
DelegateEntityFormUtils<TForm, TEntity, TEntityLink>.OnSaveEvent? beforeSaveFunc = null)
|
|
|
- where TForm : EntityForm<TEntity, TEntityLink>
|
|
|
+ where TForm : EntityForm<TEntity, TEntityLink, TForm>
|
|
|
where TEntity : Entity, new()
|
|
|
where TEntityLink : EntityLink<TEntity>, new()
|
|
|
{
|
|
@@ -126,7 +126,7 @@ namespace InABox.Core
|
|
|
}
|
|
|
|
|
|
public static void AddFormUtils<TForm, TEntity, TEntityLink>(EntityFormUtils<TForm, TEntity, TEntityLink> formUtils)
|
|
|
- where TForm : EntityForm<TEntity, TEntityLink>
|
|
|
+ where TForm : EntityForm<TEntity, TEntityLink, TForm>
|
|
|
where TEntity : Entity, new()
|
|
|
where TEntityLink : EntityLink<TEntity>, new()
|
|
|
{
|
|
@@ -143,7 +143,7 @@ namespace InABox.Core
|
|
|
}
|
|
|
|
|
|
public static bool CanEditForm<TForm, TEntity, TEntityLink>(TForm Form, TEntity Entity)
|
|
|
- where TForm : EntityForm<TEntity, TEntityLink>
|
|
|
+ where TForm : EntityForm<TEntity, TEntityLink, TForm>
|
|
|
where TEntity : Entity, new()
|
|
|
where TEntityLink : EntityLink<TEntity>, new()
|
|
|
{
|
|
@@ -160,7 +160,7 @@ namespace InABox.Core
|
|
|
}
|
|
|
|
|
|
public static TEntity NewEntity<TForm, TEntity, TEntityLink>(DigitalForm form)
|
|
|
- where TForm : EntityForm<TEntity, TEntityLink>
|
|
|
+ where TForm : EntityForm<TEntity, TEntityLink, TForm>
|
|
|
where TEntity : Entity, new()
|
|
|
where TEntityLink : EntityLink<TEntity>, new()
|
|
|
{
|
|
@@ -176,7 +176,7 @@ namespace InABox.Core
|
|
|
}
|
|
|
|
|
|
public static void OnSave<TForm, TEntity, TEntityLink>(TForm form, TEntity entity)
|
|
|
- where TForm : EntityForm<TEntity, TEntityLink>
|
|
|
+ where TForm : EntityForm<TEntity, TEntityLink, TForm>
|
|
|
where TEntity : Entity, new()
|
|
|
where TEntityLink : EntityLink<TEntity>, new()
|
|
|
{
|