mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-27 15:44:11 +02:00
parent
6721f681e2
commit
7c65757219
@ -131,6 +131,9 @@ using std::type_info;
|
|||||||
#include <boost/lexical_cast.hpp>
|
#include <boost/lexical_cast.hpp>
|
||||||
#include <boost/foreach.hpp>
|
#include <boost/foreach.hpp>
|
||||||
#include <boost/tuple/tuple.hpp>
|
#include <boost/tuple/tuple.hpp>
|
||||||
|
#include <boost/uuid/uuid.hpp>
|
||||||
|
#include <boost/uuid/uuid_generators.hpp>
|
||||||
|
#include <boost/uuid/uuid_io.hpp>
|
||||||
|
|
||||||
using boost::shared_ptr;
|
using boost::shared_ptr;
|
||||||
using boost::weak_ptr;
|
using boost::weak_ptr;
|
||||||
|
@ -373,3 +373,19 @@ Utility::LoadIcingaLibrary(const String& library, bool module)
|
|||||||
|
|
||||||
return hModule;
|
return hModule;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Generates a new UUID.
|
||||||
|
*
|
||||||
|
* @returns The new UUID in text form.
|
||||||
|
*/
|
||||||
|
String Utility::NewUUID(void)
|
||||||
|
{
|
||||||
|
boost::uuids::uuid uuid = boost::uuids::random_generator()();
|
||||||
|
|
||||||
|
stringstream us;
|
||||||
|
us << uuid;
|
||||||
|
|
||||||
|
return us.str();
|
||||||
|
}
|
||||||
|
|
||||||
|
@ -53,6 +53,8 @@ public:
|
|||||||
|
|
||||||
static void Sleep(double timeout);
|
static void Sleep(double timeout);
|
||||||
|
|
||||||
|
static String NewUUID(void);
|
||||||
|
|
||||||
static
|
static
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
HMODULE
|
HMODULE
|
||||||
|
Loading…
x
Reference in New Issue
Block a user