On Thu, 05 Mar 2009 10:30:49 +0100, Elias Ross <gen...@noderunner.net> wrote:

@Max("12.5")
BigDecimal someNumber;

Since the BigDecimal and BigInteger have String constructors that are
well defined, a String representation seems fine.

The string representation is probably less intuative though, especially for int/Integer/long/Long. And of
course it is prone typos.

There's other restrictions you may want to make as well. For instance,
you may want to restrict values to at most N decimal places or
significant digits, i.e. precision. This is useful in scientific
applications. How might you represent that?

Is this not covererd by @Digits?

--Hardy


_______________________________________________
hibernate-dev mailing list
hibernate-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/hibernate-dev

Reply via email to