Copy as Markdown

Other Tools

/*
* DO NOT EDIT. THIS FILE IS GENERATED FROM $SRCDIR/toolkit/components/glean/xpcom/nsIFOG.idl
*/
#ifndef __gen_nsIFOG_h__
#define __gen_nsIFOG_h__
#include "nsISupports.h"
#include "nsTArray.h"
#include "js/Value.h"
#include "js/GCAnnotations.h"
/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
/* starting interface: nsIFOG */
#define NS_IFOG_IID_STR "98d0e975-9cad-4ce3-ae2f-f878b8be6307"
#define NS_IFOG_IID \
{0x98d0e975, 0x9cad, 0x4ce3, \
{ 0xae, 0x2f, 0xf8, 0x78, 0xb8, 0xbe, 0x63, 0x07 }}
class NS_NO_VTABLE nsIFOG : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IFOG_IID)
/* Used by ToJSValue to check which scriptable interface is implemented. */
using ScriptableInterfaceType = nsIFOG;
/* void initializeFOG ([optional] in AUTF8String aDataPathOverride, [optional] in AUTF8String aAppIdOverride, [optional] in boolean aDisableInternalPings); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD InitializeFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride, bool aDisableInternalPings) = 0;
/* void registerCustomPings (); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD RegisterCustomPings(void) = 0;
/* void setLogPings (in boolean aEnableLogPings); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetLogPings(bool aEnableLogPings) = 0;
/* void setTagPings (in ACString aDebugTag); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetTagPings(const nsACString& aDebugTag) = 0;
/* void sendPing (in ACString aPingName); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SendPing(const nsACString& aPingName) = 0;
/* [implicit_jscontext] void setExperimentActive (in ACString aExperimentId, in ACString aBranch, [optional] in jsval aExtra); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetExperimentActive(const nsACString& aExperimentId, const nsACString& aBranch, JS::Handle<JS::Value> aExtra, JSContext* cx) = 0;
/* void setExperimentInactive (in ACString aExperimentId); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetExperimentInactive(const nsACString& aExperimentId) = 0;
/* [implicit_jscontext] jsval testGetExperimentData (in ACString aExperimentId); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD TestGetExperimentData(const nsACString& aExperimentId, JSContext* cx, JS::MutableHandle<JS::Value> _retval) = 0;
/* void setMetricsFeatureConfig (in ACString aJsonConfig); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetMetricsFeatureConfig(const nsACString& aJsonConfig) = 0;
/* [implicit_jscontext] Promise testFlushAllChildren (); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD TestFlushAllChildren(JSContext* cx, ::mozilla::dom::Promise * * _retval) = 0;
/* void testResetFOG ([optional] in AUTF8String aDataPathOverride, [optional] in AUTF8String aAppIdOverride); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD TestResetFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride) = 0;
/* [implicit_jscontext] Promise testTriggerMetrics (in unsigned long aProcessType); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD TestTriggerMetrics(uint32_t aProcessType, JSContext* cx, ::mozilla::dom::Promise * * _retval) = 0;
/* uint32_t testRegisterRuntimeMetric (in ACString aType, in ACString aCategory, in ACString aName, in Array<ACString> aPings, in ACString aLifetime, in boolean aDisabled, [optional] in ACString aExtraArgs); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD TestRegisterRuntimeMetric(const nsACString& aType, const nsACString& aCategory, const nsACString& aName, const nsTArray<nsCString >& aPings, const nsACString& aLifetime, bool aDisabled, const nsACString& aExtraArgs, uint32_t *_retval) = 0;
/* uint32_t testRegisterRuntimePing (in ACString aName, in boolean aIncludeClientId, in boolean aSendIfEmpty, in boolean aPreciseTimestamps, in boolean aIncludeInfoSections, in Array<ACString> aReasonCodes); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD TestRegisterRuntimePing(const nsACString& aName, bool aIncludeClientId, bool aSendIfEmpty, bool aPreciseTimestamps, bool aIncludeInfoSections, const nsTArray<nsCString >& aReasonCodes, uint32_t *_retval) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsIFOG, NS_IFOG_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIFOG \
NS_IMETHOD InitializeFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride, bool aDisableInternalPings) override; \
NS_IMETHOD RegisterCustomPings(void) override; \
NS_IMETHOD SetLogPings(bool aEnableLogPings) override; \
NS_IMETHOD SetTagPings(const nsACString& aDebugTag) override; \
NS_IMETHOD SendPing(const nsACString& aPingName) override; \
NS_IMETHOD SetExperimentActive(const nsACString& aExperimentId, const nsACString& aBranch, JS::Handle<JS::Value> aExtra, JSContext* cx) override; \
NS_IMETHOD SetExperimentInactive(const nsACString& aExperimentId) override; \
NS_IMETHOD TestGetExperimentData(const nsACString& aExperimentId, JSContext* cx, JS::MutableHandle<JS::Value> _retval) override; \
NS_IMETHOD SetMetricsFeatureConfig(const nsACString& aJsonConfig) override; \
NS_IMETHOD TestFlushAllChildren(JSContext* cx, ::mozilla::dom::Promise * * _retval) override; \
NS_IMETHOD TestResetFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride) override; \
NS_IMETHOD TestTriggerMetrics(uint32_t aProcessType, JSContext* cx, ::mozilla::dom::Promise * * _retval) override; \
NS_IMETHOD TestRegisterRuntimeMetric(const nsACString& aType, const nsACString& aCategory, const nsACString& aName, const nsTArray<nsCString >& aPings, const nsACString& aLifetime, bool aDisabled, const nsACString& aExtraArgs, uint32_t *_retval) override; \
NS_IMETHOD TestRegisterRuntimePing(const nsACString& aName, bool aIncludeClientId, bool aSendIfEmpty, bool aPreciseTimestamps, bool aIncludeInfoSections, const nsTArray<nsCString >& aReasonCodes, uint32_t *_retval) override;
/* Use this macro when declaring the members of this interface when the
class doesn't implement the interface. This is useful for forwarding. */
#define NS_DECL_NON_VIRTUAL_NSIFOG \
nsresult InitializeFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride, bool aDisableInternalPings); \
nsresult RegisterCustomPings(void); \
nsresult SetLogPings(bool aEnableLogPings); \
nsresult SetTagPings(const nsACString& aDebugTag); \
nsresult SendPing(const nsACString& aPingName); \
nsresult SetExperimentActive(const nsACString& aExperimentId, const nsACString& aBranch, JS::Handle<JS::Value> aExtra, JSContext* cx); \
nsresult SetExperimentInactive(const nsACString& aExperimentId); \
nsresult TestGetExperimentData(const nsACString& aExperimentId, JSContext* cx, JS::MutableHandle<JS::Value> _retval); \
nsresult SetMetricsFeatureConfig(const nsACString& aJsonConfig); \
nsresult TestFlushAllChildren(JSContext* cx, ::mozilla::dom::Promise * * _retval); \
nsresult TestResetFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride); \
nsresult TestTriggerMetrics(uint32_t aProcessType, JSContext* cx, ::mozilla::dom::Promise * * _retval); \
nsresult TestRegisterRuntimeMetric(const nsACString& aType, const nsACString& aCategory, const nsACString& aName, const nsTArray<nsCString >& aPings, const nsACString& aLifetime, bool aDisabled, const nsACString& aExtraArgs, uint32_t *_retval); \
nsresult TestRegisterRuntimePing(const nsACString& aName, bool aIncludeClientId, bool aSendIfEmpty, bool aPreciseTimestamps, bool aIncludeInfoSections, const nsTArray<nsCString >& aReasonCodes, uint32_t *_retval);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIFOG(_to) \
NS_IMETHOD InitializeFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride, bool aDisableInternalPings) override { return _to InitializeFOG(aDataPathOverride, aAppIdOverride, aDisableInternalPings); } \
NS_IMETHOD RegisterCustomPings(void) override { return _to RegisterCustomPings(); } \
NS_IMETHOD SetLogPings(bool aEnableLogPings) override { return _to SetLogPings(aEnableLogPings); } \
NS_IMETHOD SetTagPings(const nsACString& aDebugTag) override { return _to SetTagPings(aDebugTag); } \
NS_IMETHOD SendPing(const nsACString& aPingName) override { return _to SendPing(aPingName); } \
NS_IMETHOD SetExperimentActive(const nsACString& aExperimentId, const nsACString& aBranch, JS::Handle<JS::Value> aExtra, JSContext* cx) override { return _to SetExperimentActive(aExperimentId, aBranch, aExtra, cx); } \
NS_IMETHOD SetExperimentInactive(const nsACString& aExperimentId) override { return _to SetExperimentInactive(aExperimentId); } \
NS_IMETHOD TestGetExperimentData(const nsACString& aExperimentId, JSContext* cx, JS::MutableHandle<JS::Value> _retval) override { return _to TestGetExperimentData(aExperimentId, cx, _retval); } \
NS_IMETHOD SetMetricsFeatureConfig(const nsACString& aJsonConfig) override { return _to SetMetricsFeatureConfig(aJsonConfig); } \
NS_IMETHOD TestFlushAllChildren(JSContext* cx, ::mozilla::dom::Promise * * _retval) override { return _to TestFlushAllChildren(cx, _retval); } \
NS_IMETHOD TestResetFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride) override { return _to TestResetFOG(aDataPathOverride, aAppIdOverride); } \
NS_IMETHOD TestTriggerMetrics(uint32_t aProcessType, JSContext* cx, ::mozilla::dom::Promise * * _retval) override { return _to TestTriggerMetrics(aProcessType, cx, _retval); } \
NS_IMETHOD TestRegisterRuntimeMetric(const nsACString& aType, const nsACString& aCategory, const nsACString& aName, const nsTArray<nsCString >& aPings, const nsACString& aLifetime, bool aDisabled, const nsACString& aExtraArgs, uint32_t *_retval) override { return _to TestRegisterRuntimeMetric(aType, aCategory, aName, aPings, aLifetime, aDisabled, aExtraArgs, _retval); } \
NS_IMETHOD TestRegisterRuntimePing(const nsACString& aName, bool aIncludeClientId, bool aSendIfEmpty, bool aPreciseTimestamps, bool aIncludeInfoSections, const nsTArray<nsCString >& aReasonCodes, uint32_t *_retval) override { return _to TestRegisterRuntimePing(aName, aIncludeClientId, aSendIfEmpty, aPreciseTimestamps, aIncludeInfoSections, aReasonCodes, _retval); }
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIFOG(_to) \
NS_IMETHOD InitializeFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride, bool aDisableInternalPings) override { return !_to ? NS_ERROR_NULL_POINTER : _to->InitializeFOG(aDataPathOverride, aAppIdOverride, aDisableInternalPings); } \
NS_IMETHOD RegisterCustomPings(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->RegisterCustomPings(); } \
NS_IMETHOD SetLogPings(bool aEnableLogPings) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetLogPings(aEnableLogPings); } \
NS_IMETHOD SetTagPings(const nsACString& aDebugTag) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetTagPings(aDebugTag); } \
NS_IMETHOD SendPing(const nsACString& aPingName) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SendPing(aPingName); } \
NS_IMETHOD SetExperimentActive(const nsACString& aExperimentId, const nsACString& aBranch, JS::Handle<JS::Value> aExtra, JSContext* cx) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetExperimentActive(aExperimentId, aBranch, aExtra, cx); } \
NS_IMETHOD SetExperimentInactive(const nsACString& aExperimentId) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetExperimentInactive(aExperimentId); } \
NS_IMETHOD TestGetExperimentData(const nsACString& aExperimentId, JSContext* cx, JS::MutableHandle<JS::Value> _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->TestGetExperimentData(aExperimentId, cx, _retval); } \
NS_IMETHOD SetMetricsFeatureConfig(const nsACString& aJsonConfig) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetMetricsFeatureConfig(aJsonConfig); } \
NS_IMETHOD TestFlushAllChildren(JSContext* cx, ::mozilla::dom::Promise * * _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->TestFlushAllChildren(cx, _retval); } \
NS_IMETHOD TestResetFOG(const nsACString& aDataPathOverride, const nsACString& aAppIdOverride) override { return !_to ? NS_ERROR_NULL_POINTER : _to->TestResetFOG(aDataPathOverride, aAppIdOverride); } \
NS_IMETHOD TestTriggerMetrics(uint32_t aProcessType, JSContext* cx, ::mozilla::dom::Promise * * _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->TestTriggerMetrics(aProcessType, cx, _retval); } \
NS_IMETHOD TestRegisterRuntimeMetric(const nsACString& aType, const nsACString& aCategory, const nsACString& aName, const nsTArray<nsCString >& aPings, const nsACString& aLifetime, bool aDisabled, const nsACString& aExtraArgs, uint32_t *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->TestRegisterRuntimeMetric(aType, aCategory, aName, aPings, aLifetime, aDisabled, aExtraArgs, _retval); } \
NS_IMETHOD TestRegisterRuntimePing(const nsACString& aName, bool aIncludeClientId, bool aSendIfEmpty, bool aPreciseTimestamps, bool aIncludeInfoSections, const nsTArray<nsCString >& aReasonCodes, uint32_t *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->TestRegisterRuntimePing(aName, aIncludeClientId, aSendIfEmpty, aPreciseTimestamps, aIncludeInfoSections, aReasonCodes, _retval); }
#endif /* __gen_nsIFOG_h__ */