super.process(content, context, id, propertyName);
MarinerPageContext ctx = ContextInternals.getMarinerPageContext(
context.getInitialRequestContext());
MetaData metaData = context.getPageMetaData();
MetaAttributes attributes = new MetaAttributes();
//add all search engine meta tags i.e. description, keywords, author
if(MetaPropertyHandlerFactory.DESCRIPTION.equals(propertyName)
&& DevicePolicyConstants.FULL_SUPPORT_POLICY_VALUE
.equals(ctx.getDevicePolicyValue(DevicePolicyConstants.X_ELEMENT_SUPPORTS_META_DESCRIPTION))) {
attributes.setName(MetaPropertyHandlerFactory.DESCRIPTION);
attributes.setContent((String) metaData.getPropertyValue(MetaPropertyHandlerFactory.DESCRIPTION));
ctx.getProtocol().writeMeta(attributes);
}
if(MetaPropertyHandlerFactory.KEYWORDS.equals(propertyName)
&& DevicePolicyConstants.FULL_SUPPORT_POLICY_VALUE
.equals(ctx.getDevicePolicyValue(DevicePolicyConstants.X_ELEMENT_SUPPORTS_META_KEYWORDS))) {
attributes.setName(MetaPropertyHandlerFactory.KEYWORDS);
String value = null;
if(metaData.getPropertyValue(MetaPropertyHandlerFactory.KEYWORDS) != null) {
value = normalize((String) metaData.getPropertyValue(MetaPropertyHandlerFactory.KEYWORDS));
}
attributes.setContent(value);
ctx.getProtocol().writeMeta(attributes);
}
if(MetaPropertyHandlerFactory.AUTHOR.equals(propertyName)
&& DevicePolicyConstants.FULL_SUPPORT_POLICY_VALUE
.equals(ctx.getDevicePolicyValue(DevicePolicyConstants.X_ELEMENT_SUPPORTS_META_AUTHOR))) {
attributes.setName(AUTHOR_HTML_META);
attributes.setContent((String) metaData.getPropertyValue(MetaPropertyHandlerFactory.AUTHOR));
ctx.getProtocol().writeMeta(attributes);
}
}