// Javadoc inherited from IAPIElement interface
public int elementStart(MarinerRequestContext context,
IAPIAttributes iapiAttributes)
throws IAPIException {
ArgumentAttributes attrs = (ArgumentAttributes) iapiAttributes;
MarinerPageContext pageContext =
ContextInternals.getMarinerPageContext(context);
ArgumentsElement parent = null;
try {
parent = (ArgumentsElement) pageContext.peekIAPIElement();
} catch (Exception e) {
logger.error("iapi-element-no-parent-arguments", e);
throw new IAPIException(
exceptionLocalizer.format(
"iapi-element-no-parent-arguments"),
e);
}
if (parent == null) {
logger.error("iapi-element-no-parent-arguments");
throw new IAPIException(exceptionLocalizer.format(
"iapi-element-no-parent-arguments"));
} else {
parent.addArgument(attrs.getName(), attrs.getValue());
}
// There should not be any body content for this element.
return SKIP_ELEMENT_BODY;
}