50 lines
718 B
C
50 lines
718 B
C
|
/*
|
||
|
* This file is a part of CMSLU -- Content Management System like Unix
|
||
|
* and is not publicly distributed
|
||
|
*
|
||
|
* Copyright (c) 2008-2009, Tomasz Sowa
|
||
|
* All rights reserved.
|
||
|
*
|
||
|
*/
|
||
|
|
||
|
#ifndef headerfilecmslucoreacceptencodingparser
|
||
|
#define headerfilecmslucoreacceptencodingparser
|
||
|
|
||
|
#include "acceptbaseparser.h"
|
||
|
#include "log.h"
|
||
|
|
||
|
|
||
|
class AcceptEncodingParser : public AcceptBaseParser
|
||
|
{
|
||
|
public:
|
||
|
|
||
|
bool AcceptDeflate()
|
||
|
{
|
||
|
return accept_deflate;
|
||
|
}
|
||
|
|
||
|
|
||
|
private:
|
||
|
|
||
|
void Init()
|
||
|
{
|
||
|
accept_deflate = false;
|
||
|
}
|
||
|
|
||
|
|
||
|
void Param(const std::string & param, double q)
|
||
|
{
|
||
|
if( param=="deflate" && q!=0 )
|
||
|
{
|
||
|
accept_deflate = true;
|
||
|
log << log3 << "AEP: accept deflate" << logend;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
bool accept_deflate;
|
||
|
};
|
||
|
|
||
|
|
||
|
|
||
|
#endif
|