|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object project35.soa.validation.AbstractEditFieldValidationService project35.soa.validation.NumericValidator project35.soa.validation.IntegerValidator project35.soa.validation.BoundedIntegerValidator
public class BoundedIntegerValidator
Determines whether an integer field value is within minimum and maximum bounds boundaries are inclusive. The validator accepts four types of domain expression. Examples include:
Copyright (c) Kevin Garwood and University of Manchester 2007. All rights reserved. Licensed under the Academic Free License version 3.0. For more information on the terms and conditions, please see the file "LICENSE" that is included in this distribution.
Field Summary |
---|
Fields inherited from class project35.soa.validation.AbstractEditFieldValidationService |
---|
collator |
Constructor Summary | |
---|---|
BoundedIntegerValidator()
constructor |
Method Summary | |
---|---|
java.lang.String |
getConstraintsDescription()
|
void |
setBounds(int lowerBound,
boolean lowerBoundIsInclusive,
int upperBound,
boolean upperBoundIsInclusive)
sets lower and upper bounds |
void |
setLowerBound(int lowerBound,
boolean lowerBoundIsInclusive)
sets lower bounds |
void |
setUpperBound(int upperBound,
boolean upperBoundIsInclusive)
sets upper bounds |
java.util.ArrayList |
validate(Project35FormContext project35FormContext,
java.lang.String value)
validates a field value |
Methods inherited from class project35.soa.validation.AbstractEditFieldValidationService |
---|
getFieldName, getInitialisationParameters, initialiseService, isEmpty, isFieldRequired, setFieldName, setRequiredField, validateRequiredField |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BoundedIntegerValidator()
Method Detail |
---|
public java.lang.String getConstraintsDescription()
getConstraintsDescription
in interface ConstraintDescription
public void setBounds(int lowerBound, boolean lowerBoundIsInclusive, int upperBound, boolean upperBoundIsInclusive)
lowerBound
- the lower bound valuelowerBoundIsInclusive
- whether lower bound is inclusive or exlusiveupperBound
- the upper bound valueupperBoundIsInclusive
- whether upper bound is inclusive or exlusivepublic void setLowerBound(int lowerBound, boolean lowerBoundIsInclusive)
lowerBound
- the lower bound valuelowerBoundIsInclusive
- whether lower bound is inclusive or exlusivepublic void setUpperBound(int upperBound, boolean upperBoundIsInclusive)
upperBound
- the upper bound valueupperBoundIsInclusive
- whether upper bound is inclusive or exlusivepublic java.util.ArrayList validate(Project35FormContext project35FormContext, java.lang.String value)
validate
in interface EditFieldValidationService
validate
in class IntegerValidator
project35FormContext
- contains references to various application
featuresvalue
- the field value
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |