Package org.apache.fop.datatypes
Class URISpecification
- java.lang.Object
-
- org.apache.fop.datatypes.URISpecification
-
public final class URISpecification extends java.lang.ObjectThis 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_DIGITSprivate static java.lang.StringPUNCTprivate static java.lang.StringRESERVED
-
Constructor Summary
Constructors Modifier Constructor Description privateURISpecification()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description private static voidappendEscape(java.lang.StringBuffer sb, byte b)static java.lang.StringescapeURI(java.lang.String uri)Escapes any illegal URI character in a given URI, for example, it escapes a space to "%20".static java.lang.StringgetURL(java.lang.String href)Get the URL string from a wrapped URL.private static booleanisAlpha(char ch)private static booleanisDigit(char ch)private static booleanisHexDigit(char ch)private static booleanisReserved(char ch)private static booleanisUnreserved(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
-
-