help with custom validator
hey guys. can smb help me out with writing my won validation annotation? i have entity
Payment and DTO PaymentDTO and they have private BigDecimal amount field. i want to validate it bc i want this field's length to be 7 positions at maximum. so far i have this:- what to write instead of
???in myAmountValidator? should it be data type of my field? i.e.BigDecimal? - how to check if my field's max length is less than 7 positions in
isValidmethod in theAmountValidator?
thanks in advance.