4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
# File 'lib/abnf/parser/common.rb', line 4
def self.to_s
<<-ABNF
ALPHA = %x41-5A / %x61-7A ; A-Z / a-z\r
\r
BIT = "0" / "1"\r
\r
CHAR = %x01-7F\r
; any 7-bit US-ASCII character,\r
; excluding NUL\r
\r
CR = %x0D\r
; carriage return\r
\r
CRLF = CR LF\r
; Internet standard newline\r
\r
CTL = %x00-1F / %x7F\r
; controls\r
\r
DIGIT = %x30-39\r
; 0-9\r
\r
DQUOTE = %x22\r
; " (Double Quote)\r
\r
HEXDIG = DIGIT / "A" / "B" / "C" / "D" / "E" / "F"\r
\r
HTAB = %x09\r
; horizontal tab\r
\r
LF = %x0A\r
; linefeed\r
\r
LWSP = *(WSP / CRLF WSP)\r
; Use of this linear-white-space rule\r
; permits lines containing only white\r
; space that are no longer legal in\r
; mail headers and have caused\r
; interoperability problems in other\r
; contexts.\r
; Do not use when defining mail\r
; headers and use with caution in\r
; other contexts.\r
\r
OCTET = %x00-FF\r
; 8 bits of data\r
\r
SP = %x20\r
\r
VCHAR = %x21-7E\r
; visible (printing) characters\r
\r
WSP = SP / HTAB\r
; white space\r
\r
ABNF
end
|