Skip to content

AbstractNumericRightValue can be parametrized with different inner type#28

Merged
verhas merged 1 commit intoverhas:masterfrom
PetrPytelka:extensible_numeric_types
Feb 9, 2020
Merged

AbstractNumericRightValue can be parametrized with different inner type#28
verhas merged 1 commit intoverhas:masterfrom
PetrPytelka:extensible_numeric_types

Conversation

@PetrPytelka
Copy link
Copy Markdown
Contributor

@PetrPytelka PetrPytelka commented Feb 5, 2020

This change allows to implement RightValues compatible with Numeric but with other real class then Numeric. Example of such RightValues are LocalDate or EmptyValue. Real implementations based on this patch are in my branches empty_value and support_for_date2.

AbstractNumericRightValue can be parametrized with different inner type then Numeric based. New abstract method getNumericValue allows to get Numeric value.

Example of usage:
public class BasicDateValue extends AbstractNumericRightValue<Long, LocalDate> {
...
}
public class BasicEmptyValue extends AbstractNumericRightValue<Long, EmptyValue> {
}

@verhas verhas merged commit 85d32e9 into verhas:master Feb 9, 2020
@PetrPytelka PetrPytelka deleted the extensible_numeric_types branch June 9, 2020 21:43
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

Successfully merging this pull request may close these issues.

2 participants