1 18 19 package org.apache.strutsel.taglib.html; 20 21 import org.apache.struts.taglib.html.RadioTag; 22 import javax.servlet.jsp.JspException ; 23 import org.apache.strutsel.taglib.utils.EvalHelper; 24 25 36 public class ELRadioTag extends RadioTag { 37 38 42 private String accessKeyExpr; 43 47 private String altExpr; 48 52 private String altKeyExpr; 53 57 private String bundleExpr; 58 62 private String disabledExpr; 63 67 private String errorKeyExpr; 68 72 private String errorStyleExpr; 73 77 private String errorStyleClassExpr; 78 82 private String errorStyleIdExpr; 83 87 private String idNameExpr; 88 92 private String indexedExpr; 93 97 private String nameExpr; 98 102 private String onblurExpr; 103 107 private String onchangeExpr; 108 112 private String onclickExpr; 113 117 private String ondblclickExpr; 118 122 private String onfocusExpr; 123 127 private String onkeydownExpr; 128 132 private String onkeypressExpr; 133 137 private String onkeyupExpr; 138 142 private String onmousedownExpr; 143 147 private String onmousemoveExpr; 148 152 private String onmouseoutExpr; 153 157 private String onmouseoverExpr; 158 162 private String onmouseupExpr; 163 167 private String propertyExpr; 168 172 private String styleExpr; 173 177 private String styleClassExpr; 178 182 private String styleIdExpr; 183 187 private String tabindexExpr; 188 192 private String titleExpr; 193 197 private String titleKeyExpr; 198 202 private String valueExpr; 203 204 208 public String getAccesskeyExpr() { return (accessKeyExpr); } 209 213 public String getAltExpr() { return (altExpr); } 214 218 public String getAltKeyExpr() { return (altKeyExpr); } 219 223 public String getBundleExpr() { return (bundleExpr); } 224 228 public String getDisabledExpr() { return (disabledExpr); } 229 233 public String getErrorKeyExpr() { return (errorKeyExpr); } 234 238 public String getErrorStyleExpr() { return (errorStyleExpr); } 239 243 public String getErrorStyleClassExpr() { return (errorStyleClassExpr); } 244 248 public String getErrorStyleIdExpr() { return (errorStyleIdExpr); } 249 253 public String getIdNameExpr() { return (idNameExpr); } 254 258 public String getIndexedExpr() { return (indexedExpr); } 259 263 public String getNameExpr() { return (nameExpr); } 264 268 public String getOnblurExpr() { return (onblurExpr); } 269 273 public String getOnchangeExpr() { return (onchangeExpr); } 274 278 public String getOnclickExpr() { return (onclickExpr); } 279 283 public String getOndblclickExpr() { return (ondblclickExpr); } 284 288 public String getOnfocusExpr() { return (onfocusExpr); } 289 293 public String getOnkeydownExpr() { return (onkeydownExpr); } 294 298 public String getOnkeypressExpr() { return (onkeypressExpr); } 299 303 public String getOnkeyupExpr() { return (onkeyupExpr); } 304 308 public String getOnmousedownExpr() { return (onmousedownExpr); } 309 313 public String getOnmousemoveExpr() { return (onmousemoveExpr); } 314 318 public String getOnmouseoutExpr() { return (onmouseoutExpr); } 319 323 public String getOnmouseoverExpr() { return (onmouseoverExpr); } 324 328 public String getOnmouseupExpr() { return (onmouseupExpr); } 329 333 public String getPropertyExpr() { return (propertyExpr); } 334 338 public String getStyleExpr() { return (styleExpr); } 339 343 public String getStyleClassExpr() { return (styleClassExpr); } 344 348 public String getStyleIdExpr() { return (styleIdExpr); } 349 353 public String getTabindexExpr() { return (tabindexExpr); } 354 358 public String getTitleExpr() { return (titleExpr); } 359 363 public String getTitleKeyExpr() { return (titleKeyExpr); } 364 368 public String getValueExpr() { return (valueExpr); } 369 370 374 public void setAccesskeyExpr(String accessKeyExpr) { this.accessKeyExpr = accessKeyExpr; } 375 379 public void setAltExpr(String altExpr) { this.altExpr = altExpr; } 380 384 public void setAltKeyExpr(String altKeyExpr) { this.altKeyExpr = altKeyExpr; } 385 389 public void setBundleExpr(String bundleExpr) { this.bundleExpr = bundleExpr; } 390 394 public void setDisabledExpr(String disabledExpr) { this.disabledExpr = disabledExpr; } 395 399 public void setErrorKeyExpr(String errorKeyExpr) { this.errorKeyExpr = errorKeyExpr; } 400 404 public void setErrorStyleExpr(String errorStyleExpr) { this.errorStyleExpr = errorStyleExpr; } 405 409 public void setErrorStyleClassExpr(String errorStyleClassExpr) { this.errorStyleClassExpr = errorStyleClassExpr; } 410 414 public void setErrorStyleIdExpr(String errorStyleIdExpr) { this.errorStyleIdExpr = errorStyleIdExpr; } 415 419 public void setIdNameExpr(String idNameExpr) { this.idNameExpr = idNameExpr; } 420 424 public void setIndexedExpr(String indexedExpr) { this.indexedExpr = indexedExpr; } 425 429 public void setNameExpr(String nameExpr) { this.nameExpr = nameExpr; } 430 434 public void setOnblurExpr(String onblurExpr) { this.onblurExpr = onblurExpr; } 435 439 public void setOnchangeExpr(String onchangeExpr) { this.onchangeExpr = onchangeExpr; } 440 444 public void setOnclickExpr(String onclickExpr) { this.onclickExpr = onclickExpr; } 445 449 public void setOndblclickExpr(String ondblclickExpr) { this.ondblclickExpr = ondblclickExpr; } 450 454 public void setOnfocusExpr(String onfocusExpr) { this.onfocusExpr = onfocusExpr; } 455 459 public void setOnkeydownExpr(String onkeydownExpr) { this.onkeydownExpr = onkeydownExpr; } 460 464 public void setOnkeypressExpr(String onkeypressExpr) { this.onkeypressExpr = onkeypressExpr; } 465 469 public void setOnkeyupExpr(String onkeyupExpr) { this.onkeyupExpr = onkeyupExpr; } 470 474 public void setOnmousedownExpr(String onmousedownExpr) { this.onmousedownExpr = onmousedownExpr; } 475 479 public void setOnmousemoveExpr(String onmousemoveExpr) { this.onmousemoveExpr = onmousemoveExpr; } 480 484 public void setOnmouseoutExpr(String onmouseoutExpr) { this.onmouseoutExpr = onmouseoutExpr; } 485 489 public void setOnmouseoverExpr(String onmouseoverExpr) { this.onmouseoverExpr = onmouseoverExpr; } 490 494 public void setOnmouseupExpr(String onmouseupExpr) { this.onmouseupExpr = onmouseupExpr; } 495 499 public void setPropertyExpr(String propertyExpr) { this.propertyExpr = propertyExpr; } 500 504 public void setStyleExpr(String styleExpr) { this.styleExpr = styleExpr; } 505 509 public void setStyleClassExpr(String styleClassExpr) { this.styleClassExpr = styleClassExpr; } 510 514 public void setStyleIdExpr(String styleIdExpr) { this.styleIdExpr = styleIdExpr; } 515 519 public void setTabindexExpr(String tabindexExpr) { this.tabindexExpr = tabindexExpr; } 520 524 public void setTitleExpr(String titleExpr) { this.titleExpr = titleExpr; } 525 529 public void setTitleKeyExpr(String titleKeyExpr) { this.titleKeyExpr = titleKeyExpr; } 530 534 public void setValueExpr(String valueExpr) { this.valueExpr = valueExpr; } 535 536 539 public void release() 540 { 541 super.release(); 542 setAccesskeyExpr(null); 543 setAltExpr(null); 544 setAltKeyExpr(null); 545 setBundleExpr(null); 546 setDisabledExpr(null); 547 setErrorKey(null); 548 setErrorStyleExpr(null); 549 setErrorStyleClassExpr(null); 550 setErrorStyleIdExpr(null); 551 setIdNameExpr(null); 552 setIndexedExpr(null); 553 setNameExpr(null); 554 setOnblurExpr(null); 555 setOnchangeExpr(null); 556 setOnclickExpr(null); 557 setOndblclickExpr(null); 558 setOnfocusExpr(null); 559 setOnkeydownExpr(null); 560 setOnkeypressExpr(null); 561 setOnkeyupExpr(null); 562 setOnmousedownExpr(null); 563 setOnmousemoveExpr(null); 564 setOnmouseoutExpr(null); 565 setOnmouseoverExpr(null); 566 setOnmouseupExpr(null); 567 setPropertyExpr(null); 568 setStyleExpr(null); 569 setStyleClassExpr(null); 570 setStyleIdExpr(null); 571 setTabindexExpr(null); 572 setTitleExpr(null); 573 setTitleKeyExpr(null); 574 setValueExpr(null); 575 } 576 577 582 public int doStartTag() throws JspException { 583 evaluateExpressions(); 584 return(super.doStartTag()); 585 } 586 587 593 private void evaluateExpressions() throws JspException { 594 String string = null; 595 Boolean bool = null; 596 597 if ((string = EvalHelper.evalString("accessKey", getAccesskeyExpr(), 598 this, pageContext)) != null) 599 setAccesskey(string); 600 601 if ((string = EvalHelper.evalString("alt", getAltExpr(), 602 this, pageContext)) != null) 603 setAlt(string); 604 605 if ((string = EvalHelper.evalString("altKey", getAltKeyExpr(), 606 this, pageContext)) != null) 607 setAltKey(string); 608 609 if ((string = EvalHelper.evalString("bundle", getBundleExpr(), 610 this, pageContext)) != null) 611 setBundle(string); 612 613 if ((bool = EvalHelper.evalBoolean("disabled", getDisabledExpr(), 614 this, pageContext)) != null) 615 setDisabled(bool.booleanValue()); 616 617 if ((string = EvalHelper.evalString("errorKey", getErrorKeyExpr(), 618 this, pageContext)) != null) 619 setErrorKey(string); 620 621 if ((string = EvalHelper.evalString("errorStyle", getErrorStyleExpr(), 622 this, pageContext)) != null) 623 setErrorStyle(string); 624 625 if ((string = EvalHelper.evalString("errorStyleClass", getErrorStyleClassExpr(), 626 this, pageContext)) != null) 627 setErrorStyleClass(string); 628 629 if ((string = EvalHelper.evalString("errorStyleId", getErrorStyleIdExpr(), 630 this, pageContext)) != null) 631 setErrorStyleId(string); 632 633 if ((string = EvalHelper.evalString("idName", getIdNameExpr(), 634 this, pageContext)) != null) 635 setIdName(string); 636 637 if ((bool = EvalHelper.evalBoolean("indexed", getIndexedExpr(), 638 this, pageContext)) != null) 639 setIndexed(bool.booleanValue()); 640 641 if ((string = EvalHelper.evalString("name", getNameExpr(), 642 this, pageContext)) != null) 643 setName(string); 644 645 if ((string = EvalHelper.evalString("onblur", getOnblurExpr(), 646 this, pageContext)) != null) 647 setOnblur(string); 648 649 if ((string = EvalHelper.evalString("onchange", getOnchangeExpr(), 650 this, pageContext)) != null) 651 setOnchange(string); 652 653 if ((string = EvalHelper.evalString("onclick", getOnclickExpr(), 654 this, pageContext)) != null) 655 setOnclick(string); 656 657 if ((string = EvalHelper.evalString("ondblclick", getOndblclickExpr(), 658 this, pageContext)) != null) 659 setOndblclick(string); 660 661 if ((string = EvalHelper.evalString("onfocus", getOnfocusExpr(), 662 this, pageContext)) != null) 663 setOnfocus(string); 664 665 if ((string = EvalHelper.evalString("onkeydown", getOnkeydownExpr(), 666 this, pageContext)) != null) 667 setOnkeydown(string); 668 669 if ((string = EvalHelper.evalString("onkeypress", getOnkeypressExpr(), 670 this, pageContext)) != null) 671 setOnkeypress(string); 672 673 if ((string = EvalHelper.evalString("onkeyup", getOnkeyupExpr(), 674 this, pageContext)) != null) 675 setOnkeyup(string); 676 677 if ((string = EvalHelper.evalString("onmousedown", getOnmousedownExpr(), 678 this, pageContext)) != null) 679 setOnmousedown(string); 680 681 if ((string = EvalHelper.evalString("onmousemove", getOnmousemoveExpr(), 682 this, pageContext)) != null) 683 setOnmousemove(string); 684 685 if ((string = EvalHelper.evalString("onmouseout", getOnmouseoutExpr(), 686 this, pageContext)) != null) 687 setOnmouseout(string); 688 689 if ((string = EvalHelper.evalString("onmouseover", getOnmouseoverExpr(), 690 this, pageContext)) != null) 691 setOnmouseover(string); 692 693 if ((string = EvalHelper.evalString("onmouseup", getOnmouseupExpr(), 694 this, pageContext)) != null) 695 setOnmouseup(string); 696 697 if ((string = EvalHelper.evalString("property", getPropertyExpr(), 698 this, pageContext)) != null) 699 setProperty(string); 700 701 if ((string = EvalHelper.evalString("style", getStyleExpr(), 702 this, pageContext)) != null) 703 setStyle(string); 704 705 if ((string = EvalHelper.evalString("styleClass", getStyleClassExpr(), 706 this, pageContext)) != null) 707 setStyleClass(string); 708 709 if ((string = EvalHelper.evalString("styleId", getStyleIdExpr(), 710 this, pageContext)) != null) 711 setStyleId(string); 712 713 if ((string = EvalHelper.evalString("tabindex", getTabindexExpr(), 714 this, pageContext)) != null) 715 setTabindex(string); 716 717 if ((string = EvalHelper.evalString("title", getTitleExpr(), 718 this, pageContext)) != null) 719 setTitle(string); 720 721 if ((string = EvalHelper.evalString("titleKey", getTitleKeyExpr(), 722 this, pageContext)) != null) 723 setTitleKey(string); 724 725 if ((string = EvalHelper.evalString("value", getValueExpr(), 726 this, pageContext)) != null) 727 setValue(string); 728 } 729 } 730 | Popular Tags |