Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: allow owned entities to be structs #14236

Closed
Neme12 opened this issue Dec 22, 2018 · 3 comments
Closed

Feature request: allow owned entities to be structs #14236

Neme12 opened this issue Dec 22, 2018 · 3 comments

Comments

@Neme12
Copy link

Neme12 commented Dec 22, 2018

For owned entities that are inlined into their owner entity's table, the semantics of a struct make a lot of sense and are much more in line with how the entity ends up being stored. These entities do not have an identity. Their properties are inlined into their owners just like struct's fields are inlined into their containing type. Just like structs, they cannot be null because a collection of columns cannot be null independent of the columns themselves being null. They are value objects.

In addition to this, having a property whose type is a custom struct could automatically make it an owned entity without needing any configuration.

@ajcvickers
Copy link
Member

ajcvickers commented Dec 22, 2018

Duplicate of #13947. (Value conversions already work for structs and the semantics align much better to value objects than owned entities do.)

@Neme12
Copy link
Author

Neme12 commented Dec 22, 2018

That's not a duplicate 😕 I don't want to implement a conversion for every owned entity type. I simply want my owned entity types to be structs. I don't see why that's disallowed.

@ajcvickers ajcvickers reopened this Oct 16, 2022
@ajcvickers ajcvickers closed this as not planned Won't fix, can't repro, duplicate, stale Oct 16, 2022
@voroninp
Copy link

Looks like Owned Entities became a dead-end.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants