how to parse HTTP header lines ?
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Dror_Tirosh
Posted On:   Sunday, January 6, 2002 06:52 PM

I want a parser that can parse "specific" and "nonspecific" header lines: known headers are handled explicitly, and unknown are parsed as generic strings.

e.g:

			
headerLine : expiresHeader | locationHeader | anyHeader CRLF ;
anyHeader : IDENT ":" text ;
expiresHeader : "Expires" ":" INT ;
locationHeader : "Location" ":" url ;
About | Sitemap | Contact