OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
MongoSessionFunctions.h
Go to the documentation of this file.
1#pragma once
2
3
4#include <iostream>
5#include <cstdint>
6#include <vector>
7#include <bsoncxx/json.hpp>
8#include <bsoncxx/types.hpp>
9#include <mongocxx/client.hpp>
10#include <mongocxx/stdx.hpp>
11#include <mongocxx/uri.hpp>
12#include <mongocxx/instance.hpp>
13#include <bsoncxx/builder/stream/helpers.hpp>
14#include <bsoncxx/builder/stream/document.hpp>
15#include <bsoncxx/builder/stream/array.hpp>
16
17#include "User.h"
18#include "Group.h"
19
20using bsoncxx::builder::stream::close_array;
21using bsoncxx::builder::stream::close_document;
22using bsoncxx::builder::stream::document;
23using bsoncxx::builder::stream::finalize;
24using bsoncxx::builder::stream::open_array;
25using bsoncxx::builder::stream::open_document;
26using bsoncxx::document::value;
27using bsoncxx::document::view;
28using bsoncxx::document::element;
29
31{
32 std::string createSession(std::string username, mongocxx::client& adminClient);
33 std::string refreshSession(std::string sessionName, mongocxx::client& adminClient);
34 void removeOldSessions(mongocxx::client& adminClient);
35
36 std::string generateUniqueSessionName(std::string username, mongocxx::client& adminClient);
37}
Definition MongoSessionFunctions.h:31
std::string refreshSession(std::string sessionName, mongocxx::client &adminClient)
Definition MongoSessionFunctions.cpp:69
std::string generateUniqueSessionName(std::string username, mongocxx::client &adminClient)
Definition MongoSessionFunctions.cpp:31
std::string createSession(std::string username, mongocxx::client &adminClient)
Definition MongoSessionFunctions.cpp:13
void removeOldSessions(mongocxx::client &adminClient)
Definition MongoSessionFunctions.cpp:90