CamelTransport: Camel Reference Manual

## CamelTransport CamelTransport |

## Functions

gboolean | camel_transport_send_to_sync ()
void | camel_transport_send_to ()
gboolean | camel_transport_send_to_finish ()

## Description

## Functions

### camel_transport_send_to_sync ()

    gboolean
    camel_transport_send_to_sync (CamelTransport *transport,
                                  CamelMimeMessage *message,
                                  CamelAddress *from,
                                  CamelAddress *recipients,
                                  gboolean *out_sent_message_saved,
                                  GCancellable *cancellable,
                                  GError **error);

Sends the message to the given recipients, regardless of the contents of `message` . If the message contains a "Bcc" header, the transport is responsible for stripping it.

#### Parameters

transport | a CamelTransport |
message | a CamelMimeMessage to send |
from | a CamelAddress to send from |
recipients | a CamelAddress containing all recipients |
out_sent_message_saved | set to `TRUE`, if the sent message was also saved. | [out]
cancellable | optional GCancellable object, or `NULL` |
error | return location for a GError, or `NULL` |

#### Returns

`TRUE` on success or `FALSE` on error

Since: 3.0

### camel_transport_send_to ()

    void
    camel_transport_send_to (CamelTransport *transport,
                             CamelMimeMessage *message,
                             CamelAddress *from,
                             CamelAddress *recipients,
                             gint io_priority,
                             GCancellable *cancellable,
                             GAsyncReadyCallback callback,
                             gpointer user_data);

Sends the message asynchronously to the given recipients, regardless of the contents of `message` . If the message contains a "Bcc" header, the transport is responsible for stripping it.

When the operation is finished, `callback` will be called. You can then call `camel_transport_send_to_finish()` to get the result of the operation.

#### Parameters

transport | a CamelTransport |
message | a CamelMimeMessage to send |
from | a CamelAddress to send from |
recipients | a CamelAddress containing all recipients |
io_priority | the I/O priority of the request |
cancellable | optional GCancellable object, or `NULL` |
callback | a GAsyncReadyCallback to call when the request is satisfied |
user_data | data to pass to the callback function |

Since: 3.0

### camel_transport_send_to_finish ()

    gboolean
    camel_transport_send_to_finish (CamelTransport *transport,
                                    GAsyncResult *result,
                                    gboolean *out_sent_message_saved,
                                    GError **error);

Finishes the operation started with `camel_transport_send_to()`.

#### Parameters

transport | a CamelTransport |
result | a GAsyncResult |
out_sent_message_saved | set to `TRUE`, if the sent message was also saved. | [out]
error | return locaton for a GError, or `NULL` |

#### Returns

`TRUE` on success, `FALSE` on error

Since: 3.0

## Types and Values