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

Throw runtime exception is value is used from an uninitialized value-object #37

Closed
SteveDunn opened this issue Jan 1, 2022 · 0 comments

Comments

@SteveDunn
Copy link
Owner

It's impossible to guarantee that all value-objects will be initialized, for instance, new CustomerId[10].

We can pick up a lot of situations where an attempt is made to default a value-object, but for those where we can't, we need a flag in the type that is checked at runtime and throws an exception if the value-object's value is used.

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

No branches or pull requests

1 participant