/**
* Process the start tag for this instance.
*/
@Override
public int doStartTag() throws JspTagException {
// only do anything if valid user object exists
UserIF user = FrameworkUtils.getUser(pageContext);
HistoryMap history = user.getHistory();
if (history != null) {
Object obj = pageContext.findAttribute(objectName);
// log.debug("Found object " + obj );
if (obj != null) {
if (opName.equals(OP_ADD))
history.add(obj);
else
history.removeEntry(obj);
} else
log.info("Could not find object by name '" + objectName + "'.");
} else
log.info("No history attached to user object");
// empty tag has not to eval anything
return SKIP_BODY;
}
ModifyUserHistoryTag.java 文件源码
java
阅读 40
收藏 0
点赞 0
评论 0
项目:ontopia
作者:
评论列表
文章目录