parsed_request.h 540 B

1234567891011121314151617181920212223242526
  1. #pragma once
  2. #include <util/generic/strbuf.h>
  3. struct TParsedHttpRequest {
  4. TParsedHttpRequest(const TStringBuf& str);
  5. TStringBuf Method;
  6. TStringBuf Request;
  7. TStringBuf Proto;
  8. };
  9. struct TParsedHttpLocation {
  10. TParsedHttpLocation(const TStringBuf& req);
  11. TStringBuf Path;
  12. TStringBuf Cgi;
  13. };
  14. struct TParsedHttpFull: public TParsedHttpRequest, public TParsedHttpLocation {
  15. inline TParsedHttpFull(const TStringBuf& line)
  16. : TParsedHttpRequest(line)
  17. , TParsedHttpLocation(Request)
  18. {
  19. }
  20. };