Saltar para o conteúdo principal
Versão: 20 R9 BETA

Classe Transporter

Descrição

.acceptUnsecureConnection

História
ReleaseMudanças
17 R4Adicionado

.acceptUnsecureConnection : Boolean

Descrição

The .acceptUnsecureConnection property contains True if 4D is allowed to establish an unencrypted connection when encrypted connection is not possible.

It contains False if unencrypted connections are unallowed, in which case an error in returned when encrypted connection is not possible.

Estão disponíveis portos seguros:

  • SMTP

    • 465: SMTPS
    • 587 ou 25: SMTP com atualização STARTTLS se for compat[ivel com o servidor.
  • IMAP

    • 143: IMAP non-encrypted port
    • 993: IMAP com atualização STARTTLS se for compatível com o servidor
  • POP3

    • 110: Porta não criptografada POP3
    • 995: POP3 com atualização STARTTLS se suportado pelo servidor.

.authenticationMode

História
ReleaseMudanças
17 R4Adicionado

.authenticationMode : Text

Descrição

The .authenticationMode property contains the authentication mode used to open the session on the mail server.

Por padrão, o modo mais seguro suportado pelo servidor é usado.

Valores possíveis:

ValorConstantesComentário
CRAM-MD5IMAP authentication CRAM MD5Autenticação usando o protocolo CRAM-MD5
LOGINIMAP authentication loginAutenticação usando o protocolo LOGIN
OAUTH2Autenticação IMAP OAUTH2Autenticação usando o protocolo OAuth2
PLAINIMAP authentication plainAutenticação usando o protocolo PLAIN

.authenticationMode

História
ReleaseMudanças
17 R4Adicionado

.authenticationMode : Text

Descrição

The .authenticationMode property contains the authentication mode used to open the session on the mail server.

Por padrão, o modo mais seguro suportado pelo servidor é usado.

Valores possíveis:

ValorConstantesComentário
APOPAutenticação POP3 APOPAutenticação usando o protocolo APOP (POP3 apenas)
CRAM-MD5POP3 authentication CRAM MD5Autenticação usando o protocolo CRAM-MD5
LOGINPOP3 authentication loginAutenticação usando o protocolo LOGIN
OAUTH2POP3 authentication OAUTH2Autenticação usando o protocolo OAuth2
PLAINAutenticação POP3 simplesAutenticação usando o protocolo PLAIN

.authenticationMode

História
ReleaseMudanças
17 R4Adicionado

.authenticationMode : Text

Descrição

The .authenticationMode property contains the authentication mode used to open the session on the mail server.

Por padrão, o modo mais seguro suportado pelo servidor é usado.

Valores possíveis:

ValorConstantesComentário
CRAM-MD5SMTP authentication CRAM MD5Autenticação usando o protocolo CRAM-MD5
LOGINSMTP authentication loginAutenticação usando o protocolo LOGIN
OAUTH2SMTP authentication OAUTH2Autenticação usando o protocolo OAuth2
PLAINSMTP authentication plainAutenticação usando o protocolo PLAIN

.bodyCharset

História
ReleaseMudanças
18Suporte de UTF8 base64
17 R5Adicionado

.bodyCharset : Text

Descrição

The .bodyCharset property contains the charset and encoding used for the body part of the email.

Valores possíveis:

ParâmetrosValorComentário
mail mode ISO2022JPUS-ASCII_ISO-2022-JP_UTF8_QP
  • headerCharset: US-ASCII if possible, Japanese (ISO-2022-JP) & Quoted-printable if possible, otherwise UTF-8 & Quoted-printable
  • bodyCharset: US-ASCII if possible, Japanese (ISO-2022-JP) & 7-bit if possible, otherwise UTF-8 & Quoted-printable
mail mode ISO88591ISO-8859-1
  • headerCharset: ISO-8859-1 & Quoted-printable
  • bodyCharset: ISO-8859-1 & 8-bit
mail mode UTF8US-ASCII_UTF8_QPheaderCharset & bodyCharset: US-ASCII se possível, caso contrário UTF-8 & Quoted-printable (valor padrão)
modo de correio UTF8 na base64US-ASCII_UTF8_B64headerCharset & bodyCharset: US-ASCII if possible, otherwise UTF-8 & base64

.connectionTimeOut

História
ReleaseMudanças
17 R5Adicionado

.connectionTimeOut : Integer

Descrição

The .connectionTimeOut property contains the maximum wait time (in seconds) allowed to establish a connection to the server. By default, if the property has not been set in the server object (used to create the transporter object with SMTP New transporter, POP3 New transporter, or IMAP New transporter), the value is 30.


.headerCharset

História
ReleaseMudanças
17 R5Adicionado

.headerCharset : Text

Descrição

A propriedade .headerCharset contém o conjunto de caracteres e a codificação usados para o cabeçalho de e-mail. O cabeçalho inclui as seguintes partes do e-mail:

  • assunto,
  • nome(s) de arquivo anexo,
  • email name.

Valores possíveis:

ParâmetrosValorComentário
mail mode ISO2022JPUS-ASCII_ISO-2022-JP_UTF8_QP
  • headerCharset: US-ASCII if possible, Japanese (ISO-2022-JP) & Quoted-printable if possible, otherwise UTF-8 & Quoted-printable
  • bodyCharset: US-ASCII if possible, Japanese (ISO-2022-JP) & 7-bit if possible, otherwise UTF-8 & Quoted-printable
mail mode ISO88591ISO-8859-1
  • headerCharset: ISO-8859-1 & Quoted-printable
  • bodyCharset: ISO-8859-1 & 8-bit
mail mode UTF8US-ASCII_UTF8_QPheaderCharset & bodyCharset: US-ASCII if possible, otherwise UTF-8 & Quoted-printable (default value)
modo de correio UTF8 na base64US-ASCII_UTF8_B64headerCharset & bodyCharset: US-ASCII if possible, otherwise UTF-8 & base64

.host

História
ReleaseMudanças
17 R5Adicionado

.host : Text

Descrição

A propriedade .host contém o nome ou o endereço IP do servidor host. Utilizado para transacções postais (SMTP, POP3, IMAP).


.logFile

História
ReleaseMudanças
17 R5Adicionado

.logFile : Text

Descrição

The .logFile property contains the path of the extended log file defined (if any) for the mail connection. Pode ser relativo (à pasta atual de Logs) ou absoluto.

Unlike regular log files (enabled via the SET DATABASE PARAMETER command), extended log files store MIME contents of all sent mails and do not have any size limit. Para mais informações sobre arquivos de registo estendidos, consultar:


.port

História
ReleaseMudanças
17 R4Adicionado

.port : Integer

Descrição

A propriedade .port contém o número da porta utilizada para transações de email. By default, if the port property has not been set in the server object (used to create the transporter object with SMTP New transporter, POP3 New transporter, IMAP New transporter), the port used is:

  • SMTP - 587
  • POP3 - 995
  • IMAP - 993

.sendTimeOut

História
ReleaseMudanças
17 R4Adicionado

.sendTimeOut : Integer

Descrição

The .sendTimeOut property contains the maximum wait time (in seconds) of a call to .send( ) before a timeout occurs. By default, if the .sendTimeOut property has not been set in the server object, the value 100 is used.


.user

História
ReleaseMudanças
17 R4Adicionado

.user : Text

Descrição

A propriedade .user contém o nome de usuário usado para autenticação no servidor de email .


.checkConnection()

História
ReleaseMudanças
17 R4Adicionado

.checkConnection() : Object

ParâmetroTipoDescrição
ResultadosObject<-Estado da ligação do objecto transportador

Descrição

The .checkConnection() function checks the connection using information stored in the transporter object, recreates the connection if necessary, and returns the status. Esta função permite verificar se os valores fornecidos pelo utilizador são válidos e consistentes.

Objeto devolvido

A função envia um pedido para o servidor de correio e devolve um objecto descrevendo o estado do correio. Este objeto pode conter as seguintes propriedades:

PropriedadeTipoDescrição
successbooleanVerdadeiro se a verificação for bem sucedida, Falso de outra forma
statusnumber(apenas SMTP) Código de estado devolvido pelo servidor de correio (0 no caso de um problema não relacionado com o processamento de correio)
statusTexttextMensagem de estado devolvida pelo servidor de correio, ou último erro devolvido na pilha de erros 4D
errorscollectionpilha de erros 4D (não devolvida se for recebida uma resposta do servidor de correio)
[ ].errCodenumberCódigo de erro 4D
[ ].messagetextDescrição do erro 4D
[ ].componentSignaturetextAssinatura da componente interna que devolveu o erro