/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsISOAPResponse.idl
 */

#ifndef __gen_nsISOAPResponse_h__
#define __gen_nsISOAPResponse_h__

#include "nsISupports.h"

class nsIDOMElement; /* forward declaration */

class nsISOAPParameter; /* forward declaration */

class nsISOAPFault; /* forward declaration */


/* starting interface:    nsISOAPResponse */
#define NS_ISOAPRESPONSE_IID_STR "99ec6691-535f-11d4-9a58-000064657374"

#define NS_ISOAPRESPONSE_IID \
  {0x99ec6691, 0x535f, 0x11d4, \
    { 0x9a, 0x58, 0x00, 0x00, 0x64, 0x65, 0x73, 0x74 }}

class NS_NO_VTABLE nsISOAPResponse : public nsISupports {
 public: 

  NS_DEFINE_STATIC_IID_ACCESSOR(NS_ISOAPRESPONSE_IID)

  /**
   * The DOM element representing the SOAP envelope in the response.
   * DOM methods may be used to access attributes and children of this
   * element. While the element and it's subtree are not readonly,
   * the expectation is that they will not be modified.
   */
  /* readonly attribute nsIDOMElement envelope; */
  NS_IMETHOD GetEnvelope(nsIDOMElement * *aEnvelope) = 0;

  /**
   * A convenience attribute to obtain the DOM element representing 
   * the response envelope header, if one exists. NULL if no header
   * exists in the response.
   */
  /* readonly attribute nsIDOMElement header; */
  NS_IMETHOD GetHeader(nsIDOMElement * *aHeader) = 0;

  /**
   * A convenience attribute to obtain the DOM element representing
   * the response envelope body. While DOM interfaces and methods may
   * be used to access body entries, the expectation is that the
   * <code>returnValue</code> property will be used if the response
   * represents the result of a RPC call.
   */
  /* readonly attribute nsIDOMElement body; */
  NS_IMETHOD GetBody(nsIDOMElement * *aBody) = 0;

  /**
   * The status code returned by the underlying transport.
   */
  /* readonly attribute unsigned long status; */
  NS_IMETHOD GetStatus(PRUint32 *aStatus) = 0;

  /**
   * The target object on which the method was invoked. This URI
   * is generally used as the namespace to qualify the tagname of 
   * the element that is the single body entry of the SOAP response.
   */
  /* readonly attribute string targetObjectURI; */
  NS_IMETHOD GetTargetObjectURI(char * *aTargetObjectURI) = 0;

  /**
   * The name of the method that was invoked. The methodName is used as
   * the tagname for the element that is the single body entry of the
   * SOAP message.
   */
  /* readonly attribute string methodName; */
  NS_IMETHOD GetMethodName(char * *aMethodName) = 0;

  /**
   * Did the response generate a fault?
   *
   * @returns Whether a fault was generated a not. If the return value
   *          is <code>true</code>, the fault details can be obtained
   *          from the <code>fault</code> property.
   */
  /* boolean generatedFault (); */
  NS_IMETHOD GeneratedFault(PRBool *_retval) = 0;

  /**
   * The fault returned in the response, if one was generated. NULL
   * if there was no fault.
   */
  /* readonly attribute nsISOAPFault fault; */
  NS_IMETHOD GetFault(nsISOAPFault * *aFault) = 0;

  /**
   * The result from the first body entry in the response SOAP message.
   */
  /* readonly attribute nsISOAPParameter returnValue; */
  NS_IMETHOD GetReturnValue(nsISOAPParameter * *aReturnValue) = 0;

};

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSISOAPRESPONSE \
  NS_IMETHOD GetEnvelope(nsIDOMElement * *aEnvelope); \
  NS_IMETHOD GetHeader(nsIDOMElement * *aHeader); \
  NS_IMETHOD GetBody(nsIDOMElement * *aBody); \
  NS_IMETHOD GetStatus(PRUint32 *aStatus); \
  NS_IMETHOD GetTargetObjectURI(char * *aTargetObjectURI); \
  NS_IMETHOD GetMethodName(char * *aMethodName); \
  NS_IMETHOD GeneratedFault(PRBool *_retval); \
  NS_IMETHOD GetFault(nsISOAPFault * *aFault); \
  NS_IMETHOD GetReturnValue(nsISOAPParameter * *aReturnValue); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSISOAPRESPONSE(_to) \
  NS_IMETHOD GetEnvelope(nsIDOMElement * *aEnvelope) { return _to ## GetEnvelope(aEnvelope); } \
  NS_IMETHOD GetHeader(nsIDOMElement * *aHeader) { return _to ## GetHeader(aHeader); } \
  NS_IMETHOD GetBody(nsIDOMElement * *aBody) { return _to ## GetBody(aBody); } \
  NS_IMETHOD GetStatus(PRUint32 *aStatus) { return _to ## GetStatus(aStatus); } \
  NS_IMETHOD GetTargetObjectURI(char * *aTargetObjectURI) { return _to ## GetTargetObjectURI(aTargetObjectURI); } \
  NS_IMETHOD GetMethodName(char * *aMethodName) { return _to ## GetMethodName(aMethodName); } \
  NS_IMETHOD GeneratedFault(PRBool *_retval) { return _to ## GeneratedFault(_retval); } \
  NS_IMETHOD GetFault(nsISOAPFault * *aFault) { return _to ## GetFault(aFault); } \
  NS_IMETHOD GetReturnValue(nsISOAPParameter * *aReturnValue) { return _to ## GetReturnValue(aReturnValue); } 

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

/* Header file */
class nsSOAPResponse : public nsISOAPResponse
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSISOAPRESPONSE

  nsSOAPResponse();
  virtual ~nsSOAPResponse();
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(nsSOAPResponse, nsISOAPResponse)

nsSOAPResponse::nsSOAPResponse()
{
  NS_INIT_ISUPPORTS();
  /* member initializers and constructor code */
}

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

/* readonly attribute nsIDOMElement envelope; */
NS_IMETHODIMP nsSOAPResponse::GetEnvelope(nsIDOMElement * *aEnvelope)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute nsIDOMElement header; */
NS_IMETHODIMP nsSOAPResponse::GetHeader(nsIDOMElement * *aHeader)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute nsIDOMElement body; */
NS_IMETHODIMP nsSOAPResponse::GetBody(nsIDOMElement * *aBody)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute unsigned long status; */
NS_IMETHODIMP nsSOAPResponse::GetStatus(PRUint32 *aStatus)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute string targetObjectURI; */
NS_IMETHODIMP nsSOAPResponse::GetTargetObjectURI(char * *aTargetObjectURI)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute string methodName; */
NS_IMETHODIMP nsSOAPResponse::GetMethodName(char * *aMethodName)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* boolean generatedFault (); */
NS_IMETHODIMP nsSOAPResponse::GeneratedFault(PRBool *_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute nsISOAPFault fault; */
NS_IMETHODIMP nsSOAPResponse::GetFault(nsISOAPFault * *aFault)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute nsISOAPParameter returnValue; */
NS_IMETHODIMP nsSOAPResponse::GetReturnValue(nsISOAPParameter * *aReturnValue)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

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

#define NS_SOAPRESPONSE_CID                         \
{ /* 87d21ec3-539d-11d4-9a59-00104bdf5339 */        \
  0x87d21ec3, 0x539d, 0x11d4,                       \
 {0x9a, 0x59, 0x00, 0x10, 0x4b, 0xdf, 0x53, 0x39} }
#define NS_SOAPRESPONSE_CONTRACTID \
"@mozilla.org/xmlextras/soap/response;1"

#endif /* __gen_nsISOAPResponse_h__ */
