Back to index

lightning-sunbird  0.9+nobinonly
Functions
nsMsgEncoders.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

MimeEncoderDataMIME_B64EncoderInit (nsresult(*output_fn)(const char *buf, PRInt32 size, void *closure), void *closure)
MimeEncoderDataMIME_QPEncoderInit (nsresult(*output_fn)(const char *buf, PRInt32 size, void *closure), void *closure)
MimeEncoderDataMIME_UUEncoderInit (char *filename, nsresult(*output_fn)(const char *buf, PRInt32 size, void *closure), void *closure)
nsresult MIME_EncoderDestroy (MimeEncoderData *data, PRBool abort_p)
nsresult MIME_EncoderWrite (MimeEncoderData *data, const char *buffer, PRInt32 size)

Function Documentation

MimeEncoderData* MIME_B64EncoderInit ( nsresult(*)(const char *buf, PRInt32 size, void *closure output_fn,
void closure 
)

Definition at line 48 of file nsMsgEncoders.cpp.

{
  MimeEncoderData *returnEncoderData = nsnull;
  nsIMimeConverter *converter;
  nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);
  if (NS_SUCCEEDED(res) && nsnull != converter) 
  {
    res = converter->B64EncoderInit(output_fn, closure, &returnEncoderData);
    NS_RELEASE(converter);
  }
  return NS_SUCCEEDED(res) ? returnEncoderData : nsnull;
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 90 of file nsMsgEncoders.cpp.

{
  //MimeEncoderData *returnEncoderData = nsnull;
  nsIMimeConverter *converter;
  nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);
  if (NS_SUCCEEDED(res) && nsnull != converter) 
  {
    res = converter->EncoderDestroy(data, abort_p);
    NS_RELEASE(converter);
  }

  return NS_SUCCEEDED(res) ? 0 : -1;
}

Here is the call graph for this function:

Here is the caller graph for this function:

nsresult MIME_EncoderWrite ( MimeEncoderData data,
const char *  buffer,
PRInt32  size 
)

Definition at line 105 of file nsMsgEncoders.cpp.

{
  //  MimeEncoderData *returnEncoderData = nsnull;
  nsIMimeConverter *converter;
  PRInt32 written = 0;
  nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);
  if (NS_SUCCEEDED(res) && nsnull != converter) {
    res = converter->EncoderWrite(data, buffer, size, &written);
    NS_RELEASE(converter);
  }
  return NS_SUCCEEDED(res) ? 0 : -1;
}

Here is the call graph for this function:

Here is the caller graph for this function:

MimeEncoderData* MIME_QPEncoderInit ( nsresult(*)(const char *buf, PRInt32 size, void *closure output_fn,
void closure 
)

Definition at line 62 of file nsMsgEncoders.cpp.

{
  MimeEncoderData *returnEncoderData = nsnull;
  nsIMimeConverter *converter;
  nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);
  if (NS_SUCCEEDED(res) && nsnull != converter) 
  {
    res = converter->QPEncoderInit(output_fn, closure, &returnEncoderData);
    NS_RELEASE(converter);
  }
  return NS_SUCCEEDED(res) ? returnEncoderData : nsnull;
}

Here is the call graph for this function:

Here is the caller graph for this function:

MimeEncoderData* MIME_UUEncoderInit ( char *  filename,
nsresult(*)(const char *buf, PRInt32 size, void *closure output_fn,
void closure 
)

Definition at line 76 of file nsMsgEncoders.cpp.

{
  MimeEncoderData *returnEncoderData = nsnull;
  nsIMimeConverter *converter;
  nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);
  if (NS_SUCCEEDED(res) && nsnull != converter) 
  {
    res = converter->UUEncoderInit(filename, output_fn, closure, &returnEncoderData);
    NS_RELEASE(converter);
  }
  return NS_SUCCEEDED(res) ? returnEncoderData : nsnull;
}

Here is the call graph for this function:

Here is the caller graph for this function: