public interface EmailBuilder
EmailBuilder
builds Email
s based on a given NotificationContext
and Event
.
The builders are OSGi services that are looked up as service references while sending an email for an occurring
notification.
Email builders are specific to a Event
type, and as such must provide an scr property named "topic"
indicating the event topic it wants to process.Modifier and Type | Method and Description |
---|---|
boolean |
accepts(NotificationContext context,
Event event)
Indicates whether this email builder accepts the given
NotificationContext and Event to build an
email from. |
Email |
build(NotificationContext context,
Event event,
String addressFrom)
Builds an email message from the given notification context and event.
|
boolean |
shouldBuild(NotificationContext context,
Event event)
Indicates whether this email builder should build the email given the
NotificationContext and Event |
boolean accepts(NotificationContext context, Event event)
NotificationContext
and Event
to build an
email from.context
- The notification context.event
- The event.true
if the email builder accepts the context and event.boolean shouldBuild(NotificationContext context, Event event)
NotificationContext
and Event
context
- The notification context.event
- The event.true
if the email builder should build the email.Email build(NotificationContext context, Event event, String addressFrom)
context
- The notification context.event
- The event.addressFrom
- The address from with to send the email."Copyright © 2006 - 2015 Adobe Systems Incorporated. All Rights Reserved"