首页下载资源视频素材jsf学习实例

ZIPjsf学习实例

chenroujie2.33MB需要积分:1

资源文件列表:

jsf学习实例 大约有82个文件
  1. web12/
  2. web12/Book.jpg 28.89KB
  3. web12/ConfirmInvoice.jsp 3.67KB
  4. web12/Header.jsp 1.27KB
  5. web12/Home.jsp 1.11KB
  6. web12/index.jsp 185B
  7. web12/ModifyInvoice.jsp 3.38KB
  8. web12/Search.jsp 1.25KB
  9. web12/styles.css 4.7KB
  10. web12/ViewAccounts.jsp 912B
  11. web12/ViewInvoices.jsp 5.11KB
  12. web12/WEB-INF/
  13. web12/WEB-INF/faces-config.xml 3.95KB
  14. web12/WEB-INF/web.xml 2.22KB
  15. web12/WEB-INF/classes/
  16. web12/WEB-INF/classes/com/
  17. web12/WEB-INF/classes/com/wiley/
  18. web12/WEB-INF/classes/com/wiley/masteringjsf/
  19. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/
  20. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/Messages.properties 189B
  21. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/Messages_en_US.java 1.03KB
  22. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/test/
  23. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/test/FilterTest.java 1.81KB
  24. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/test/FilterTest.java.bck 1.81KB
  25. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/test/Suite.java 453B
  26. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/test/Suite.java.bck 453B
  27. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/
  28. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/InvoiceBean.java 6.44KB
  29. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/AccountBean.java 2.01KB
  30. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/HomePage.java 223B
  31. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/SearchPage.java 2.14KB
  32. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/ShowDetailListener.java 1.14KB
  33. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/ViewInvoicesPage.java 5.07KB
  34. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/ModifyInvoicePage.java 3.04KB
  35. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/ViewAccountsPage.java 718B
  36. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/ConfirmInvoicePage.java 2.09KB
  37. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/BooleanTextConverter.java 795B
  38. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/InvoiceAppUtils.java 1.79KB
  39. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/Filter.java 2.53KB
  40. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/bak/BusinessDelegate.java 2.8KB
  41. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/AccountBean.class 1.96KB
  42. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/BooleanTextConverter.class 826B
  43. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/BusinessDelegate$DelegateException.class 504B
  44. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/BusinessDelegate.class 2.8KB
  45. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/InvoiceBean$AmountComparator.class 603B
  46. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/InvoiceBean$DiscountComparator.class 609B
  47. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/InvoiceBean$InvoiceDateComparator.class 612B
  48. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/InvoiceBean$InvoiceNumberComparator.class 627B
  49. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/InvoiceBean.class 5.38KB
  50. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ConfirmInvoicePage.class 2.04KB
  51. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/Filter.class 2.61KB
  52. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/HomePage.class 345B
  53. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/InvoiceAppUtils.class 1.79KB
  54. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ModifyInvoicePage.class 3.23KB
  55. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/SearchPage.class 2.01KB
  56. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ShowDetailListener.class 1.13KB
  57. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ViewAccountsPage.class 855B
  58. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ViewInvoicesPage.class 4.08KB
  59. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/BooleanTextConverter.java 795B
  60. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/BusinessDelegate.java 2.8KB
  61. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ConfirmInvoicePage.java 2.14KB
  62. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/Filter.java 2.53KB
  63. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/HomePage.java 223B
  64. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/InvoiceAppUtils.java 1.79KB
  65. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/InvoiceBean.java 6.44KB
  66. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ModifyInvoicePage.java 3.04KB
  67. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/SearchPage.java 2.14KB
  68. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ShowDetailListener.java 1.14KB
  69. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ViewAccountsPage.java 718B
  70. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/ViewInvoicesPage.java 5.07KB
  71. web12/WEB-INF/classes/com/wiley/masteringjsf/ch7ex2/AccountBean.java 2.01KB
  72. web12/WEB-INF/lib/
  73. web12/WEB-INF/lib/commons-logging.jar 30.9KB
  74. web12/WEB-INF/lib/jsf-api.jar 355.93KB
  75. web12/WEB-INF/lib/jsf-impl.jar 682.17KB
  76. web12/WEB-INF/lib/commons-beanutils.jar 115.97KB
  77. web12/WEB-INF/lib/commons-collections.jar 166.9KB
  78. web12/WEB-INF/lib/commons-digester.jar 106.57KB
  79. web12/WEB-INF/lib/jstl.jar 20.54KB
  80. web12/WEB-INF/lib/standard.jar 354.97KB
  81. web12/WEB-INF/lib/myfaces-extensions.jar 738.15KB
  82. web12/WEB-INF/lib/commons-fileupload-1.0.jar 21.85KB

资源介绍:

jsf学习实例 jsf学习实例
package com.wiley.masteringjsf.ch7ex2; import java.io.Serializable; import java.util.*; import javax.faces.model.SelectItem; /** * A bean that models a simple invoice */ public class InvoiceBean implements Serializable { public static final String INVOICE_NUMBER_ID = "invoiceNumberId"; public static final String AMOUNT_ID = "amountId"; public static final String DISCOUNT_ID = "discountId"; public static final String INVOICE_DATE_ID = "invoiceDateId"; private Integer invoiceNumber; private Date invoiceDate; private Double amount;//数量 private AccountBean account; private Double discount;//折扣 private List paymentTerms = new ArrayList();//支付期限 private List statusCodes = new ArrayList(); private String paymentTerm; private Integer statusCode = new Integer(1); private boolean newCustomer; private boolean expedited; // TODO: Not sure this is used in any example... private boolean selected; public boolean isSelected() { return selected; } public void setSelected(boolean selected) { this.selected = selected; } public InvoiceBean() { } public InvoiceBean(String number, String discount, String amount) { this(new Integer(number), new Date(), new Double(amount), new Double(discount), null); } public InvoiceBean(Integer invoiceNumber, Date invoiceDate, Double amount, Double discount, AccountBean account) { setInvoiceNumber(invoiceNumber); setInvoiceDate(invoiceDate); setDiscount(discount); setAmount(amount); setAccount(account); paymentTerms.add(new SelectItem("0", "Upon Receipt", "")); paymentTerms.add(new SelectItem("30", "Net 30 Days", "")); paymentTerms.add(new SelectItem("60", "Net 60 days", "")); statusCodes.add(new SelectItem(new Integer(1), "Open", "")); statusCodes.add(new SelectItem(new Integer(2), "Past Due", "")); statusCodes.add(new SelectItem(new Integer(3), "Paid", "")); } static class InvoiceNumberComparator implements Comparator { public int compare(Object obj1, Object obj2) { Integer num1 = ((InvoiceBean) obj1).getInvoiceNumber(); Integer num2 = ((InvoiceBean) obj2).getInvoiceNumber(); return num1.compareTo(num2); } } static class AmountComparator implements Comparator { public int compare(Object obj1, Object obj2) { Double num1 = ((InvoiceBean) obj1).getAmount(); Double num2 = ((InvoiceBean) obj2).getAmount(); return num1.compareTo(num2); } } static class DiscountComparator implements Comparator { public int compare(Object obj1, Object obj2) { Double num1 = ((InvoiceBean) obj1).getDiscount(); Double num2 = ((InvoiceBean) obj2).getDiscount(); return num1.compareTo(num2); } } static class InvoiceDateComparator implements Comparator { public int compare(Object obj1, Object obj2) { Date num1 = ((InvoiceBean) obj1).getInvoiceDate(); Date num2 = ((InvoiceBean) obj2).getInvoiceDate(); return num1.compareTo(num2); } } public static Comparator getComparator(String key) { if (key.equals(INVOICE_NUMBER_ID)) return new InvoiceNumberComparator(); if (key.equals(INVOICE_DATE_ID)) return new InvoiceDateComparator(); if (key.equals(AMOUNT_ID)) return new AmountComparator(); if (key.equals(DISCOUNT_ID)) return new DiscountComparator(); throw new IllegalArgumentException("Invalid key " + key); } public String getInvoiceNumberId() { return INVOICE_NUMBER_ID; } public String getAmountId() { return AMOUNT_ID; } protected static String getLabel(List items, Object value) { if (value == null) return null; Iterator itemIter = items.iterator(); while (itemIter.hasNext()) { SelectItem item = (SelectItem) itemIter.next(); if (item.getValue().equals(value)) return item.getLabel(); } throw new IllegalArgumentException("Invalid value: " + value); } public String getSelectedTerm() { return getLabel(paymentTerms, paymentTerm); } public String getSelectedStatus() { return getLabel(statusCodes, statusCode); } /*-------- Accessor methods --------*/ public boolean isExpedited() { return expedited; } public void setExpedited(boolean expedited) { this.expedited = expedited; } public boolean isNewCustomer() { return newCustomer; } public void setNewCustomer(boolean newCustomer) { this.newCustomer = newCustomer; } public List getPaymentTerms() { return paymentTerms; } public void setPaymentTerms(List termOptions) { this.paymentTerms = termOptions; } public String getPaymentTerm() {return paymentTerm;} public void setPaymentTerm(String selectedTerm) { this.paymentTerm = selectedTerm; } public List getStatusCodes() {return statusCodes;} public void setStatusCodes(List invoiceStatusOptions) { this.statusCodes = invoiceStatusOptions; } public Integer getStatusCode() { return statusCode; } public void setStatusCode(Integer invoiceStatusCode) { this.statusCode = invoiceStatusCode; } public Integer getInvoiceNumber() { return invoiceNumber; } public void setInvoiceNumber(Integer number) { this.invoiceNumber = number; } public Date getInvoiceDate() { return invoiceDate; } public void setInvoiceDate(Date invoiceDate) { this.invoiceDate = invoiceDate; } public Double getAmount() { return amount; } public void setAmount(Double amount) { this.amount = amount; } public AccountBean getAccount() { return account; } public void setAccount(AccountBean account) { this.account = account; } public Double getDiscount() { return discount; } public void setDiscount(Double discount) { this.discount = discount; } }
100+评论
captcha