PsychicHTTP

This commit is contained in:
iranl
2024-08-26 23:41:54 +02:00
parent ca9c2feebc
commit 89393cee58
16 changed files with 1522 additions and 1447 deletions

View File

@@ -318,6 +318,11 @@ PsychicWebParameter * PsychicRequest::addParam(PsychicWebParameter *param) {
return param;
}
int PsychicRequest::params()
{
return _params.size();
}
bool PsychicRequest::hasParam(const char *key)
{
return getParam(key) != NULL;
@@ -332,6 +337,18 @@ PsychicWebParameter * PsychicRequest::getParam(const char *key)
return NULL;
}
PsychicWebParameter * PsychicRequest::getParam(int index)
{
if (_params.size() > index){
std::list<PsychicWebParameter*>::iterator it = _params.begin();
for(int i=0; i<index; i++){
++it;
}
return *it;
}
return NULL;
}
bool PsychicRequest::hasSessionKey(const String& key)
{
return this->_session->find(key) != this->_session->end();