15 Syntax (構文)
15 Syntax (構文)
RTSP の構文は RFC 2068 [2] で用いられる拡張バッカス・ナウア形式 (augmented Backus-Naur form, BNF) で記述される。
15.1 Base Syntax (基本構文)
OCTET = <any 8-bit sequence of data>
CHAR = <any US-ASCII character (octets 0 - 127)>
UPALPHA = <any US-ASCII uppercase letter "A".."Z">
LOALPHA = <any US-ASCII lowercase letter "a".."z">
ALPHA = UPALPHA | LOALPHA
DIGIT = <any US-ASCII digit "0".."9">
CTL = <any US-ASCII control character (octets 0 - 31) and DEL (127)>
CR = <US-ASCII CR, carriage return (13)>
LF = <US-ASCII LF, linefeed (10)>
SP = <US-ASCII SP, space (32)>
HT = <US-ASCII HT, horizontal-tab (9)>
DQUOTE = <US-ASCII double-quote mark (34)>
CRLF = CR LF
LWS = [CRLF] 1*( SP | HT )
TEXT = <any OCTET except CTLs>
tspecials = "(" | ")" | "<" | ">" | "@" |
"," | ";" | ":" | "\" | DQUOTE |
"/" | "[" | "]" | "?" | "=" |
"{" | "}" | SP | HT
token = 1*<any CHAR except CTLs or tspecials>
quoted-string = ( DQUOTE *(qdtext) DQUOTE )
qdtext = <any TEXT except DQUOTE>
quoted-pair = "\" CHAR
message-header = field-name ":" [ field-value ] CRLF
field-name = token
field-value = *( field-content | LWS )
field-content = <the OCTETs making up the field-value and consisting of either *TEXT or combinations of token, tspecials, and quoted-string>
safe = "\$" | "-" | "_" | "." | "+"
extra = "!" | "*" | "'" | "(" | ")" | ","
hex = DIGIT | "A" | "B" | "C" | "D" | "E" | "F" | "a" | "b" | "c" | "d" | "e" | "f"
escape = "\%" hex hex
reserved = ";" | "/" | "?" | ":" | "@" | "&" | "="
unreserved = alpha | digit | safe | extra
xchar = unreserved | reserved | escape