models.protocols

Class CFMailProtocol

lucee.Component
    extended by cbmailservices.models.AbstractProtocol
      extended by models.protocols.CFMailProtocol

Copyright Since 2005 ColdBox Framework by Luis Majano and Ortus Solutions, Corp www.ortussolutions.com ---- This protocol sends mail via the cfmail tag.

Class Attributes:
  • singleton
  •  
  • synchronized : false
  •  
  • accessors : true
  •  
  • persistent : false
  •  
  • author : Robert Rawlings, Luis Majano
  •  
    Constructor Summary
    init([struct properties='[runtime expression]'])
          Initialize the File protocol.
    Method Summary
    private any mailIt(any payload)
         Mail a payload according to its contents.
    struct send(cbmailservices.models.Mail<cbmailservices.models.Mail> payload)
         Send mails to html files on disk.
     
    Methods inherited from class cbmailservices.models.AbstractProtocol
    getLog, getName, getProperties, getProperty, propertyExists, setLog, setName, setProperties, setProperty
     
    Methods inherited from class lucee.Component
    None

    Constructor Detail

    init

    public init([struct properties='[runtime expression]'])

    Initialize the File protocol

    Parameters:
    properties - A map of configuration properties for the protocol

    Method Detail

    mailIt

    private any mailIt(any payload)

    Mail a payload according to its contents

    Parameters:
    payload

    send

    public struct send(cbmailservices.models.Mail<cbmailservices.models.Mail> payload)

    Send mails to html files on disk The return is a struct with two keys - `error` - A boolean flag if the message was sent or not - `messages` - An array of error messages the protocol stored if any

    Overrides:
    send in class cbmailservices.models.AbstractProtocol
    Parameters:
    payload - The paylod object to send the message with
    Returns:
    struct of { "error" : boolean, "messages" : [] }