42 {
43
44 return [
45 [
46 'http://example.org/hello?foo=bar#test',
47 [
48 'scheme' => 'http',
49 'host' => 'example.org',
50 'path' => '/hello',
51 'port' => null,
52 'user' => null,
53 'query' => 'foo=bar',
54 'fragment' => 'test'
55 ]
56 ],
57
58
59 [
60 'http://example.org/有词法别名.zh',
61 [
62 'scheme' => 'http',
63 'host' => 'example.org',
64 'path' => '/%E6%9C%89%E8%AF%8D%E6%B3%95%E5%88%AB%E5%90%8D.zh',
65 'port' => null,
66 'user' => null,
67 'query' => null,
68 'fragment' => null
69 ]
70 ],
71 [
72 'ftp://user:password@ftp.example.org/',
73 [
74 'scheme' => 'ftp',
75 'host' => 'ftp.example.org',
76 'path' => '/',
77 'port' => null,
78 'user' => 'user',
79 'pass' => 'password',
80 'query' => null,
81 'fragment' => null,
82 ]
83 ],
84
85
86 [
87 'http://example.org/hello:12?foo=bar#test',
88 [
89 'scheme' => 'http',
90 'host' => 'example.org',
91 'path' => '/hello:12',
92 'port' => null,
93 'user' => null,
94 'query' => 'foo=bar',
95 'fragment' => 'test'
96 ]
97 ],
98 [
99 '/path/to/colon:34',
100 [
101 'scheme' => null,
102 'host' => null,
103 'path' => '/path/to/colon:34',
104 'port' => null,
105 'user' => null,
106 'query' => null,
107 'fragment' => null,
108 ]
109 ],
110
111 [
112 'file:///foo/bar',
113 [
114 'scheme' => 'file',
115 'host' => '',
116 'path' => '/foo/bar',
117 'port' => null,
118 'user' => null,
119 'query' => null,
120 'fragment' => null,
121 ]
122 ],
123
124 [
125 'vfs:///somefile',
126 [
127 'scheme' => 'vfs',
128 'host' => '',
129 'path' => '/somefile',
130 'port' => null,
131 'user' => null,
132 'query' => null,
133 'fragment' => null,
134 ]
135 ],
136
137 [
138 'ldap://[2001:db8::7]/c=GB?objectClass?one',
139 [
140 'scheme' => 'ldap',
141 'host' => '[2001:db8::7]',
142 'path' => '/c=GB',
143 'port' => null,
144 'user' => null,
145 'query' => 'objectClass?one',
146 'fragment' => null,
147 ]
148 ],
149 [
150 'news:comp.infosystems.www.servers.unix',
151 [
152 'scheme' => 'news',
153 'host' => null,
154 'path' => 'comp.infosystems.www.servers.unix',
155 'port' => null,
156 'user' => null,
157 'query' => null,
158 'fragment' => null,
159 ]
160 ],
161
162 [
163 'http://example.org:8080/',
164 [
165 'scheme' => 'http',
166 'host' => 'example.org',
167 'path' => '/',
168 'port' => 8080,
169 'user' => null,
170 'query' => null,
171 'fragment' => null,
172 ]
173 ],
174
175 [
176 '#foo',
177 [
178 'scheme' => null,
179 'host' => null,
180 'path' => null,
181 'port' => null,
182 'user' => null,
183 'query' => null,
184 'fragment' => 'foo',
185 ]
186
187 ]
188
189 ];
190
191 }