diff options
Diffstat (limited to 'src/mongo/db/auth/privilege.h')
-rw-r--r-- | src/mongo/db/auth/privilege.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mongo/db/auth/privilege.h b/src/mongo/db/auth/privilege.h index eef476ea224..0b113c7ff56 100644 --- a/src/mongo/db/auth/privilege.h +++ b/src/mongo/db/auth/privilege.h @@ -16,6 +16,7 @@ #pragma once #include <string> +#include <vector> #include "mongo/db/auth/action_set.h" #include "mongo/db/auth/action_type.h" @@ -37,6 +38,9 @@ namespace mongo { const ActionSet& getActions() const { return _actions; } + void addActions(const ActionSet& actionsToAdd); + void removeActions(const ActionSet& actionsToRemove); + // Checks if the given action is present in the Privilege. bool includesAction(const ActionType& action) const; // Checks if the given actions are present in the Privilege. @@ -48,4 +52,6 @@ namespace mongo { ActionSet _actions; // bitmask of actions this privilege grants }; + typedef std::vector<Privilege> PrivilegeVector; + } // namespace mongo |