/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM ../../../dist/idl\nsITextInputProcessor.idl
 */

#ifndef __gen_nsITextInputProcessor_h__
#define __gen_nsITextInputProcessor_h__


#ifndef __gen_nsISupports_h__
#include "nsISupports.h"
#endif

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

class nsITextInputProcessorCallback; /* forward declaration */


/* starting interface:    nsITextInputProcessor */
#define NS_ITEXTINPUTPROCESSOR_IID_STR "512f1efe-9e0f-48a4-b423-3936ef948f34"

#define NS_ITEXTINPUTPROCESSOR_IID \
  {0x512f1efe, 0x9e0f, 0x48a4, \
    { 0xb4, 0x23, 0x39, 0x36, 0xef, 0x94, 0x8f, 0x34 }}

class NS_NO_VTABLE nsITextInputProcessor : public nsISupports {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_ITEXTINPUTPROCESSOR_IID)

  /* boolean beginInputTransaction (in nsIDOMWindow aWindow, in nsITextInputProcessorCallback aCallback); */
  NS_IMETHOD BeginInputTransaction(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, bool *_retval) = 0;

  /* [optional_argc] boolean beginInputTransactionForTests (in nsIDOMWindow aWindow, [optional] in nsITextInputProcessorCallback aCallback); */
  NS_IMETHOD BeginInputTransactionForTests(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, uint8_t _argc, bool *_retval) = 0;

  /* boolean startComposition (); */
  NS_IMETHOD StartComposition(bool *_retval) = 0;

  /* void setPendingCompositionString (in DOMString aString); */
  NS_IMETHOD SetPendingCompositionString(const nsAString & aString) = 0;

  enum {
    ATTR_RAW_CLAUSE = 2U,
    ATTR_SELECTED_RAW_CLAUSE = 3U,
    ATTR_CONVERTED_CLAUSE = 4U,
    ATTR_SELECTED_CLAUSE = 5U
  };

  /* void appendClauseToPendingComposition (in unsigned long aLength, in unsigned long aAttribute); */
  NS_IMETHOD AppendClauseToPendingComposition(uint32_t aLength, uint32_t aAttribute) = 0;

  /* void setCaretInPendingComposition (in unsigned long aOffset); */
  NS_IMETHOD SetCaretInPendingComposition(uint32_t aOffset) = 0;

  /* boolean flushPendingComposition (); */
  NS_IMETHOD FlushPendingComposition(bool *_retval) = 0;

  /* [optional_argc] boolean commitComposition ([optional] in DOMString aCommitString); */
  NS_IMETHOD CommitComposition(const nsAString & aCommitString, uint8_t _argc, bool *_retval) = 0;

  /* void cancelComposition (); */
  NS_IMETHOD CancelComposition(void) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsITextInputProcessor, NS_ITEXTINPUTPROCESSOR_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSITEXTINPUTPROCESSOR \
  NS_IMETHOD BeginInputTransaction(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, bool *_retval) MOZ_OVERRIDE; \
  NS_IMETHOD BeginInputTransactionForTests(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, uint8_t _argc, bool *_retval) MOZ_OVERRIDE; \
  NS_IMETHOD StartComposition(bool *_retval) MOZ_OVERRIDE; \
  NS_IMETHOD SetPendingCompositionString(const nsAString & aString) MOZ_OVERRIDE; \
  NS_IMETHOD AppendClauseToPendingComposition(uint32_t aLength, uint32_t aAttribute) MOZ_OVERRIDE; \
  NS_IMETHOD SetCaretInPendingComposition(uint32_t aOffset) MOZ_OVERRIDE; \
  NS_IMETHOD FlushPendingComposition(bool *_retval) MOZ_OVERRIDE; \
  NS_IMETHOD CommitComposition(const nsAString & aCommitString, uint8_t _argc, bool *_retval) MOZ_OVERRIDE; \
  NS_IMETHOD CancelComposition(void) MOZ_OVERRIDE; 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSITEXTINPUTPROCESSOR(_to) \
  NS_IMETHOD BeginInputTransaction(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, bool *_retval) MOZ_OVERRIDE { return _to BeginInputTransaction(aWindow, aCallback, _retval); } \
  NS_IMETHOD BeginInputTransactionForTests(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, uint8_t _argc, bool *_retval) MOZ_OVERRIDE { return _to BeginInputTransactionForTests(aWindow, aCallback, _argc, _retval); } \
  NS_IMETHOD StartComposition(bool *_retval) MOZ_OVERRIDE { return _to StartComposition(_retval); } \
  NS_IMETHOD SetPendingCompositionString(const nsAString & aString) MOZ_OVERRIDE { return _to SetPendingCompositionString(aString); } \
  NS_IMETHOD AppendClauseToPendingComposition(uint32_t aLength, uint32_t aAttribute) MOZ_OVERRIDE { return _to AppendClauseToPendingComposition(aLength, aAttribute); } \
  NS_IMETHOD SetCaretInPendingComposition(uint32_t aOffset) MOZ_OVERRIDE { return _to SetCaretInPendingComposition(aOffset); } \
  NS_IMETHOD FlushPendingComposition(bool *_retval) MOZ_OVERRIDE { return _to FlushPendingComposition(_retval); } \
  NS_IMETHOD CommitComposition(const nsAString & aCommitString, uint8_t _argc, bool *_retval) MOZ_OVERRIDE { return _to CommitComposition(aCommitString, _argc, _retval); } \
  NS_IMETHOD CancelComposition(void) MOZ_OVERRIDE { return _to CancelComposition(); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSITEXTINPUTPROCESSOR(_to) \
  NS_IMETHOD BeginInputTransaction(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, bool *_retval) MOZ_OVERRIDE { return !_to ? NS_ERROR_NULL_POINTER : _to->BeginInputTransaction(aWindow, aCallback, _retval); } \
  NS_IMETHOD BeginInputTransactionForTests(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, uint8_t _argc, bool *_retval) MOZ_OVERRIDE { return !_to ? NS_ERROR_NULL_POINTER : _to->BeginInputTransactionForTests(aWindow, aCallback, _argc, _retval); } \
  NS_IMETHOD StartComposition(bool *_retval) MOZ_OVERRIDE { return !_to ? NS_ERROR_NULL_POINTER : _to->StartComposition(_retval); } \
  NS_IMETHOD SetPendingCompositionString(const nsAString & aString) MOZ_OVERRIDE { return !_to ? NS_ERROR_NULL_POINTER : _to->SetPendingCompositionString(aString); } \
  NS_IMETHOD AppendClauseToPendingComposition(uint32_t aLength, uint32_t aAttribute) MOZ_OVERRIDE { return !_to ? NS_ERROR_NULL_POINTER : _to->AppendClauseToPendingComposition(aLength, aAttribute); } \
  NS_IMETHOD SetCaretInPendingComposition(uint32_t aOffset) MOZ_OVERRIDE { return !_to ? NS_ERROR_NULL_POINTER : _to->SetCaretInPendingComposition(aOffset); } \
  NS_IMETHOD FlushPendingComposition(bool *_retval) MOZ_OVERRIDE { return !_to ? NS_ERROR_NULL_POINTER : _to->FlushPendingComposition(_retval); } \
  NS_IMETHOD CommitComposition(const nsAString & aCommitString, uint8_t _argc, bool *_retval) MOZ_OVERRIDE { return !_to ? NS_ERROR_NULL_POINTER : _to->CommitComposition(aCommitString, _argc, _retval); } \
  NS_IMETHOD CancelComposition(void) MOZ_OVERRIDE { return !_to ? NS_ERROR_NULL_POINTER : _to->CancelComposition(); } 

#if 0
/* Use the code below as a template for the implementation class for this interface. */

/* Header file */
class nsTextInputProcessor : public nsITextInputProcessor
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSITEXTINPUTPROCESSOR

  nsTextInputProcessor();

private:
  ~nsTextInputProcessor();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS(nsTextInputProcessor, nsITextInputProcessor)

nsTextInputProcessor::nsTextInputProcessor()
{
  /* member initializers and constructor code */
}

nsTextInputProcessor::~nsTextInputProcessor()
{
  /* destructor code */
}

/* boolean beginInputTransaction (in nsIDOMWindow aWindow, in nsITextInputProcessorCallback aCallback); */
NS_IMETHODIMP nsTextInputProcessor::BeginInputTransaction(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, bool *_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [optional_argc] boolean beginInputTransactionForTests (in nsIDOMWindow aWindow, [optional] in nsITextInputProcessorCallback aCallback); */
NS_IMETHODIMP nsTextInputProcessor::BeginInputTransactionForTests(nsIDOMWindow *aWindow, nsITextInputProcessorCallback *aCallback, uint8_t _argc, bool *_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* boolean startComposition (); */
NS_IMETHODIMP nsTextInputProcessor::StartComposition(bool *_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void setPendingCompositionString (in DOMString aString); */
NS_IMETHODIMP nsTextInputProcessor::SetPendingCompositionString(const nsAString & aString)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void appendClauseToPendingComposition (in unsigned long aLength, in unsigned long aAttribute); */
NS_IMETHODIMP nsTextInputProcessor::AppendClauseToPendingComposition(uint32_t aLength, uint32_t aAttribute)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void setCaretInPendingComposition (in unsigned long aOffset); */
NS_IMETHODIMP nsTextInputProcessor::SetCaretInPendingComposition(uint32_t aOffset)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* boolean flushPendingComposition (); */
NS_IMETHODIMP nsTextInputProcessor::FlushPendingComposition(bool *_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [optional_argc] boolean commitComposition ([optional] in DOMString aCommitString); */
NS_IMETHODIMP nsTextInputProcessor::CommitComposition(const nsAString & aCommitString, uint8_t _argc, bool *_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void cancelComposition (); */
NS_IMETHODIMP nsTextInputProcessor::CancelComposition()
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* End of implementation class template. */
#endif

#define TEXT_INPUT_PROCESSOR_CID \
  { 0xcaaab47f, 0x1e31, 0x478e, \
    { 0x89, 0x19, 0x97, 0x09, 0x04, 0xe9, 0xcb, 0x72 } }
#define TEXT_INPUT_PROCESSOR_CONTRACTID \
  "@mozilla.org/text-input-processor;1"

#endif /* __gen_nsITextInputProcessor_h__ */
