You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Always have to check if the value of a LazyId is null or not makes the code "heavy". Also there are cases where a LazyId cannot have a null value (for example when a foreign key has a NON NULL)
Describe the solution you'd like
Splitting the LazyId class into different classes:
a generic one (the current LazyId)
a null one
a non-null one
Note that LazyId would then become a sealed class and the variants would be subclasses.
Describe alternatives you've considered
Probably also splitting the non-null variant into:
a non-null lazy one
a non-null defined one
could be useful
Additional context
No.
The text was updated successfully, but these errors were encountered:
This is not fully doable. What can be done is to make LazyId always return non-null values. In this scenario, LazyId itself would be null.
This way the "null-check" will be necessary only if the value of the Table could be null, thus reducing the needing for "null-checking" even if the value could never be null.
Is your feature request related to a problem? Please describe.
Always have to check if the value of a LazyId is null or not makes the code "heavy". Also there are cases where a LazyId cannot have a null value (for example when a foreign key has a
NON NULL
)Describe the solution you'd like
Splitting the
LazyId
class into different classes:Note that LazyId would then become a sealed class and the variants would be subclasses.
Describe alternatives you've considered
Probably also splitting the non-null variant into:
could be useful
Additional context
No.
The text was updated successfully, but these errors were encountered: