org.w3c.www.webdav
Class DAVParser
java.lang.Object
|
+--org.w3c.www.webdav.DAVParser
- public class DAVParser
- extends java.lang.Object
Method Summary |
static java.lang.String |
decodeETag(java.lang.String encoded)
[ETag] -> ETag |
static java.lang.String |
decodeURL(java.lang.String encoded)
-> URI |
protected static void |
error(java.lang.String mth,
java.lang.String msg)
Emit an error. |
static int |
nextItem(byte[] buf,
org.w3c.www.webdav.ParseState ps)
Parse list of items, taking care of quotes and optional LWS. |
static int |
skipSpaces(byte[] buf,
org.w3c.www.webdav.ParseState ps)
Skip leading LWS, not including CR LF. |
static boolean |
startsWith(byte[] buf,
org.w3c.www.webdav.ParseState ps,
char c)
|
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
DAVParser
public DAVParser()
error
protected static void error(java.lang.String mth,
java.lang.String msg)
throws HttpInvalidValueException
- Emit an error.
- Parameters:
mth
- The method trigerring the error.msg
- An associated message.- Throws:
- HttpInvalidValueException - To indicate the error to caller.
skipSpaces
public static final int skipSpaces(byte[] buf,
org.w3c.www.webdav.ParseState ps)
- Skip leading LWS, not including CR LF.
Update the input offset, after any leading space.
- Parameters:
buf
- The buffer to be parsed.ptr
- The buffer pointer to be updated on return.- Returns:
- The potentially advanced buffer input offset.
startsWith
public static final boolean startsWith(byte[] buf,
org.w3c.www.webdav.ParseState ps,
char c)
nextItem
public static final int nextItem(byte[] buf,
org.w3c.www.webdav.ParseState ps)
- Parse list of items, taking care of quotes and optional LWS.
The output offset points to the next element of the list.
- Returns:
- The starting location (i.e.
ps.start
value), or
-1 if no item available (end of list).
decodeURL
public static final java.lang.String decodeURL(java.lang.String encoded)
throws HttpInvalidValueException
- -> URI
decodeETag
public static final java.lang.String decodeETag(java.lang.String encoded)
throws HttpInvalidValueException
- [ETag] -> ETag