1 33 34 package com.icesoft.faces.component.outputdeclaration; 35 36 import javax.faces.context.FacesContext; 37 import javax.faces.el.ValueBinding; 38 39 43 public class OutputDeclaration 44 extends javax.faces.component.UIOutput { 45 46 public static final String COMPONENT_TYPE = 47 "com.icesoft.faces.OutputDeclaration"; 48 public static final String COMPONENT_FAMILY = "javax.faces.Output"; 49 public static final String RENDERER_TYPE = 50 "com.icesoft.faces.OutputDeclaration"; 51 52 public OutputDeclaration() { 53 super(); 54 setRendererType(RENDERER_TYPE); 55 } 56 57 public String getRendererType() { 58 return RENDERER_TYPE; 59 } 60 61 public String getFamily() { 62 return COMPONENT_FAMILY; 63 } 64 65 66 private String doctypePublic = null; 68 69 72 public String getDoctypePublic() { 73 if (this.doctypePublic != null) { 74 return this.doctypePublic; 75 } 76 ValueBinding _vb = getValueBinding("doctypePublic"); 77 if (_vb != null) { 78 return (String ) _vb.getValue(getFacesContext()); 79 } 80 return null; 81 } 82 83 88 public void setDoctypePublic(String doctypePublic) { 89 this.doctypePublic = doctypePublic; 90 } 91 92 private String doctypeRoot = null; 94 95 98 public String getDoctypeRoot() { 99 if (this.doctypeRoot != null) { 100 return this.doctypeRoot; 101 } 102 ValueBinding _vb = getValueBinding("doctypeRoot"); 103 if (_vb != null) { 104 return (String ) _vb.getValue(getFacesContext()); 105 } 106 return null; 107 } 108 109 114 public void setDoctypeRoot(String doctypeRoot) { 115 this.doctypeRoot = doctypeRoot; 116 } 117 118 private String doctypeSystem = null; 120 121 124 public String getDoctypeSystem() { 125 if (this.doctypeSystem != null) { 126 return this.doctypeSystem; 127 } 128 ValueBinding _vb = getValueBinding("doctypeSystem"); 129 if (_vb != null) { 130 return (String ) _vb.getValue(getFacesContext()); 131 } 132 return null; 133 } 134 135 140 public void setDoctypeSystem(String doctypeSystem) { 141 this.doctypeSystem = doctypeSystem; 142 } 143 144 147 public void restoreState(FacesContext _context, Object _state) { 148 Object _values[] = (Object []) _state; 149 super.restoreState(_context, _values[0]); 150 this.doctypePublic = (String ) _values[1]; 151 this.doctypeRoot = (String ) _values[2]; 152 this.doctypeSystem = (String ) _values[3]; 153 } 154 155 158 public Object saveState(FacesContext _context) { 159 Object _values[] = new Object [4]; 160 _values[0] = super.saveState(_context); 161 _values[1] = this.doctypePublic; 162 _values[2] = this.doctypeRoot; 163 _values[3] = this.doctypeSystem; 164 return _values; 165 } 166 } 167 | Popular Tags |