Skip to content

How to declare relation between properties (enum and nullable field) #10471

Answered by ondrejmirtes
mhsdesign asked this question in Support
Discussion options

You must be logged in to vote

No you can't express this with the current type system.

If I were you I'd choose a different object design. Usage of nullable or optional parameters is usually a code smell. You should have separate EmptyHolder and StringHolder classes.

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@mhsdesign
Comment options

@ondrejmirtes
Comment options

Answer selected by mhsdesign
@mhsdesign
Comment options

@ondrejmirtes
Comment options

@mhsdesign
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Support
Labels
None yet
2 participants