Package org.eclipse.jetty.http
Enum UriCompliance.Violation
- java.lang.Object
-
- java.lang.Enum<UriCompliance.Violation>
-
- org.eclipse.jetty.http.UriCompliance.Violation
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<UriCompliance.Violation>
,ComplianceViolation
- Enclosing class:
- UriCompliance
public static enum UriCompliance.Violation extends java.lang.Enum<UriCompliance.Violation> implements ComplianceViolation
These are URI compliance "violations", which may be allowed by the compliance mode. These are actual violations of the RFC, as they represent additional requirements in excess of the strict compliance of RFC 3986. A compliance mode that contains one or more of these Violations, allows request to violate the corresponding additional requirement.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.eclipse.jetty.http.ComplianceViolation
ComplianceViolation.Listener, ComplianceViolation.Mode
-
-
Enum Constant Summary
Enum Constants Enum Constant Description AMBIGUOUS_EMPTY_SEGMENT
Allow ambiguous empty segments e.g.AMBIGUOUS_PATH_ENCODING
Allow ambiguous path encoding within a URI segment e.g.AMBIGUOUS_PATH_PARAMETER
Allow ambiguous path parameters within a URI segment e.g.AMBIGUOUS_PATH_SEGMENT
Allow ambiguous path segments e.g.AMBIGUOUS_PATH_SEPARATOR
Allow ambiguous path separator within a URI segment e.g.UTF16_ENCODINGS
Allow UTF-16 encoding eg/foo%u2192bar
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getDescription()
java.lang.String
getName()
java.lang.String
getURL()
static UriCompliance.Violation
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static UriCompliance.Violation[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.-
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Methods inherited from interface org.eclipse.jetty.http.ComplianceViolation
isAllowedBy
-
-
-
-
Enum Constant Detail
-
AMBIGUOUS_PATH_SEGMENT
public static final UriCompliance.Violation AMBIGUOUS_PATH_SEGMENT
Allow ambiguous path segments e.g./foo/%2e%2e/bar
-
AMBIGUOUS_EMPTY_SEGMENT
public static final UriCompliance.Violation AMBIGUOUS_EMPTY_SEGMENT
Allow ambiguous empty segments e.g.//
-
AMBIGUOUS_PATH_SEPARATOR
public static final UriCompliance.Violation AMBIGUOUS_PATH_SEPARATOR
Allow ambiguous path separator within a URI segment e.g./foo/b%2fr
-
AMBIGUOUS_PATH_PARAMETER
public static final UriCompliance.Violation AMBIGUOUS_PATH_PARAMETER
Allow ambiguous path parameters within a URI segment e.g./foo/..;/bar
or/foo/%2e%2e;param/bar
-
AMBIGUOUS_PATH_ENCODING
public static final UriCompliance.Violation AMBIGUOUS_PATH_ENCODING
Allow ambiguous path encoding within a URI segment e.g./%2557EB-INF
-
UTF16_ENCODINGS
public static final UriCompliance.Violation UTF16_ENCODINGS
Allow UTF-16 encoding eg/foo%u2192bar
.
-
-
Method Detail
-
values
public static UriCompliance.Violation[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (UriCompliance.Violation c : UriCompliance.Violation.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static UriCompliance.Violation valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
getName
public java.lang.String getName()
- Specified by:
getName
in interfaceComplianceViolation
- Returns:
- The name of the violation.
-
getURL
public java.lang.String getURL()
- Specified by:
getURL
in interfaceComplianceViolation
- Returns:
- A URL to the specification that provides more information regarding the requirement that may be violated.
-
getDescription
public java.lang.String getDescription()
- Specified by:
getDescription
in interfaceComplianceViolation
- Returns:
- A short description of the violation.
-
-