Package com.sun.identity.sm
Class IPAddressValidator
- java.lang.Object
-
- com.sun.identity.sm.IPAddressValidator
-
- All Implemented Interfaces:
ServiceAttributeValidator
public class IPAddressValidator extends Object implements ServiceAttributeValidator
The classIPAddressValidator
is used to check if the IP address is syntactically correct.
-
-
Constructor Summary
Constructors Constructor Description IPAddressValidator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
validate(String value)
Validates an IP address.boolean
validate(Set<String> values)
Validates a set of string IP address.
-
-
-
Method Detail
-
validate
public boolean validate(Set<String> values)
Validates a set of string IP address.- Specified by:
validate
in interfaceServiceAttributeValidator
- Parameters:
values
- the set of IP address to validate- Returns:
- true if all of the IP addresses are valid; false otherwise
-
validate
public boolean validate(String value)
Validates an IP address.- Parameters:
value
- the IP address to validate- Returns:
- true if the IP address is valid; false otherwise
-
-