summaryrefslogtreecommitdiff
path: root/src/include/operators.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/operators.h')
-rw-r--r--src/include/operators.h38
1 files changed, 4 insertions, 34 deletions
diff --git a/src/include/operators.h b/src/include/operators.h
index a4e0f74..66c7e2b 100644
--- a/src/include/operators.h
+++ b/src/include/operators.h
@@ -1,11 +1,13 @@
-/** --------------------------------------------------------------------
+/**
* @file operators.h
* @brief Declaration of all operators.
* @author Andreas Aardal Hanssen, Erwin Hoffmann
* @date 2002-2005, 2023
- * ----------------------------------------------------------------- **/
+ */
+
#ifndef operators_h_included
#define operators_h_included
+
#include "depot.h"
#include "imapparser.h"
#include "message.h"
@@ -15,7 +17,6 @@
namespace Binc {
- //--------------------------------------------------------------------
class Operator {
public:
enum ProcessResult { OK, BAD, NO, NOTHING, ABORT };
@@ -27,11 +28,9 @@ namespace Binc {
virtual int getState(void) const = 0;
virtual const std::string getName(void) const = 0;
- //--
virtual ~Operator(void){};
};
- //--------------------------------------------------------------------
class AppendOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -43,7 +42,6 @@ namespace Binc {
~AppendOperator(void);
};
- //--------------------------------------------------------------------
class AuthenticateOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -60,7 +58,6 @@ namespace Binc {
~AuthenticateOperator(void);
};
- //--------------------------------------------------------------------
class CapabilityOperator : public Operator {
std::vector<std::string> capabilities;
@@ -77,7 +74,6 @@ namespace Binc {
~CapabilityOperator(void);
};
- //--------------------------------------------------------------------
class CheckOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -90,7 +86,6 @@ namespace Binc {
~CheckOperator(void);
};
- //--------------------------------------------------------------------
class CreateOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -103,7 +98,6 @@ namespace Binc {
~CreateOperator(void);
};
- //--------------------------------------------------------------------
class CloseOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -116,7 +110,6 @@ namespace Binc {
~CloseOperator(void);
};
- //--------------------------------------------------------------------
class CopyOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -129,7 +122,6 @@ namespace Binc {
~CopyOperator(void);
};
- //--------------------------------------------------------------------
class DeleteOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -142,7 +134,6 @@ namespace Binc {
~DeleteOperator(void);
};
- //--------------------------------------------------------------------
class ExpungeOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -155,7 +146,6 @@ namespace Binc {
~ExpungeOperator(void);
};
- //--------------------------------------------------------------------
class FetchOperator : public Operator {
protected:
ParseResult expectSectionText(BincImapParserFetchAtt &f_in) const;
@@ -175,7 +165,6 @@ namespace Binc {
~FetchOperator(void);
};
- //--------------------------------------------------------------------
class IdOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -188,7 +177,6 @@ namespace Binc {
~IdOperator(void);
};
- //--------------------------------------------------------------------
class IdleOperator : public Operator {
protected:
ParseResult expectSectionText(BincImapParserFetchAtt &f_in) const;
@@ -208,7 +196,6 @@ namespace Binc {
~IdleOperator(void);
};
- //--------------------------------------------------------------------
class ListOperator : public Operator {
protected:
enum MailboxFlags { DIR_SELECT = 0x01, DIR_MARKED = 0x02, DIR_NOINFERIORS = 0x04, DIR_LEAF = 0x08 };
@@ -227,7 +214,6 @@ namespace Binc {
~ListOperator(void);
};
- //--------------------------------------------------------------------
class LoginOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -240,7 +226,6 @@ namespace Binc {
~LoginOperator(void);
};
- //--------------------------------------------------------------------
class LogoutOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -253,7 +238,6 @@ namespace Binc {
~LogoutOperator(void);
};
- //--------------------------------------------------------------------
class LsubOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -266,7 +250,6 @@ namespace Binc {
~LsubOperator(void);
};
- //--------------------------------------------------------------------
class NamespaceOperator : public Operator {
public:
virtual ProcessResult process(Depot &, Request &);
@@ -279,7 +262,6 @@ namespace Binc {
~NamespaceOperator(void);
};
- //--------------------------------------------------------------------
class NoopOperator : public Operator {
public:
virtual ProcessResult process(Depot &, Request &);
@@ -292,7 +274,6 @@ namespace Binc {
~NoopOperator(void);
};
- //--------------------------------------------------------------------
class NoopPendingOperator : public NoopOperator {
public:
ProcessResult process(Depot &, Request &);
@@ -301,7 +282,6 @@ namespace Binc {
~NoopPendingOperator(void);
};
- //--------------------------------------------------------------------
class RenameOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -314,12 +294,10 @@ namespace Binc {
~RenameOperator(void);
};
- //--------------------------------------------------------------------
class SearchOperator : public Operator {
protected:
ParseResult expectSearchKey(BincImapParserSearchKey &s_in) const;
- //------------------------------------------------------------------
class SearchNode {
std::string date;
std::string astring;
@@ -390,7 +368,6 @@ namespace Binc {
void init(const BincImapParserSearchKey &a);
- //-
static bool compareNodes(const SearchNode &a, const SearchNode &b)
{
return a.getWeight() < b.getWeight();
@@ -411,7 +388,6 @@ namespace Binc {
~SearchOperator(void);
};
- //--------------------------------------------------------------------
class SelectOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -424,7 +400,6 @@ namespace Binc {
~SelectOperator(void);
};
- //--------------------------------------------------------------------
class ExamineOperator : public SelectOperator {
public:
const std::string getName(void) const;
@@ -432,7 +407,6 @@ namespace Binc {
~ExamineOperator(void);
};
- //--------------------------------------------------------------------
class StarttlsOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -446,7 +420,6 @@ namespace Binc {
~StarttlsOperator(void);
};
- //--------------------------------------------------------------------
class StatusOperator : public Operator {
std::map<int, Status> statuses;
@@ -461,7 +434,6 @@ namespace Binc {
~StatusOperator(void);
};
- //--------------------------------------------------------------------
class StoreOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -474,7 +446,6 @@ namespace Binc {
~StoreOperator(void);
};
- //--------------------------------------------------------------------
class SubscribeOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);
@@ -487,7 +458,6 @@ namespace Binc {
~SubscribeOperator(void);
};
- //--------------------------------------------------------------------
class UnsubscribeOperator : public Operator {
public:
ProcessResult process(Depot &, Request &);