Package org.apache.fop.datatypes
Class URISpecification
- java.lang.Object
-
- org.apache.fop.datatypes.URISpecification
-
public final class URISpecification extends java.lang.Object
This class contains method to deal with the <uri-specification> datatype from XSL-FO.
-
-
Field Summary
Fields Modifier and Type Field Description private static char[]
HEX_DIGITS
private static java.lang.String
PUNCT
private static java.lang.String
RESERVED
-
Constructor Summary
Constructors Modifier Constructor Description private
URISpecification()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description private static void
appendEscape(java.lang.StringBuffer sb, byte b)
static java.lang.String
escapeURI(java.lang.String uri)
Escapes any illegal URI character in a given URI, for example, it escapes a space to "%20".static java.lang.String
getURL(java.lang.String href)
Get the URL string from a wrapped URL.private static boolean
isAlpha(char ch)
private static boolean
isDigit(char ch)
private static boolean
isHexDigit(char ch)
private static boolean
isReserved(char ch)
private static boolean
isUnreserved(char ch)
-
-
-
Field Detail
-
PUNCT
private static final java.lang.String PUNCT
- See Also:
- Constant Field Values
-
RESERVED
private static final java.lang.String RESERVED
- See Also:
- Constant Field Values
-
HEX_DIGITS
private static final char[] HEX_DIGITS
-
-
Method Detail
-
getURL
public static java.lang.String getURL(java.lang.String href)
Get the URL string from a wrapped URL.- Parameters:
href
- the input wrapped URL- Returns:
- the raw URL
-
isDigit
private static boolean isDigit(char ch)
-
isAlpha
private static boolean isAlpha(char ch)
-
isHexDigit
private static boolean isHexDigit(char ch)
-
isReserved
private static boolean isReserved(char ch)
-
isUnreserved
private static boolean isUnreserved(char ch)
-
appendEscape
private static void appendEscape(java.lang.StringBuffer sb, byte b)
-
escapeURI
public static java.lang.String escapeURI(java.lang.String uri)
Escapes any illegal URI character in a given URI, for example, it escapes a space to "%20". Note: This method does not "parse" the URI and therefore does not treat the individual components (user-info, path, query etc.) individually.- Parameters:
uri
- the URI to inspect- Returns:
- the escaped URI
-
-