/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM $SRCDIR/dom/media/webspeech/synth/nsISynthVoiceRegistry.idl
 */

#ifndef __gen_nsISynthVoiceRegistry_h__
#define __gen_nsISynthVoiceRegistry_h__


#include "nsISupports.h"

/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
class nsISpeechService; /* forward declaration */


/* starting interface:    nsISynthVoiceRegistry */
#define NS_ISYNTHVOICEREGISTRY_IID_STR "5d7a0b38-77e5-4ee5-897c-ce5db9b85d44"

#define NS_ISYNTHVOICEREGISTRY_IID \
  {0x5d7a0b38, 0x77e5, 0x4ee5, \
    { 0x89, 0x7c, 0xce, 0x5d, 0xb9, 0xb8, 0x5d, 0x44 }}

class NS_NO_VTABLE MOZ_BINDING(binding_to, idl, class, XPIDL_nsISynthVoiceRegistry) nsISynthVoiceRegistry : public nsISupports {
 public:

  NS_INLINE_DECL_STATIC_IID(NS_ISYNTHVOICEREGISTRY_IID)

  /* Used by ToJSValue to check which scriptable interface is implemented. */
  using ScriptableInterfaceType = nsISynthVoiceRegistry;

  /* void addVoice (in nsISpeechService aService, in AString aUri, in AString aName, in AString aLang, in boolean aLocalService, in boolean aQueuesUtterances); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_addVoice)
  NS_IMETHOD AddVoice(nsISpeechService *aService, const nsAString& aUri, const nsAString& aName, const nsAString& aLang, bool aLocalService, bool aQueuesUtterances) = 0;

  /* void removeVoice (in nsISpeechService aService, in AString aUri); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_removeVoice)
  NS_IMETHOD RemoveVoice(nsISpeechService *aService, const nsAString& aUri) = 0;

  /* void notifyVoicesChanged (); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_notifyVoicesChanged)
  NS_IMETHOD NotifyVoicesChanged(void) = 0;

  /* void notifyVoicesError (in AString aError); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_notifyVoicesError)
  NS_IMETHOD NotifyVoicesError(const nsAString& aError) = 0;

  /* void setDefaultVoice (in AString aUri, in boolean aIsDefault); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_setDefaultVoice)
  NS_IMETHOD SetDefaultVoice(const nsAString& aUri, bool aIsDefault) = 0;

  /* readonly attribute uint32_t voiceCount; */
  MOZ_BINDING(binding_to, idl, getter, XPIDL_nsISynthVoiceRegistry_voiceCount)
  NS_IMETHOD GetVoiceCount(uint32_t *aVoiceCount) = 0;

  /* AString getVoice (in uint32_t aIndex); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_getVoice)
  NS_IMETHOD GetVoice(uint32_t aIndex, nsAString& _retval) = 0;

  /* boolean isDefaultVoice (in AString aUri); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_isDefaultVoice)
  NS_IMETHOD IsDefaultVoice(const nsAString& aUri, bool *_retval) = 0;

  /* boolean isLocalVoice (in AString aUri); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_isLocalVoice)
  NS_IMETHOD IsLocalVoice(const nsAString& aUri, bool *_retval) = 0;

  /* AString getVoiceLang (in AString aUri); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_getVoiceLang)
  NS_IMETHOD GetVoiceLang(const nsAString& aUri, nsAString& _retval) = 0;

  /* AString getVoiceName (in AString aUri); */
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_getVoiceName)
  NS_IMETHOD GetVoiceName(const nsAString& aUri, nsAString& _retval) = 0;

};


/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSISYNTHVOICEREGISTRY \
  NS_IMETHOD AddVoice(nsISpeechService *aService, const nsAString& aUri, const nsAString& aName, const nsAString& aLang, bool aLocalService, bool aQueuesUtterances) override; \
  NS_IMETHOD RemoveVoice(nsISpeechService *aService, const nsAString& aUri) override; \
  NS_IMETHOD NotifyVoicesChanged(void) override; \
  NS_IMETHOD NotifyVoicesError(const nsAString& aError) override; \
  NS_IMETHOD SetDefaultVoice(const nsAString& aUri, bool aIsDefault) override; \
  NS_IMETHOD GetVoiceCount(uint32_t *aVoiceCount) override; \
  NS_IMETHOD GetVoice(uint32_t aIndex, nsAString& _retval) override; \
  NS_IMETHOD IsDefaultVoice(const nsAString& aUri, bool *_retval) override; \
  NS_IMETHOD IsLocalVoice(const nsAString& aUri, bool *_retval) override; \
  NS_IMETHOD GetVoiceLang(const nsAString& aUri, nsAString& _retval) override; \
  NS_IMETHOD GetVoiceName(const nsAString& aUri, nsAString& _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_NSISYNTHVOICEREGISTRY \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_addVoice)\
  nsresult AddVoice(nsISpeechService *aService, const nsAString& aUri, const nsAString& aName, const nsAString& aLang, bool aLocalService, bool aQueuesUtterances); \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_removeVoice)\
  nsresult RemoveVoice(nsISpeechService *aService, const nsAString& aUri); \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_notifyVoicesChanged)\
  nsresult NotifyVoicesChanged(void); \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_notifyVoicesError)\
  nsresult NotifyVoicesError(const nsAString& aError); \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_setDefaultVoice)\
  nsresult SetDefaultVoice(const nsAString& aUri, bool aIsDefault); \
  MOZ_BINDING(binding_to, idl, getter, XPIDL_nsISynthVoiceRegistry_voiceCount)\
  nsresult GetVoiceCount(uint32_t *aVoiceCount); \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_getVoice)\
  nsresult GetVoice(uint32_t aIndex, nsAString& _retval); \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_isDefaultVoice)\
  nsresult IsDefaultVoice(const nsAString& aUri, bool *_retval); \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_isLocalVoice)\
  nsresult IsLocalVoice(const nsAString& aUri, bool *_retval); \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_getVoiceLang)\
  nsresult GetVoiceLang(const nsAString& aUri, nsAString& _retval); \
  MOZ_BINDING(binding_to, idl, method, XPIDL_nsISynthVoiceRegistry_getVoiceName)\
  nsresult GetVoiceName(const nsAString& aUri, nsAString& _retval); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSISYNTHVOICEREGISTRY(_to) \
  NS_IMETHOD AddVoice(nsISpeechService *aService, const nsAString& aUri, const nsAString& aName, const nsAString& aLang, bool aLocalService, bool aQueuesUtterances) override { return _to AddVoice(aService, aUri, aName, aLang, aLocalService, aQueuesUtterances); } \
  NS_IMETHOD RemoveVoice(nsISpeechService *aService, const nsAString& aUri) override { return _to RemoveVoice(aService, aUri); } \
  NS_IMETHOD NotifyVoicesChanged(void) override { return _to NotifyVoicesChanged(); } \
  NS_IMETHOD NotifyVoicesError(const nsAString& aError) override { return _to NotifyVoicesError(aError); } \
  NS_IMETHOD SetDefaultVoice(const nsAString& aUri, bool aIsDefault) override { return _to SetDefaultVoice(aUri, aIsDefault); } \
  NS_IMETHOD GetVoiceCount(uint32_t *aVoiceCount) override { return _to GetVoiceCount(aVoiceCount); } \
  NS_IMETHOD GetVoice(uint32_t aIndex, nsAString& _retval) override { return _to GetVoice(aIndex, _retval); } \
  NS_IMETHOD IsDefaultVoice(const nsAString& aUri, bool *_retval) override { return _to IsDefaultVoice(aUri, _retval); } \
  NS_IMETHOD IsLocalVoice(const nsAString& aUri, bool *_retval) override { return _to IsLocalVoice(aUri, _retval); } \
  NS_IMETHOD GetVoiceLang(const nsAString& aUri, nsAString& _retval) override { return _to GetVoiceLang(aUri, _retval); } \
  NS_IMETHOD GetVoiceName(const nsAString& aUri, nsAString& _retval) override { return _to GetVoiceName(aUri, _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_NSISYNTHVOICEREGISTRY(_to) \
  NS_IMETHOD AddVoice(nsISpeechService *aService, const nsAString& aUri, const nsAString& aName, const nsAString& aLang, bool aLocalService, bool aQueuesUtterances) override { return !_to ? NS_ERROR_NULL_POINTER : _to->AddVoice(aService, aUri, aName, aLang, aLocalService, aQueuesUtterances); } \
  NS_IMETHOD RemoveVoice(nsISpeechService *aService, const nsAString& aUri) override { return !_to ? NS_ERROR_NULL_POINTER : _to->RemoveVoice(aService, aUri); } \
  NS_IMETHOD NotifyVoicesChanged(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->NotifyVoicesChanged(); } \
  NS_IMETHOD NotifyVoicesError(const nsAString& aError) override { return !_to ? NS_ERROR_NULL_POINTER : _to->NotifyVoicesError(aError); } \
  NS_IMETHOD SetDefaultVoice(const nsAString& aUri, bool aIsDefault) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetDefaultVoice(aUri, aIsDefault); } \
  NS_IMETHOD GetVoiceCount(uint32_t *aVoiceCount) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetVoiceCount(aVoiceCount); } \
  NS_IMETHOD GetVoice(uint32_t aIndex, nsAString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetVoice(aIndex, _retval); } \
  NS_IMETHOD IsDefaultVoice(const nsAString& aUri, bool *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->IsDefaultVoice(aUri, _retval); } \
  NS_IMETHOD IsLocalVoice(const nsAString& aUri, bool *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->IsLocalVoice(aUri, _retval); } \
  NS_IMETHOD GetVoiceLang(const nsAString& aUri, nsAString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetVoiceLang(aUri, _retval); } \
  NS_IMETHOD GetVoiceName(const nsAString& aUri, nsAString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetVoiceName(aUri, _retval); } 

// %{C++:67-68
#define NS_SYNTHVOICEREGISTRY_CONTRACTID \
    "@mozilla.org/synth-voice-registry;1"
// %}

#endif /* __gen_nsISynthVoiceRegistry_h__ */
