Main demo method.
Map constraints = MutableObject.getConstraintMap(Customer.class);
Iterator iter = constraints.values()
.iterator();
ObjectConstraint constraint = null;
while (iter.hasNext()) {
constraint = (ObjectConstraint)iter.next();
System.out.println("Property=" + constraint.getName() + " Type="
+ constraint.getClass().getName());
}
constraint = MutableObject.getConstraint(SavingsAccount.class, "interestRate");
System.out.println("\nSavingsAccount interestRate property");
System.out.println("dataType = "
+ ((NumericConstraint)constraint).getDataType().getName());
System.out.println("minValue = " + ((NumericConstraint)constraint).getMinValue());
System.out.println("maxValue = " + ((NumericConstraint)constraint).getMaxValue());