mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-31 01:24:19 +02:00
parent
171c137451
commit
caf2812f0d
@ -65,6 +65,7 @@ REGISTER_SAFE_SCRIPTFUNCTION(escape_shell_arg, &Utility::EscapeShellArg);
|
|||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
REGISTER_SAFE_SCRIPTFUNCTION(escape_create_process_arg, &Utility::EscapeCreateProcessArg);
|
REGISTER_SAFE_SCRIPTFUNCTION(escape_create_process_arg, &Utility::EscapeCreateProcessArg);
|
||||||
#endif /* _WIN32 */
|
#endif /* _WIN32 */
|
||||||
|
REGISTER_SCRIPTFUNCTION(__ptr, &ScriptUtils::Ptr);
|
||||||
|
|
||||||
String ScriptUtils::CastString(const Value& value)
|
String ScriptUtils::CastString(const Value& value)
|
||||||
{
|
{
|
||||||
@ -317,3 +318,7 @@ Array::Ptr ScriptUtils::TrackParents(const Object::Ptr& child)
|
|||||||
return Array::FromVector(DependencyGraph::GetParents(child));
|
return Array::FromVector(DependencyGraph::GetParents(child));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
double ScriptUtils::Ptr(const Object::Ptr& object)
|
||||||
|
{
|
||||||
|
return reinterpret_cast<intptr_t>(object.get());
|
||||||
|
}
|
||||||
|
@ -52,6 +52,7 @@ public:
|
|||||||
static void Assert(const Value& arg);
|
static void Assert(const Value& arg);
|
||||||
static String MsiGetComponentPathShim(const String& component);
|
static String MsiGetComponentPathShim(const String& component);
|
||||||
static Array::Ptr TrackParents(const Object::Ptr& parent);
|
static Array::Ptr TrackParents(const Object::Ptr& parent);
|
||||||
|
static double Ptr(const Object::Ptr& object);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
ScriptUtils(void);
|
ScriptUtils(void);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user