示例#1
0
  public int doStartTag() throws JspException {

    PNTag pnTag = (PNTag) this.getParent();
    if (pnTag == null) return Tag.SKIP_BODY;
    pn = pnTag.getPn();
    if (pn == null || !(pn instanceof EPN)) return Tag.SKIP_BODY;

    EPN epn = (EPN) pn;

    int seq = Integer.parseInt(sequence);
    attributeMeta = epn.getSortedAttributeMeta(seq);
    if (attributeMeta == null) return Tag.SKIP_BODY;

    if (!attributeMeta.hasActivated()) return Tag.SKIP_BODY;

    pageContext.setAttribute("attributeTitle", attributeMeta.getAttributeTitle());
    pageContext.setAttribute("attributeIndex", attributeMeta.getAttributeIndex() + "");

    return EVAL_BODY_INCLUDE;
  }
示例#2
0
 public AttributeValue getSelectedAttributeValue() {
   return ((EPN) this.pn).getAttributeValue(attributeMeta.getAttributeIndex());
 }
示例#3
0
 /**
  * Constructor.
  *
  * @param attributeMeta the meta data of attribute
  * @throws NullPointerException if the attributeMeta parameter is null
  */
 public DescCriterion(AttributeMeta<?, ?> attributeMeta) throws NullPointerException {
   super(attributeMeta);
   sort = new Sort(attributeMeta.getName(), SortDirection.DESCENDING);
 }