Copy as Markdown

Other Tools

/*
* DO NOT EDIT. THIS FILE IS GENERATED FROM $SRCDIR/netwerk/protocol/http/nsIObliviousHttp.idl
*/
#ifndef __gen_nsIObliviousHttp_h__
#define __gen_nsIObliviousHttp_h__
#include "nsISupports.h"
#include "nsTArray.h"
/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
class nsIChannel; /* forward declaration */
class nsIURI; /* forward declaration */
/* starting interface: nsIObliviousHttpClientResponse */
#define NS_IOBLIVIOUSHTTPCLIENTRESPONSE_IID_STR "f2a4aaa4-046a-439e-beef-893b15a90cff"
#define NS_IOBLIVIOUSHTTPCLIENTRESPONSE_IID \
{0xf2a4aaa4, 0x046a, 0x439e, \
{ 0xbe, 0xef, 0x89, 0x3b, 0x15, 0xa9, 0x0c, 0xff }}
class NS_NO_VTABLE nsIObliviousHttpClientResponse : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IOBLIVIOUSHTTPCLIENTRESPONSE_IID)
/* Used by ToJSValue to check which scriptable interface is implemented. */
using ScriptableInterfaceType = nsIObliviousHttpClientResponse;
/* Array<octet> decapsulate (in Array<octet> encResponse); */
NS_IMETHOD Decapsulate(const nsTArray<uint8_t >& encResponse, nsTArray<uint8_t >& _retval) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsIObliviousHttpClientResponse, NS_IOBLIVIOUSHTTPCLIENTRESPONSE_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIOBLIVIOUSHTTPCLIENTRESPONSE \
NS_IMETHOD Decapsulate(const nsTArray<uint8_t >& encResponse, nsTArray<uint8_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_NSIOBLIVIOUSHTTPCLIENTRESPONSE \
nsresult Decapsulate(const nsTArray<uint8_t >& encResponse, nsTArray<uint8_t >& _retval);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIOBLIVIOUSHTTPCLIENTRESPONSE(_to) \
NS_IMETHOD Decapsulate(const nsTArray<uint8_t >& encResponse, nsTArray<uint8_t >& _retval) override { return _to Decapsulate(encResponse, _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_NSIOBLIVIOUSHTTPCLIENTRESPONSE(_to) \
NS_IMETHOD Decapsulate(const nsTArray<uint8_t >& encResponse, nsTArray<uint8_t >& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Decapsulate(encResponse, _retval); }
/* starting interface: nsIObliviousHttpClientRequest */
#define NS_IOBLIVIOUSHTTPCLIENTREQUEST_IID_STR "403af7f9-4a76-49fc-a622-38d6ba3ee496"
#define NS_IOBLIVIOUSHTTPCLIENTREQUEST_IID \
{0x403af7f9, 0x4a76, 0x49fc, \
{ 0xa6, 0x22, 0x38, 0xd6, 0xba, 0x3e, 0xe4, 0x96 }}
class NS_NO_VTABLE nsIObliviousHttpClientRequest : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IOBLIVIOUSHTTPCLIENTREQUEST_IID)
/* Used by ToJSValue to check which scriptable interface is implemented. */
using ScriptableInterfaceType = nsIObliviousHttpClientRequest;
/* readonly attribute Array<octet> encRequest; */
NS_IMETHOD GetEncRequest(nsTArray<uint8_t >& aEncRequest) = 0;
/* readonly attribute nsIObliviousHttpClientResponse response; */
NS_IMETHOD GetResponse(nsIObliviousHttpClientResponse **aResponse) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsIObliviousHttpClientRequest, NS_IOBLIVIOUSHTTPCLIENTREQUEST_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIOBLIVIOUSHTTPCLIENTREQUEST \
NS_IMETHOD GetEncRequest(nsTArray<uint8_t >& aEncRequest) override; \
NS_IMETHOD GetResponse(nsIObliviousHttpClientResponse **aResponse) 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_NSIOBLIVIOUSHTTPCLIENTREQUEST \
nsresult GetEncRequest(nsTArray<uint8_t >& aEncRequest); \
nsresult GetResponse(nsIObliviousHttpClientResponse **aResponse);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIOBLIVIOUSHTTPCLIENTREQUEST(_to) \
NS_IMETHOD GetEncRequest(nsTArray<uint8_t >& aEncRequest) override { return _to GetEncRequest(aEncRequest); } \
NS_IMETHOD GetResponse(nsIObliviousHttpClientResponse **aResponse) override { return _to GetResponse(aResponse); }
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIOBLIVIOUSHTTPCLIENTREQUEST(_to) \
NS_IMETHOD GetEncRequest(nsTArray<uint8_t >& aEncRequest) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetEncRequest(aEncRequest); } \
NS_IMETHOD GetResponse(nsIObliviousHttpClientResponse **aResponse) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetResponse(aResponse); }
/* starting interface: nsIObliviousHttpServerResponse */
#define NS_IOBLIVIOUSHTTPSERVERRESPONSE_IID_STR "105deb62-45b4-407a-b330-550433279111"
#define NS_IOBLIVIOUSHTTPSERVERRESPONSE_IID \
{0x105deb62, 0x45b4, 0x407a, \
{ 0xb3, 0x30, 0x55, 0x04, 0x33, 0x27, 0x91, 0x11 }}
class NS_NO_VTABLE nsIObliviousHttpServerResponse : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IOBLIVIOUSHTTPSERVERRESPONSE_IID)
/* Used by ToJSValue to check which scriptable interface is implemented. */
using ScriptableInterfaceType = nsIObliviousHttpServerResponse;
/* readonly attribute Array<octet> request; */
NS_IMETHOD GetRequest(nsTArray<uint8_t >& aRequest) = 0;
/* Array<octet> encapsulate (in Array<octet> response); */
NS_IMETHOD Encapsulate(const nsTArray<uint8_t >& response, nsTArray<uint8_t >& _retval) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsIObliviousHttpServerResponse, NS_IOBLIVIOUSHTTPSERVERRESPONSE_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIOBLIVIOUSHTTPSERVERRESPONSE \
NS_IMETHOD GetRequest(nsTArray<uint8_t >& aRequest) override; \
NS_IMETHOD Encapsulate(const nsTArray<uint8_t >& response, nsTArray<uint8_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_NSIOBLIVIOUSHTTPSERVERRESPONSE \
nsresult GetRequest(nsTArray<uint8_t >& aRequest); \
nsresult Encapsulate(const nsTArray<uint8_t >& response, nsTArray<uint8_t >& _retval);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIOBLIVIOUSHTTPSERVERRESPONSE(_to) \
NS_IMETHOD GetRequest(nsTArray<uint8_t >& aRequest) override { return _to GetRequest(aRequest); } \
NS_IMETHOD Encapsulate(const nsTArray<uint8_t >& response, nsTArray<uint8_t >& _retval) override { return _to Encapsulate(response, _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_NSIOBLIVIOUSHTTPSERVERRESPONSE(_to) \
NS_IMETHOD GetRequest(nsTArray<uint8_t >& aRequest) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetRequest(aRequest); } \
NS_IMETHOD Encapsulate(const nsTArray<uint8_t >& response, nsTArray<uint8_t >& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Encapsulate(response, _retval); }
/* starting interface: nsIObliviousHttpServer */
#define NS_IOBLIVIOUSHTTPSERVER_IID_STR "fb1abc56-b525-4e1a-a4c6-341a9b32084e"
#define NS_IOBLIVIOUSHTTPSERVER_IID \
{0xfb1abc56, 0xb525, 0x4e1a, \
{ 0xa4, 0xc6, 0x34, 0x1a, 0x9b, 0x32, 0x08, 0x4e }}
class NS_NO_VTABLE nsIObliviousHttpServer : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IOBLIVIOUSHTTPSERVER_IID)
/* Used by ToJSValue to check which scriptable interface is implemented. */
using ScriptableInterfaceType = nsIObliviousHttpServer;
/* readonly attribute Array<octet> encodedConfig; */
NS_IMETHOD GetEncodedConfig(nsTArray<uint8_t >& aEncodedConfig) = 0;
/* nsIObliviousHttpServerResponse decapsulate (in Array<octet> encRequest); */
NS_IMETHOD Decapsulate(const nsTArray<uint8_t >& encRequest, nsIObliviousHttpServerResponse **_retval) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsIObliviousHttpServer, NS_IOBLIVIOUSHTTPSERVER_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIOBLIVIOUSHTTPSERVER \
NS_IMETHOD GetEncodedConfig(nsTArray<uint8_t >& aEncodedConfig) override; \
NS_IMETHOD Decapsulate(const nsTArray<uint8_t >& encRequest, nsIObliviousHttpServerResponse **_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_NSIOBLIVIOUSHTTPSERVER \
nsresult GetEncodedConfig(nsTArray<uint8_t >& aEncodedConfig); \
nsresult Decapsulate(const nsTArray<uint8_t >& encRequest, nsIObliviousHttpServerResponse **_retval);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIOBLIVIOUSHTTPSERVER(_to) \
NS_IMETHOD GetEncodedConfig(nsTArray<uint8_t >& aEncodedConfig) override { return _to GetEncodedConfig(aEncodedConfig); } \
NS_IMETHOD Decapsulate(const nsTArray<uint8_t >& encRequest, nsIObliviousHttpServerResponse **_retval) override { return _to Decapsulate(encRequest, _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_NSIOBLIVIOUSHTTPSERVER(_to) \
NS_IMETHOD GetEncodedConfig(nsTArray<uint8_t >& aEncodedConfig) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetEncodedConfig(aEncodedConfig); } \
NS_IMETHOD Decapsulate(const nsTArray<uint8_t >& encRequest, nsIObliviousHttpServerResponse **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Decapsulate(encRequest, _retval); }
/* starting interface: nsIObliviousHttp */
#define NS_IOBLIVIOUSHTTP_IID_STR "d581149e-3319-4563-b95e-46c64af5c4e8"
#define NS_IOBLIVIOUSHTTP_IID \
{0xd581149e, 0x3319, 0x4563, \
{ 0xb9, 0x5e, 0x46, 0xc6, 0x4a, 0xf5, 0xc4, 0xe8 }}
class NS_NO_VTABLE nsIObliviousHttp : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IOBLIVIOUSHTTP_IID)
/* Used by ToJSValue to check which scriptable interface is implemented. */
using ScriptableInterfaceType = nsIObliviousHttp;
/* nsIObliviousHttpClientRequest encapsulateRequest (in Array<octet> encodedConfig, in Array<octet> request); */
NS_IMETHOD EncapsulateRequest(const nsTArray<uint8_t >& encodedConfig, const nsTArray<uint8_t >& request, nsIObliviousHttpClientRequest **_retval) = 0;
/* nsIObliviousHttpServer server (); */
NS_IMETHOD Server(nsIObliviousHttpServer **_retval) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsIObliviousHttp, NS_IOBLIVIOUSHTTP_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIOBLIVIOUSHTTP \
NS_IMETHOD EncapsulateRequest(const nsTArray<uint8_t >& encodedConfig, const nsTArray<uint8_t >& request, nsIObliviousHttpClientRequest **_retval) override; \
NS_IMETHOD Server(nsIObliviousHttpServer **_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_NSIOBLIVIOUSHTTP \
nsresult EncapsulateRequest(const nsTArray<uint8_t >& encodedConfig, const nsTArray<uint8_t >& request, nsIObliviousHttpClientRequest **_retval); \
nsresult Server(nsIObliviousHttpServer **_retval);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIOBLIVIOUSHTTP(_to) \
NS_IMETHOD EncapsulateRequest(const nsTArray<uint8_t >& encodedConfig, const nsTArray<uint8_t >& request, nsIObliviousHttpClientRequest **_retval) override { return _to EncapsulateRequest(encodedConfig, request, _retval); } \
NS_IMETHOD Server(nsIObliviousHttpServer **_retval) override { return _to Server(_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_NSIOBLIVIOUSHTTP(_to) \
NS_IMETHOD EncapsulateRequest(const nsTArray<uint8_t >& encodedConfig, const nsTArray<uint8_t >& request, nsIObliviousHttpClientRequest **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->EncapsulateRequest(encodedConfig, request, _retval); } \
NS_IMETHOD Server(nsIObliviousHttpServer **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Server(_retval); }
/* starting interface: nsIObliviousHttpService */
#define NS_IOBLIVIOUSHTTPSERVICE_IID_STR "b1f08d56-fca6-4290-9500-d5168dc9d8c3"
#define NS_IOBLIVIOUSHTTPSERVICE_IID \
{0xb1f08d56, 0xfca6, 0x4290, \
{ 0x95, 0x00, 0xd5, 0x16, 0x8d, 0xc9, 0xd8, 0xc3 }}
class NS_NO_VTABLE nsIObliviousHttpService : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IOBLIVIOUSHTTPSERVICE_IID)
/* Used by ToJSValue to check which scriptable interface is implemented. */
using ScriptableInterfaceType = nsIObliviousHttpService;
/* nsIChannel newChannel (in nsIURI relayURI, in nsIURI targetURI, in Array<octet> encodedConfig); */
NS_IMETHOD NewChannel(nsIURI *relayURI, nsIURI *targetURI, const nsTArray<uint8_t >& encodedConfig, nsIChannel **_retval) = 0;
/* void getTRRSettings (out nsIURI relayURI, out Array<octet> encodedConfig); */
NS_IMETHOD GetTRRSettings(nsIURI **relayURI, nsTArray<uint8_t >& encodedConfig) = 0;
/* void clearTRRConfig (); */
NS_IMETHOD ClearTRRConfig(void) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsIObliviousHttpService, NS_IOBLIVIOUSHTTPSERVICE_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIOBLIVIOUSHTTPSERVICE \
NS_IMETHOD NewChannel(nsIURI *relayURI, nsIURI *targetURI, const nsTArray<uint8_t >& encodedConfig, nsIChannel **_retval) override; \
NS_IMETHOD GetTRRSettings(nsIURI **relayURI, nsTArray<uint8_t >& encodedConfig) override; \
NS_IMETHOD ClearTRRConfig(void) 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_NSIOBLIVIOUSHTTPSERVICE \
nsresult NewChannel(nsIURI *relayURI, nsIURI *targetURI, const nsTArray<uint8_t >& encodedConfig, nsIChannel **_retval); \
nsresult GetTRRSettings(nsIURI **relayURI, nsTArray<uint8_t >& encodedConfig); \
nsresult ClearTRRConfig(void);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIOBLIVIOUSHTTPSERVICE(_to) \
NS_IMETHOD NewChannel(nsIURI *relayURI, nsIURI *targetURI, const nsTArray<uint8_t >& encodedConfig, nsIChannel **_retval) override { return _to NewChannel(relayURI, targetURI, encodedConfig, _retval); } \
NS_IMETHOD GetTRRSettings(nsIURI **relayURI, nsTArray<uint8_t >& encodedConfig) override { return _to GetTRRSettings(relayURI, encodedConfig); } \
NS_IMETHOD ClearTRRConfig(void) override { return _to ClearTRRConfig(); }
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIOBLIVIOUSHTTPSERVICE(_to) \
NS_IMETHOD NewChannel(nsIURI *relayURI, nsIURI *targetURI, const nsTArray<uint8_t >& encodedConfig, nsIChannel **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->NewChannel(relayURI, targetURI, encodedConfig, _retval); } \
NS_IMETHOD GetTRRSettings(nsIURI **relayURI, nsTArray<uint8_t >& encodedConfig) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTRRSettings(relayURI, encodedConfig); } \
NS_IMETHOD ClearTRRConfig(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ClearTRRConfig(); }
#endif /* __gen_nsIObliviousHttp_h__ */