nsresult nsTextEncoder::QueryInterface(REFNSIID aIID,
nsresult nsDocumentEncoderFactory::QueryInterface(REFNSIID aIID,
nsresult nsTextEncoder::QueryInterface(REFNSIID aIID,                                                  void **aInstancePtr){  if (nsnull == aInstancePtr)    return NS_ERROR_NULL_POINTER;     *aInstancePtr = 0;     if (aIID.Equals(kISupportsIID)) {    *aInstancePtr = (void *)(nsISupports*)this;     } else if (aIID.Equals(NS_GET_IID(nsIDocumentEncoder))) {    *aInstancePtr = (void *)(nsIDocumentEncoder*)this;     }  if (nsnull == *aInstancePtr)    return NS_NOINTERFACE;     NS_ADDREF_THIS();  return NS_OK;   }