it.eng.spagobi.validation
Class SpagoURLValidator

java.lang.Object
  extended by org.apache.commons.validator.UrlValidator
      extended by it.eng.spagobi.validation.SpagoURLValidator
All Implemented Interfaces:
java.io.Serializable

public class SpagoURLValidator
extends org.apache.commons.validator.UrlValidator

Author:
AZ This class contains code from Jakarta Commons Validator It'is implemented as a subclass of URLValidator to solve the bugs described in http://issues.apache.org/bugzilla/attachment.cgi?id=14369 so in Spago Validator we can use SpagoURLValidator to validate URL
See Also:
Serialized Form

Field Summary
static int ALLOW_2_SLASHES
          Allow two slashes in the path component of the URL.
static int ALLOW_ALL_SCHEMES
          Allows all validly formatted schemes to pass validation instead of supplying a set of valid schemes.
static int NO_FRAGMENTS
          Enabling this options disallows any URL fragments.
 
Constructor Summary
SpagoURLValidator()
           
 
Method Summary
 boolean isValid(java.lang.String value)
          Controls if a String at imput is a valid URL.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ALLOW_ALL_SCHEMES

public static final int ALLOW_ALL_SCHEMES
Allows all validly formatted schemes to pass validation instead of supplying a set of valid schemes.

See Also:
Constant Field Values

ALLOW_2_SLASHES

public static final int ALLOW_2_SLASHES
Allow two slashes in the path component of the URL.

See Also:
Constant Field Values

NO_FRAGMENTS

public static final int NO_FRAGMENTS
Enabling this options disallows any URL fragments.

See Also:
Constant Field Values
Constructor Detail

SpagoURLValidator

public SpagoURLValidator()
Method Detail

isValid

public boolean isValid(java.lang.String value)
Controls if a String at imput is a valid URL.

Overrides:
isValid in class org.apache.commons.validator.UrlValidator
Parameters:
value - The input string
Returns:
True if the string is a valid URL, else false.