8000 Remove new() restriction in EfRepository<> · Issue #124 · SharpRepository/SharpRepository · GitHub
[go: up one dir, main page]

Skip to content

Remove new() restriction in EfRepository<> #124

@ioann

Description

@ioann
< 6159 /div>

I couldn't understand what is the reason of this restriction. I tried remove it manually and I faced with situation that this restriction didn't need (not required). Finally all works fine without them.

But I see a big disadvantage in this restriction (new()). I can't create entity with protected default constructor for encapsulate logic for object creation into another constructor. It is so useful if you use style like DDD.

I suggest remove this restriction at all. I can provide pull request with fix.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0