Bincimap 2.0.16
Easy Imapping
Loading...
Searching...
No Matches
operator-noop.cc
Go to the documentation of this file.
1
7#include <string>
8#include <iostream>
9
10#include "recursivedescent.h"
11#include "session.h"
12#include "depot.h"
13#include "operators.h"
14
15using namespace ::std;
16using namespace Binc;
17
18//----------------------------------------------------------------------
20{
21}
22
23//----------------------------------------------------------------------
25{
26}
27
28//----------------------------------------------------------------------
29const string NoopOperator::getName(void) const
30{
31 return "NOOP";
32}
33
34//----------------------------------------------------------------------
36{
40}
41
42//----------------------------------------------------------------------
44 Request &command)
45{
46 return OK;
47}
48
49//----------------------------------------------------------------------
51{
52 Session &session = Session::getInstance();
53
54 if (c_in.getUidMode()) return REJECT;
55
57 if ((res = expectCRLF()) != ACCEPT) {
58 session.setLastError("Expected CRLF after NOOP");
59 return res;
60 }
61
62 c_in.setName("NOOP");
63
64 return ACCEPT;
65}
virtual ParseResult parse(Request &) const
int getState(void) const
virtual ProcessResult process(Depot &, Request &)
const std::string getName(void) const
void setName(const std::string &s_in)
Definition: imapparser.cc:70
bool getUidMode(void) const
Definition: imapparser.cc:40
void setLastError(const std::string &error) const
Definition: session.cc:185
@ NONAUTHENTICATED
Definition: session.h:36
@ AUTHENTICATED
Definition: session.h:37
static Session & getInstance(void)
Definition: session.cc:33
Definition: bincimapd.cc:9
Operator::ParseResult expectCRLF(void)
Declaration of all operators.
Declaration of a recursive descent IMAP command parser.