public class CreateNewsletterFunction extends CreateContentFunction implements Initializable, Contextualizable
Modifier and Type | Class and Description |
---|---|
protected class |
CreateNewsletterFunction.IgnoreRootTagHandler
Ignore the root tag.
|
protected class |
CreateNewsletterFunction.LocalImageHandler
Local image handler: injects attributes so that the image will be properly handled.
|
protected class |
CreateNewsletterFunction.NewsletterFilter
Automatic newsletter filter.
|
Modifier and Type | Field and Description |
---|---|
private CategoryProviderExtensionPoint |
_categoryProviderEP |
protected Context |
_context
The Avalon context
|
private ContentTypeExtensionPoint |
_cTypeExtPt |
protected static String |
_DEFAULT_LEVEL
The defaut content insertion level.
|
protected static Set<String> |
_IGNORE_ATTRS
The list of attributes to ignore.
|
private SAXParserFactory |
_saxParserFactory |
private SourceResolver |
_sourceResolver |
private TransformerFactory |
_transformerFactory |
private Properties |
_transformerProperties |
static String |
NEWSLETTER_CATEGORY_KEY
Newsletter category key.
|
static String |
NEWSLETTER_CONTENT_ID_MAP_KEY
Key for content ID map when processing auto sections.
|
static DateFormat |
NEWSLETTER_DATE_FORMAT
The date format.
|
static String |
NEWSLETTER_DATE_KEY
Newsletter date key.
|
static String |
NEWSLETTER_IS_AUTOMATIC_KEY
Newsletter automatic property key.
|
static String |
NEWSLETTER_NUMBER_KEY
Newsletter number key.
|
static String |
NEWSLETTER_PROCESS_AUTO_SECTIONS_KEY
Key for "process auto sections".
|
_currentUserProvider, _siteManager, PAGE_KEY, PAGE_ZONE_KEY, SITE_KEY
_observationManager, _resolver, CONTENT_LANGUAGE_KEY, CONTENT_MIXINS_KEY, CONTENT_NAME_KEY, CONTENT_TITLE_KEY, CONTENT_TYPES_KEY, PARENT_CONTENT_ID_KEY, PARENT_CONTENT_METADATA_PATH_KEY
CONTENT_KEY
_logger, _manager, CONTEXT_PARAMETERS_KEY, FAIL_CONDITIONS_KEY, RESULT_MAP_KEY, WORKFLOW_ERRORS_KEY, WORKFLOW_WARNS_KEY
Constructor and Description |
---|
CreateNewsletterFunction() |
Modifier and Type | Method and Description |
---|---|
private String |
_getContent(String skinId,
String templateId) |
private void |
_initContentRichText(ModifiableContent content,
String skinId,
String categoryID,
boolean processAutoSections,
Map<String,AutomaticNewsletterFilterResult> filterResults) |
protected void |
_populateContent(Map transientVars,
ModifiableContent content)
Populate the content.
|
private String |
_processAutoTags(String text,
boolean processAutoSections,
Map<String,AutomaticNewsletterFilterResult> filterResults,
String contentId) |
void |
contextualize(Context context) |
void |
initialize() |
void |
service(ServiceManager manager) |
_createContent, _getContentRoot, _notifyContentAdded, _populateAdditionalData
_getNonNullVar, _getObjectType, _getSubContentRoot, execute, getSystemUser
getContent
addWorkflowError, addWorkflowWarning, enableLogging, getConditionFailures, getContextParameters, getResultsMap, getUser
public static final String NEWSLETTER_CATEGORY_KEY
public static final String NEWSLETTER_NUMBER_KEY
public static final String NEWSLETTER_DATE_KEY
public static final String NEWSLETTER_IS_AUTOMATIC_KEY
public static final String NEWSLETTER_PROCESS_AUTO_SECTIONS_KEY
public static final String NEWSLETTER_CONTENT_ID_MAP_KEY
public static final DateFormat NEWSLETTER_DATE_FORMAT
protected static final Set<String> _IGNORE_ATTRS
protected static final String _DEFAULT_LEVEL
private SourceResolver _sourceResolver
private ContentTypeExtensionPoint _cTypeExtPt
private CategoryProviderExtensionPoint _categoryProviderEP
private TransformerFactory _transformerFactory
private Properties _transformerProperties
private SAXParserFactory _saxParserFactory
public CreateNewsletterFunction()
public void contextualize(Context context) throws ContextException
contextualize
in interface Contextualizable
ContextException
public void service(ServiceManager manager) throws ServiceException
service
in interface Serviceable
service
in class CreateContentFunction
ServiceException
public void initialize() throws Exception
initialize
in interface Initializable
Exception
protected void _populateContent(Map transientVars, ModifiableContent content) throws com.opensymphony.workflow.WorkflowException
CreateContentFunction
_populateContent
in class CreateContentFunction
transientVars
- the transient variables.content
- the content.com.opensymphony.workflow.WorkflowException
- if an error occurs.private void _initContentRichText(ModifiableContent content, String skinId, String categoryID, boolean processAutoSections, Map<String,AutomaticNewsletterFilterResult> filterResults) throws com.opensymphony.workflow.WorkflowException
com.opensymphony.workflow.WorkflowException
private String _processAutoTags(String text, boolean processAutoSections, Map<String,AutomaticNewsletterFilterResult> filterResults, String contentId) throws com.opensymphony.workflow.WorkflowException
com.opensymphony.workflow.WorkflowException
private String _getContent(String skinId, String templateId) throws IOException, com.opensymphony.workflow.WorkflowException
IOException
com.opensymphony.workflow.WorkflowException