1 14 15 package com.sun.facelets.tag.jstl.core; 16 17 import javax.faces.component.UIComponent; 18 19 import com.sun.facelets.tag.TagAttribute; 20 import com.sun.facelets.tag.TagConfig; 21 import java.io.IOException ; 22 23 import javax.el.ELException; 24 import javax.faces.FacesException; 25 26 import com.sun.facelets.FaceletContext; 27 import com.sun.facelets.FaceletException; 28 import com.sun.facelets.tag.TagHandler; 29 30 34 public final class ChooseWhenHandler extends TagHandler { 35 36 private final TagAttribute test; 37 38 public ChooseWhenHandler(TagConfig config) { 39 super(config); 40 this.test = this.getRequiredAttribute("test"); 41 } 42 43 public void apply(FaceletContext ctx, UIComponent parent) 44 throws IOException , FacesException, FaceletException, ELException { 45 this.nextHandler.apply(ctx, parent); 46 } 47 48 public boolean isTestTrue(FaceletContext ctx) { 49 return this.test.getBoolean(ctx); 50 } 51 } 52 | Popular Tags |