Platform Explorer / Nuxeo Platform 5.8

Component org.nuxeo.ecm.platform.MailService

Documentation

Services to to manage mails.

Implementation

Services

Extension Points

XML Source

<?xml version="1.0"?>
<component name="org.nuxeo.ecm.platform.MailService">
  <documentation>
    Services to to manage mails.

    @author <a href="mailto:arussel@nuxeo.com">Alexandre Russel</a>
  </documentation>
  <service>
    <provide interface="org.nuxeo.ecm.platform.mail.service.MailService" />
  </service>
  <implementation class="org.nuxeo.ecm.platform.mail.service.MailServiceImpl" />
  <extension-point name="sessionFactory">
    <documentation>
      Extension point to register a session factory.

      <p>
        A session factory allows to create session for users. To create sessions
        the factory needs informations such as host, port, protocol ... The list
        of needed properties depends on the protocol used and if you need store,
        transport or both. For more information see the
        <a href="http://java.sun.com/products/javamail/javadocs/index.html">
          JavaMail API
        </a>
        .
      </p>
      <p>
        To get hold of a Session call: MailService mailService =
        Framework.getService(MailSerivce.class); Transport transport =
        mailSerivce.getTransport("myFactory"); Store store =
        mailServcie.getStore("myFactory");
      </p>
      <p>
        The default is to get a session for the authenticated user if any, or
        you can pass a String to get a session for a user.
      </p>
    </documentation>
    <object
      class="org.nuxeo.ecm.platform.mail.service.SessionFactoryDescriptor" />
  </extension-point>
  <extension-point name="propertiesFetcher">
    <documentation>
      Extension point to register a properties fetcher.
      <p>
        The responsability of a property fetcher is to fetch properties from any
        backend.
      </p>
    </documentation>
    <object
      class="org.nuxeo.ecm.platform.mail.fetcher.PropertiesFetcherDescriptor" />
  </extension-point>

  <extension-point name="actionPipes">
    <documentation>
      Extension point to register a list of actions.

      <p>
        An ActionPipe is a list of ActionMessage used for mail import. Default contribution
        are merged but you can override them using 'override' attribute. 

      <code>
        <pipe name="nxmail" override="true">
          <action id="StartAction" to="CreateDocumentsAction">
            org.nuxeo.ecm.platform.mail.listener.action.StartAction
          </action>
          <action id="CreateDocumentsAction">
            org.nuxeo.ecm.platform.mail.listener.action.CreateDocumentsAction
          </action>
        </pipe>
      </code>
      </p>

      <p>
        When registering the ActionPipe, the service looks for an ActionMessage named
        'StartAction', so this is a mandatory attribute. Registration of the pipe ends when
        service doesn't find the next action.
      </p>

    </documentation>
    <object
      class="org.nuxeo.ecm.platform.mail.action.MessageActionPipeDescriptor" />
  </extension-point>

</component>