Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

copy trunk to branch for release procedure

  • Loading branch information...
commit 6c96fa36ab8fcb3c8488d27ae05e5449d287542a 2 parents da345b4 + b6d9870
Leonardo Uribe authored
Showing with 11,901 additions and 5,992 deletions.
  1. +39 −14 api/pom.xml
  2. +0 −114 api/src/main/java-templates/javax/faces/component/UICommandTemplate.java
  3. +0 −72 api/src/main/java-templates/javax/faces/component/UIGraphicTemplate.java
  4. +0 −401 api/src/main/java-templates/javax/faces/component/UIInputTemplate.java
  5. +0 −27 api/src/main/java-templates/javax/faces/component/UINamingContainerTemplate.java
  6. +0 −30 api/src/main/java-templates/javax/faces/component/UIOutputTemplate.java
  7. +0 −102 api/src/main/java-templates/javax/faces/component/UISelectBooleanTemplate.java
  8. +0 −60 api/src/main/java-templates/javax/faces/component/UISelectOneTemplate.java
  9. +0 −365 api/src/main/java-templates/javax/faces/component/UIViewRootTemplate.java
  10. +18 −15 api/src/main/java/javax/faces/FacesException.java
  11. +14 −11 api/src/main/java/javax/faces/FactoryFinder.java
  12. +16 −13 api/src/main/java/javax/faces/application/Application.java
  13. +16 −13 api/src/main/java/javax/faces/application/ApplicationFactory.java
  14. +16 −13 api/src/main/java/javax/faces/application/FacesMessage.java
  15. +16 −13 api/src/main/java/javax/faces/application/NavigationHandler.java
  16. +16 −13 api/src/main/java/javax/faces/application/StateManager.java
  17. +14 −11 api/src/main/java/javax/faces/application/StateManagerWrapper.java
  18. +14 −11 api/src/main/java/javax/faces/application/ViewExpiredException.java
  19. +60 −46 api/src/main/java/javax/faces/application/ViewHandler.java
  20. +21 −18 api/src/main/java/javax/faces/application/ViewHandlerWrapper.java
  21. +16 −13 api/src/main/java/javax/faces/component/ActionSource.java
  22. +14 −11 api/src/main/java/javax/faces/component/ActionSource2.java
  23. +15 −12 api/src/main/java/javax/faces/component/ContextCallback.java
  24. +16 −13 api/src/main/java/javax/faces/component/EditableValueHolder.java
  25. +50 −14 api/src/main/java/javax/faces/component/NamingContainer.java
  26. +16 −13 api/src/main/java/javax/faces/component/StateHolder.java
  27. +21 −15 api/src/main/java/javax/faces/component/UIColumn.java
  28. +334 −0 api/src/main/java/javax/faces/component/UICommand.java
  29. +72 −61 api/src/main/java/javax/faces/component/UIComponent.java
  30. +41 −16 api/src/main/java/javax/faces/component/UIComponentBase.java
  31. +392 −231 ...in/{java-templates/javax/faces/component/UIDataTemplate.java → java/javax/faces/component/UIData.java}
  32. +22 −13 api/src/main/java/javax/faces/component/UIForm.java
  33. +142 −0 api/src/main/java/javax/faces/component/UIGraphic.java
  34. +866 −0 api/src/main/java/javax/faces/component/UIInput.java
  35. +48 −0 api/src/main/java/javax/faces/component/UINamingContainer.java
  36. +134 −0 api/src/main/java/javax/faces/component/UIOutput.java
  37. +47 −0 api/src/main/java/javax/faces/component/UIPanel.java
  38. +150 −0 api/src/main/java/javax/faces/component/UISelectBoolean.java
  39. +139 −76 ...plates/javax/faces/component/UISelectManyTemplate.java → java/javax/faces/component/UISelectMany.java}
  40. +99 −0 api/src/main/java/javax/faces/component/UISelectOne.java
  41. +676 −0 api/src/main/java/javax/faces/component/UIViewRoot.java
  42. +14 −11 api/src/main/java/javax/faces/component/ValueHolder.java
  43. +18 −15 api/src/main/java/javax/faces/component/_AttachedListStateWrapper.java
  44. +18 −15 api/src/main/java/javax/faces/component/_AttachedStateWrapper.java
  45. +14 −11 api/src/main/java/javax/faces/component/_ClassUtils.java
  46. +14 −11 api/src/main/java/javax/faces/component/_ComponentAttributesMap.java
  47. +16 −13 api/src/main/java/javax/faces/component/_ComponentChildrenList.java
  48. +18 −15 api/src/main/java/javax/faces/component/_ComponentFacetMap.java
  49. +38 −35 api/src/main/java/javax/faces/component/_ComponentUtils.java
  50. +16 −13 api/src/main/java/javax/faces/component/_EmptyIterator.java
  51. +16 −13 api/src/main/java/javax/faces/component/_FacetsAndChildrenIterator.java
  52. +49 −46 api/src/main/java/javax/faces/component/_LabeledFacesMessage.java
  53. +48 −45 api/src/main/java/javax/faces/component/_MessageUtils.java
  54. +14 −11 api/src/main/java/javax/faces/component/_MethodBindingToActionListener.java
  55. +14 −11 api/src/main/java/javax/faces/component/_MethodBindingToListener.java
  56. +14 −11 api/src/main/java/javax/faces/component/_MethodBindingToMethodExpression.java
  57. +14 −11 api/src/main/java/javax/faces/component/_MethodBindingToValueChangeListener.java
  58. +14 −11 api/src/main/java/javax/faces/component/_MethodExpressionToMethodBinding.java
  59. +14 −11 api/src/main/java/javax/faces/component/_PrimitiveArrayIterator.java
  60. +36 −16 api/src/main/java/javax/faces/component/_SelectItemsIterator.java
  61. +14 −11 api/src/main/java/javax/faces/component/_SelectItemsUtil.java
  62. +15 −12 api/src/main/java/javax/faces/component/_SharedRendererUtils.java
  63. +74 −0 api/src/main/java/javax/faces/component/_UIMessage.java
  64. +72 −0 api/src/main/java/javax/faces/component/_UIMessages.java
  65. +66 −0 api/src/main/java/javax/faces/component/_UIParameter.java
  66. +103 −0 api/src/main/java/javax/faces/component/_UISelectItem.java
  67. +62 −0 api/src/main/java/javax/faces/component/_UISelectItems.java
  68. +14 −11 api/src/main/java/javax/faces/component/_ValueBindingToValueExpression.java
  69. +14 −11 api/src/main/java/javax/faces/component/_ValueExpressionToValueBinding.java
  70. +72 −0 api/src/main/java/javax/faces/component/html/HtmlInputHidden.java
  71. +32 −0 api/src/main/java/javax/faces/component/html/_AccesskeyProperty.java
  72. +31 −0 api/src/main/java/javax/faces/component/html/_AltProperty.java
  73. +40 −0 api/src/main/java/javax/faces/component/html/_ChangeSelectProperties.java
  74. +39 −0 api/src/main/java/javax/faces/component/html/_DisabledClassEnabledClassProperties.java
  75. +39 −0 api/src/main/java/javax/faces/component/html/_DisabledReadonlyProperties.java
  76. +32 −0 api/src/main/java/javax/faces/component/html/_EscapeProperty.java
  77. +96 −0 api/src/main/java/javax/faces/component/html/_EventProperties.java
  78. +40 −0 api/src/main/java/javax/faces/component/html/_FocusBlurProperties.java
  79. +65 −0 api/src/main/java/javax/faces/component/html/_HtmlColumn.java
  80. +78 −0 api/src/main/java/javax/faces/component/html/_HtmlCommandButton.java
  81. +71 −0 api/src/main/java/javax/faces/component/html/_HtmlCommandLink.java
  82. +166 −0 api/src/main/java/javax/faces/component/html/_HtmlDataTable.java
  83. +89 −0 api/src/main/java/javax/faces/component/html/_HtmlForm.java
  84. +84 −0 api/src/main/java/javax/faces/component/html/_HtmlGraphicImage.java
  85. +98 −0 api/src/main/java/javax/faces/component/html/_HtmlInputSecret.java
  86. +89 −0 api/src/main/java/javax/faces/component/html/_HtmlInputText.java
  87. +76 −0 api/src/main/java/javax/faces/component/html/_HtmlInputTextarea.java
  88. +45 −0 api/src/main/java/javax/faces/component/html/_HtmlMessage.java
  89. +61 −0 api/src/main/java/javax/faces/component/html/_HtmlMessages.java
  90. +45 −0 api/src/main/java/javax/faces/component/html/_HtmlOutputFormat.java
  91. +53 −0 api/src/main/java/javax/faces/component/html/_HtmlOutputLabel.java
  92. +47 −0 api/src/main/java/javax/faces/component/html/_HtmlOutputLink.java
  93. +45 −0 api/src/main/java/javax/faces/component/html/_HtmlOutputText.java
  94. +172 −0 api/src/main/java/javax/faces/component/html/_HtmlPanelGrid.java
  95. +54 −0 api/src/main/java/javax/faces/component/html/_HtmlPanelGroup.java
  96. +66 −0 api/src/main/java/javax/faces/component/html/_HtmlSelectBooleanCheckbox.java
  97. +95 −0 api/src/main/java/javax/faces/component/html/_HtmlSelectManyCheckbox.java
  98. +90 −0 api/src/main/java/javax/faces/component/html/_HtmlSelectManyListbox.java
  99. +79 −0 api/src/main/java/javax/faces/component/html/_HtmlSelectManyMenu.java
  100. +87 −0 api/src/main/java/javax/faces/component/html/_HtmlSelectOneListbox.java
  101. +74 −0 api/src/main/java/javax/faces/component/html/_HtmlSelectOneMenu.java
  102. +88 −0 api/src/main/java/javax/faces/component/html/_HtmlSelectOneRadio.java
  103. +33 −0 api/src/main/java/javax/faces/component/html/_LabelProperty.java
  104. +92 −0 api/src/main/java/javax/faces/component/html/_LinkProperties.java
  105. +88 −0 api/src/main/java/javax/faces/component/html/_MessageProperties.java
  106. +39 −0 api/src/main/java/javax/faces/component/html/_StyleProperties.java
  107. +32 −0 api/src/main/java/javax/faces/component/html/_TabindexProperty.java
  108. +31 −0 api/src/main/java/javax/faces/component/html/_TitleProperty.java
  109. +47 −0 api/src/main/java/javax/faces/component/html/_UniversalProperties.java
  110. +24 −21 api/src/main/java/javax/faces/context/ExternalContext.java
  111. +16 −13 api/src/main/java/javax/faces/context/FacesContext.java
  112. +16 −13 api/src/main/java/javax/faces/context/FacesContextFactory.java
  113. +16 −13 api/src/main/java/javax/faces/context/ResponseStream.java
  114. +14 −11 api/src/main/java/javax/faces/context/ResponseWriter.java
  115. +14 −11 api/src/main/java/javax/faces/context/ResponseWriterWrapper.java
  116. +15 −12 api/src/main/java/javax/faces/convert/BigDecimalConverter.java
  117. +15 −12 api/src/main/java/javax/faces/convert/BigIntegerConverter.java
  118. +15 −12 api/src/main/java/javax/faces/convert/BooleanConverter.java
  119. +15 −12 api/src/main/java/javax/faces/convert/ByteConverter.java
  120. +22 −19 api/src/main/java/javax/faces/convert/CharacterConverter.java
  121. +14 −11 api/src/main/java/javax/faces/convert/Converter.java
  122. +14 −11 api/src/main/java/javax/faces/convert/ConverterException.java
  123. +26 −27 api/src/main/java/javax/faces/convert/DateTimeConverter.java
  124. +16 −13 api/src/main/java/javax/faces/convert/DoubleConverter.java
  125. +17 −14 api/src/main/java/javax/faces/convert/EnumConverter.java
  126. +15 −12 api/src/main/java/javax/faces/convert/FloatConverter.java
  127. +15 −12 api/src/main/java/javax/faces/convert/IntegerConverter.java
  128. +15 −12 api/src/main/java/javax/faces/convert/LongConverter.java
  129. +32 −28 api/src/main/java/javax/faces/convert/NumberConverter.java
  130. +15 −12 api/src/main/java/javax/faces/convert/ShortConverter.java
  131. +49 −46 api/src/main/java/javax/faces/convert/_LabeledFacesMessage.java
  132. +25 −22 api/src/main/java/javax/faces/convert/_MessageUtils.java
  133. +31 −28 api/src/main/java/javax/faces/el/EvaluationException.java
  134. +29 −26 api/src/main/java/javax/faces/el/MethodBinding.java
  135. +32 −29 api/src/main/java/javax/faces/el/MethodNotFoundException.java
  136. +33 −30 api/src/main/java/javax/faces/el/PropertyNotFoundException.java
  137. +16 −13 api/src/main/java/javax/faces/el/PropertyResolver.java
  138. +33 −30 api/src/main/java/javax/faces/el/ReferenceSyntaxException.java
  139. +14 −11 api/src/main/java/javax/faces/el/ValueBinding.java
  140. +23 −20 api/src/main/java/javax/faces/el/VariableResolver.java
  141. +33 −30 api/src/main/java/javax/faces/event/AbortProcessingException.java
  142. +31 −28 api/src/main/java/javax/faces/event/ActionEvent.java
  143. +17 −14 api/src/main/java/javax/faces/event/ActionListener.java
  144. +28 −25 api/src/main/java/javax/faces/event/FacesEvent.java
  145. +16 −13 api/src/main/java/javax/faces/event/FacesListener.java
  146. +14 −11 api/src/main/java/javax/faces/event/MethodExpressionActionListener.java
  147. +14 −11 api/src/main/java/javax/faces/event/MethodExpressionValueChangeListener.java
  148. +30 −27 api/src/main/java/javax/faces/event/PhaseEvent.java
  149. +37 −34 api/src/main/java/javax/faces/event/PhaseId.java
  150. +19 −16 api/src/main/java/javax/faces/event/PhaseListener.java
  151. +31 −28 api/src/main/java/javax/faces/event/ValueChangeEvent.java
  152. +17 −14 api/src/main/java/javax/faces/event/ValueChangeListener.java
  153. +16 −13 api/src/main/java/javax/faces/lifecycle/Lifecycle.java
  154. +16 −13 api/src/main/java/javax/faces/lifecycle/LifecycleFactory.java
  155. +56 −53 api/src/main/java/javax/faces/model/ArrayDataModel.java
  156. +16 −13 api/src/main/java/javax/faces/model/DataModel.java
  157. +29 −26 api/src/main/java/javax/faces/model/DataModelEvent.java
  158. +17 −14 api/src/main/java/javax/faces/model/DataModelListener.java
  159. +16 −13 api/src/main/java/javax/faces/model/ListDataModel.java
  160. +16 −13 api/src/main/java/javax/faces/model/ResultDataModel.java
  161. +16 −13 api/src/main/java/javax/faces/model/ResultSetDataModel.java
  162. +16 −13 api/src/main/java/javax/faces/model/ScalarDataModel.java
  163. +24 −17 api/src/main/java/javax/faces/model/SelectItem.java
  164. +36 −33 api/src/main/java/javax/faces/model/SelectItemGroup.java
  165. +16 −13 api/src/main/java/javax/faces/render/RenderKit.java
  166. +16 −13 api/src/main/java/javax/faces/render/RenderKitFactory.java
  167. +16 −13 api/src/main/java/javax/faces/render/Renderer.java
  168. +16 −13 api/src/main/java/javax/faces/render/ResponseStateManager.java
  169. +16 −13 api/src/main/java/javax/faces/validator/DoubleRangeValidator.java
  170. +17 −14 api/src/main/java/javax/faces/validator/LengthValidator.java
  171. +18 −15 api/src/main/java/javax/faces/validator/LongRangeValidator.java
  172. +14 −11 api/src/main/java/javax/faces/validator/MethodExpressionValidator.java
  173. +19 −16 api/src/main/java/javax/faces/validator/Validator.java
  174. +19 −16 api/src/main/java/javax/faces/validator/ValidatorException.java
  175. +49 −46 api/src/main/java/javax/faces/validator/_LabeledFacesMessage.java
  176. +27 −24 api/src/main/java/javax/faces/validator/_MessageUtils.java
  177. +16 −13 api/src/main/java/javax/faces/webapp/AttributeTag.java
  178. +14 −11 api/src/main/java/javax/faces/webapp/ConverterELTag.java
  179. +16 −13 api/src/main/java/javax/faces/webapp/ConverterTag.java
  180. +105 −24 api/src/main/java/javax/faces/webapp/FacesServlet.java
  181. +16 −13 api/src/main/java/javax/faces/webapp/FacetTag.java
  182. +16 −13 api/src/main/java/javax/faces/webapp/UIComponentBodyTag.java
  183. +27 −17 api/src/main/java/javax/faces/webapp/UIComponentClassicTagBase.java
  184. +14 −11 api/src/main/java/javax/faces/webapp/UIComponentELTag.java
  185. +14 −11 api/src/main/java/javax/faces/webapp/UIComponentTag.java
  186. +14 −11 api/src/main/java/javax/faces/webapp/UIComponentTagBase.java
  187. +14 −11 api/src/main/java/javax/faces/webapp/ValidatorELTag.java
  188. +16 −13 api/src/main/java/javax/faces/webapp/ValidatorTag.java
  189. +573 −428 api/src/main/java/javax/faces/webapp/_ErrorPageWriter.java
  190. +16 −13 api/src/main/java/javax/faces/webapp/_PageContextOutWriter.java
  191. +251 −0 api/src/main/resources/META-INF/componentClass12.vm
  192. 0  api/src/main/resources/META-INF/rsc/{facelet-dev-debug.xml → myfaces-dev-debug.xml}
  193. 0  api/src/main/resources/META-INF/rsc/{facelet-dev-error.xml → myfaces-dev-error.xml}
  194. +64 −61 api/src/test/java/javax/faces/FacesExceptionTest.java
  195. +14 −11 api/src/test/java/javax/faces/FactoryFinderTest.java
  196. +159 −156 api/src/test/java/javax/faces/application/FacesMessageTest.java
  197. +14 −11 api/src/test/java/javax/faces/application/StateManagerTest.java
  198. +14 −11 api/src/test/java/javax/faces/component/AbstractUIComponentPropertyTest.java
  199. +39 −39 api/src/test/java/javax/faces/component/UIComponentAttributesTest.java
  200. +14 −11 api/src/test/java/javax/faces/component/UIComponentBaseTest.java
  201. +14 −11 api/src/test/java/javax/faces/component/UIComponentMock.java
  202. +14 −11 api/src/test/java/javax/faces/component/UIComponentTest.java
  203. +0 −1  api/src/test/java/javax/faces/component/UIComponentValueExpressionTest.java
  204. +63 −63 api/src/test/java/javax/faces/component/UIInputTest.java
  205. +19 −16 api/src/test/java/javax/faces/component/UISelectManyTest.java
  206. +14 −11 api/src/test/java/javax/faces/component/_AttachedListStateWrapperTest.java
  207. +14 −11 api/src/test/java/javax/faces/component/_AttachedStateWrapperTest.java
  208. +14 −11 api/src/test/java/javax/faces/component/_MethodBindingToMethodExpressionTest.java
  209. +14 −11 api/src/test/java/javax/faces/convert/DateTimeConverterTest.java
  210. +144 −141 api/src/test/java/javax/faces/convert/EnumConverterTest.java
  211. +45 −42 api/src/test/java/javax/faces/convert/MessageUtilsTest.java
  212. +77 −74 api/src/test/java/javax/faces/convert/NumberConverterTest.java
  213. +27 −24 api/src/test/java/org/apache/myfaces/mock/api/Mock2ApplicationFactory.java
  214. +28 −25 api/src/test/java/org/apache/myfaces/mock/api/MockApplicationFactory.java
  215. +1 −1  assembly/pom.xml
  216. +3 −2 impl/pom.xml
  217. +19 −16 impl/src/main/java/org/apache/myfaces/application/ActionListenerImpl.java
  218. +14 −11 impl/src/main/java/org/apache/myfaces/application/ApplicationFactoryImpl.java
  219. +16 −13 impl/src/main/java/org/apache/myfaces/application/ApplicationImpl.java
  220. +3 −3 impl/src/main/java/org/apache/myfaces/application/DefaultViewHandlerSupport.java
  221. +16 −13 impl/src/main/java/org/apache/myfaces/application/MyfacesStateManager.java
  222. +14 −11 impl/src/main/java/org/apache/myfaces/application/NavigationHandlerImpl.java
  223. +16 −13 impl/src/main/java/org/apache/myfaces/application/TreeStructureManager.java
  224. +54 −51 impl/src/main/java/org/apache/myfaces/application/jsp/JspStateManagerImpl.java
  225. +120 −111 impl/src/main/java/org/apache/myfaces/application/jsp/JspViewHandlerImpl.java
  226. +18 −0 impl/src/main/java/org/apache/myfaces/application/jsp/ViewResponseWrapper.java
  227. +14 −11 impl/src/main/java/org/apache/myfaces/config/FacesConfigDispenser.java
  228. +14 −12 impl/src/main/java/org/apache/myfaces/config/FacesConfigUnmarshaller.java
  229. +14 −13 impl/src/main/java/org/apache/myfaces/config/FacesConfigValidator.java
  230. +10 −20 impl/src/main/java/org/apache/myfaces/config/FacesConfigurator.java
  231. +14 −11 impl/src/main/java/org/apache/myfaces/config/LastVariableResolverInChain.java
  232. +14 −11 impl/src/main/java/org/apache/myfaces/config/ManagedBeanBuilder.java
  233. +14 −11 impl/src/main/java/org/apache/myfaces/config/RuntimeConfig.java
  234. +14 −12 impl/src/main/java/org/apache/myfaces/config/annotation/AllAnnotationLifecycleProvider.java
  235. +14 −13 impl/src/main/java/org/apache/myfaces/config/annotation/DefaultLifecycleProviderFactory.java
  236. +14 −13 impl/src/main/java/org/apache/myfaces/config/annotation/DiscoverableLifecycleProvider.java
  237. +1 −3 impl/src/main/java/org/apache/myfaces/config/annotation/LifecycleProvider.java
  238. +14 −12 impl/src/main/java/org/apache/myfaces/config/annotation/LifecycleProviderFactory.java
  239. +14 −12 impl/src/main/java/org/apache/myfaces/config/annotation/NoAnnotationLifecyleProvider.java
  240. +14 −12 impl/src/main/java/org/apache/myfaces/config/annotation/NoInjectionAnnotationLifecycleProvider.java
  241. +14 −12 impl/src/main/java/org/apache/myfaces/config/annotation/ResourceAnnotationLifecycleProvider.java
  242. +14 −12 impl/src/main/java/org/apache/myfaces/config/annotation/TomcatAnnotationLifecycleProvider.java
  243. +14 −11 impl/src/main/java/org/apache/myfaces/config/element/ListEntries.java
  244. +14 −11 impl/src/main/java/org/apache/myfaces/config/element/ListEntry.java
  245. +14 −11 impl/src/main/java/org/apache/myfaces/config/element/ManagedBean.java
  246. +14 −11 impl/src/main/java/org/apache/myfaces/config/element/ManagedProperty.java
  247. +14 −11 impl/src/main/java/org/apache/myfaces/config/element/MapEntries.java
  248. +14 −11 impl/src/main/java/org/apache/myfaces/config/element/MapEntry.java
  249. +14 −11 impl/src/main/java/org/apache/myfaces/config/element/NavigationCase.java
  250. +14 −11 impl/src/main/java/org/apache/myfaces/config/element/NavigationRule.java
  251. +14 −11 impl/src/main/java/org/apache/myfaces/config/element/Renderer.java
  252. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/FacesConfigEntityResolver.java
  253. +14 −11 impl/src/main/java/org/apache/myfaces/config/impl/digester/DigesterFacesConfigDispenserImpl.java
  254. +14 −11 impl/src/main/java/org/apache/myfaces/config/impl/digester/DigesterFacesConfigUnmarshallerImpl.java
  255. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/Application.java
  256. +14 −11 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/Attribute.java
  257. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/Component.java
  258. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/Converter.java
  259. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/FacesConfig.java
  260. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/Factory.java
  261. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/ListEntries.java
  262. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/LocaleConfig.java
  263. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/ManagedBean.java
  264. +14 −11 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/ManagedProperty.java
  265. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/MapEntries.java
  266. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/NavigationCase.java
  267. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/NavigationRule.java
  268. +14 −11 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/Property.java
  269. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/RenderKit.java
  270. +16 −13 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/Renderer.java
  271. +14 −11 impl/src/main/java/org/apache/myfaces/config/impl/digester/elements/ResourceBundle.java
  272. +16 −13 impl/src/main/java/org/apache/myfaces/context/FacesContextFactoryImpl.java
  273. +16 −13 impl/src/main/java/org/apache/myfaces/context/FacesContextWrapper.java
  274. +14 −11 impl/src/main/java/org/apache/myfaces/context/ReleaseableExternalContext.java
  275. +14 −11 impl/src/main/java/org/apache/myfaces/context/portlet/ApplicationMap.java
  276. +14 −13 impl/src/main/java/org/apache/myfaces/context/portlet/InitParameterMap.java
  277. +14 −11 impl/src/main/java/org/apache/myfaces/context/portlet/PortletExternalContextImpl.java
  278. +14 −11 impl/src/main/java/org/apache/myfaces/context/portlet/RequestHeaderMap.java
  279. +14 −11 impl/src/main/java/org/apache/myfaces/context/portlet/RequestHeaderValuesMap.java
  280. +14 −11 impl/src/main/java/org/apache/myfaces/context/portlet/RequestMap.java
  281. +14 −11 impl/src/main/java/org/apache/myfaces/context/portlet/RequestParameterMap.java
  282. +14 −11 impl/src/main/java/org/apache/myfaces/context/portlet/RequestParameterValuesMap.java
  283. +14 −11 impl/src/main/java/org/apache/myfaces/context/portlet/SessionMap.java
  284. +14 −11 impl/src/main/java/org/apache/myfaces/context/servlet/ApplicationMap.java
  285. +14 −11 impl/src/main/java/org/apache/myfaces/context/servlet/CookieMap.java
  286. +14 −11 impl/src/main/java/org/apache/myfaces/context/servlet/FacesContextImpl.java
  287. +16 −13 impl/src/main/java/org/apache/myfaces/context/servlet/InitParameterMap.java
  288. +16 −13 impl/src/main/java/org/apache/myfaces/context/servlet/RequestHeaderMap.java
  289. +16 −13 impl/src/main/java/org/apache/myfaces/context/servlet/RequestHeaderValuesMap.java
  290. +16 −13 impl/src/main/java/org/apache/myfaces/context/servlet/RequestMap.java
  291. +16 −13 impl/src/main/java/org/apache/myfaces/context/servlet/RequestParameterMap.java
  292. +16 −13 impl/src/main/java/org/apache/myfaces/context/servlet/RequestParameterValuesMap.java
  293. +14 −11 impl/src/main/java/org/apache/myfaces/context/servlet/ServletExternalContextImpl.java
  294. +32 −14 impl/src/main/java/org/apache/myfaces/context/servlet/ServletFacesContextImpl.java
  295. +14 −11 impl/src/main/java/org/apache/myfaces/context/servlet/SessionMap.java
  296. +60 −57 impl/src/main/java/org/apache/myfaces/convert/ConverterUtils.java
  297. +14 −12 impl/src/main/java/org/apache/myfaces/el/NullPropertyResolver.java
  298. +14 −12 impl/src/main/java/org/apache/myfaces/el/NullVariableResolver.java
  299. +14 −11 impl/src/main/java/org/apache/myfaces/el/PropertyResolverImpl.java
  300. +14 −11 impl/src/main/java/org/apache/myfaces/el/VariableResolverImpl.java
Sorry, we could not display the entire diff because too many files (424) changed.
View
53 api/pom.xml
@@ -21,7 +21,7 @@
<plugins>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
- <version>2.1</version>
+ <version>2.2</version>
<executions>
<execution>
<goals>
@@ -42,6 +42,7 @@
</execution>
</executions>
</plugin>
+ <!--
<plugin>
<groupId>org.apache.myfaces.buildtools</groupId>
<artifactId>myfaces-faces-plugin</artifactId>
@@ -69,6 +70,28 @@
</dependency>
</dependencies>
</plugin>
+ -->
+ <plugin>
+ <groupId>org.apache.myfaces.buildtools</groupId>
+ <artifactId>myfaces-builder-plugin</artifactId>
+ <version>1.0.1</version>
+ <executions>
+ <execution>
+ <goals>
+ <goal>build-metadata</goal>
+ </goals>
+ </execution>
+ <execution>
+ <id>makecomp</id>
+ <configuration>
+ <jsfVersion>12</jsfVersion>
+ </configuration>
+ <goals>
+ <goal>make-components</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
</build>
<profiles>
@@ -83,7 +106,7 @@
<plugins>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
- <version>2.3</version>
+ <version>2.4</version>
<executions>
<execution>
<id>attach-javadoc</id>
@@ -172,7 +195,12 @@
<artifactId>commons-logging</artifactId>
<version>1.1.1</version>
</dependency>
-
+ <dependency>
+ <groupId>org.apache.myfaces.buildtools</groupId>
+ <artifactId>myfaces-builder-annotations</artifactId>
+ <version>1.0.1</version>
+ <scope>provided</scope>
+ </dependency>
<dependency>
<groupId>commons-beanutils</groupId>
<artifactId>commons-beanutils</artifactId>
@@ -221,12 +249,11 @@
<plugins>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
- <version>2.3</version>
+ <version>2.4</version>
</plugin>
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>changelog-maven-plugin</artifactId>
- <version>2.0-beta-1</version>
+ <artifactId>maven-changelog-plugin</artifactId>
+ <version>2.1</version>
<reportSets>
<reportSet>
<id>dual-report</id>
@@ -243,14 +270,12 @@
</reportSets>
</plugin>
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>jxr-maven-plugin</artifactId>
- <version>2.0-beta-1</version>
+ <artifactId>maven-jxr-plugin</artifactId>
+ <version>2.1</version>
</plugin>
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>surefire-report-maven-plugin</artifactId>
- <version>2.0-beta-1</version>
+ <artifactId>maven-surefire-report-plugin</artifactId>
+ <version>2.4.3</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
@@ -265,7 +290,7 @@
<!-- override PMD settings to set targetJdk -->
<plugin>
<artifactId>maven-pmd-plugin</artifactId>
- <version>2.2</version>
+ <version>2.4</version>
<configuration>
<rulesets>
<ruleset>/rulesets/basic.xml</ruleset>
View
114 api/src/main/java-templates/javax/faces/component/UICommandTemplate.java
@@ -1,114 +0,0 @@
-/*
- * Copyright 2006 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package javax.faces.component;
-
-import javax.faces.context.FacesContext;
-import javax.faces.event.AbortProcessingException;
-import javax.faces.event.ActionEvent;
-import javax.faces.event.ActionListener;
-import javax.faces.event.FacesEvent;
-import javax.faces.event.PhaseId;
-import javax.faces.el.MethodBinding;
-import javax.el.MethodExpression;
-
-/**
- * TODO: comment this!
- *
- * @author Bruno Aranda (latest modification by $Author$)
- * @version $Revision$ $Date$
- */
-public abstract class UICommandTemplate extends UIComponentBase
-{
- /**/ // lines starting with /**/ are magically ignored from the generated class
-
- /**/public abstract boolean isImmediate();
- /**/public abstract ActionListener[] getActionListeners();
- /**/public abstract MethodExpression getActionExpression();
- /**/public abstract void setActionExpression(MethodExpression methodExpression);
-
- /**
- * @deprecated Use setActionExpression instead.
- */
- public void setAction(MethodBinding action)
- {
- if(action != null)
- {
- setActionExpression(new _MethodBindingToMethodExpression(action));
- }
- else
- {
- setActionExpression(null);
- }
- }
-
- /**
- * @deprecated Use getActionExpression() instead.
- */
- public MethodBinding getAction()
- {
- MethodExpression actionExpression = getActionExpression();
- if (actionExpression instanceof _MethodBindingToMethodExpression) {
- return ((_MethodBindingToMethodExpression)actionExpression).getMethodBinding();
- }
- if(actionExpression != null)
- {
- return new _MethodExpressionToMethodBinding(actionExpression);
- }
- return null;
- }
-
- @Override
- public void broadcast(FacesEvent event)
- throws AbortProcessingException
- {
- super.broadcast(event);
-
- if (event instanceof ActionEvent)
- {
- FacesContext context = getFacesContext();
-
- MethodBinding mb = getActionListener();
- if(mb != null)
- {
- mb.invoke(context, new Object[] { event });
- }
-
- ActionListener defaultActionListener
- = context.getApplication().getActionListener();
- if (defaultActionListener != null)
- {
- defaultActionListener.processAction((ActionEvent)event);
- }
- }
- }
-
- @Override
- public void queueEvent(FacesEvent event)
- {
- if (event != null && event instanceof ActionEvent)
- {
- if (isImmediate())
- {
- event.setPhaseId(PhaseId.APPLY_REQUEST_VALUES);
- }
- else
- {
- event.setPhaseId(PhaseId.INVOKE_APPLICATION);
- }
- }
- super.queueEvent(event);
- }
-}
View
72 api/src/main/java-templates/javax/faces/component/UIGraphicTemplate.java
@@ -1,72 +0,0 @@
-/*
-* Copyright 2004-2006 The Apache Software Foundation.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.faces.component;
-
-import javax.faces.el.ValueBinding;
-import javax.el.ValueExpression;
-
-/**
- * @author Andreas Berger (latest modification by $Author$)
- * @version $Revision$ $Date$
- * @since 1.2
- */
-public class UIGraphicTemplate extends UIComponentBase
-{
- private static final String URL_PROPERTY = "url";
- private static final String VALUE_PROPERTY = "value";
-
- /**/ public String getFamily() { return null;}
-
- /**///setUrl
- public void setUrl(String url)
- {
- setValue(url);
- }
-
- /**///getUrl
- public String getUrl()
- {
- return (String)getValue();
- }
-
- @Override
- public ValueExpression getValueExpression(String name)
- {
- if (URL_PROPERTY.equals(name))
- {
- return super.getValueExpression(VALUE_PROPERTY);
- }
- else
- {
- return super.getValueExpression(name);
- }
- }
-
- @Override
- public void setValueExpression(String name,
- ValueExpression binding)
- {
- if (URL_PROPERTY.equals(name))
- {
- super.setValueExpression(VALUE_PROPERTY, binding);
- }
- else
- {
- super.setValueExpression(name, binding);
- }
- }
-}
-
View
401 api/src/main/java-templates/javax/faces/component/UIInputTemplate.java
@@ -1,401 +0,0 @@
-/*
-* Copyright 2004-2006 The Apache Software Foundation.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.faces.component;
-
-import javax.el.ValueExpression;
-import javax.faces.FacesException;
-import javax.faces.application.FacesMessage;
-import javax.faces.context.FacesContext;
-import javax.faces.convert.Converter;
-import javax.faces.convert.ConverterException;
-import javax.faces.el.EvaluationException;
-import javax.faces.el.MethodBinding;
-import javax.faces.event.AbortProcessingException;
-import javax.faces.event.FacesEvent;
-import javax.faces.event.ValueChangeEvent;
-import javax.faces.event.ValueChangeListener;
-import javax.faces.render.Renderer;
-import javax.faces.validator.Validator;
-import java.util.ArrayList;
-import java.util.List;
-
-
-/**
- * @author Andreas Berger (latest modification by $Author$)
- * @version $Revision$ $Date$
- * @since 1.2
- */
-public class UIInputTemplate extends UIOutput implements EditableValueHolder
-{
- public static final String CONVERSION_MESSAGE_ID = "javax.faces.component.UIInput.CONVERSION";
- public static final String REQUIRED_MESSAGE_ID = "javax.faces.component.UIInput.REQUIRED";
- public static final String UPDATE_MESSAGE_ID = "javax.faces.component.UIInput.UPDATE";
- private static final String ERROR_HANDLING_EXCEPTION_LIST = "org.apache.myfaces.errorHandling.exceptionList";
-
- /**
- * Store the specified object as the "local value" of this component.
- * The value-binding named "value" (if any) is ignored; the object is
- * only stored locally on this component. During the "update model"
- * phase, if there is a value-binding named "value" then this local
- * value will be stored via that value-binding and the "local value"
- * reset to null.
- */
- /**///setValue
- public void setValue(Object value)
- {
- setLocalValueSet(true);
- super.setValue(value);
- }
-
- /**
- * Set the "submitted value" of this component from the relevant data
- * in the current servet request object.
- * <p>
- * If this component is not rendered, then do nothing; no output would
- * have been sent to the client so no input is expected.
- * <p>
- * Invoke the inherited functionality, which typically invokes the
- * renderer associated with this component to extract and set this
- * component's "submitted value".
- * <p>
- * If this component is marked "immediate", then immediately apply
- * validation to the submitted value found. On error, call context
- * method "renderResponse" which will force processing to leap to
- * the "render response" phase as soon as the "decode" step has
- * completed for all other components.
- */
- public void processDecodes(FacesContext context)
- {
- if (context == null) throw new NullPointerException("context");
- if (!isRendered()) return;
- super.processDecodes(context);
- if (isImmediate())
- {
- try
- {
- validate(context);
- }
- catch (RuntimeException e)
- {
- context.renderResponse();
- throw e;
- }
- if (!isValid())
- {
- context.renderResponse();
- }
- }
- }
-
- public void processValidators(FacesContext context)
- {
- if (context == null) throw new NullPointerException("context");
- if (!isRendered()) return;
-
- super.processValidators(context);
-
- if (!isImmediate())
- {
- try
- {
- validate(context);
- }
- catch (RuntimeException e)
- {
- context.renderResponse();
- throw e;
- }
- if (!isValid())
- {
- context.renderResponse();
- }
- }
- }
-
- public void processUpdates(FacesContext context)
- {
- if (context == null) throw new NullPointerException("context");
- if (!isRendered()) return;
-
- super.processUpdates(context);
-
- try
- {
- updateModel(context);
- }
- catch (RuntimeException e)
- {
- context.renderResponse();
- throw e;
- }
- if (!isValid())
- {
- context.renderResponse();
- }
- }
-
- public void decode(FacesContext context)
- {
- //We (re)set to valid, so that component automatically gets (re)validated
- setValid(true);
- super.decode(context);
- }
-
- public void broadcast(FacesEvent event)
- throws AbortProcessingException
- {
- if (!(event instanceof ValueChangeEvent))
- {
- throw new IllegalArgumentException("FacesEvent of class " + event.getClass().getName() + " not supported by UIInput");
- }
-
- // invoke standard listeners attached to this component first
- super.broadcast(event);
-
- // invoke the single listener defined directly on the component
- MethodBinding valueChangeListenerBinding = getValueChangeListener();
- if (valueChangeListenerBinding != null)
- {
- try
- {
- valueChangeListenerBinding.invoke(getFacesContext(),
- new Object[]{event});
- }
- catch (EvaluationException e)
- {
- Throwable cause = e.getCause();
- if (cause != null && cause instanceof AbortProcessingException)
- {
- throw (AbortProcessingException)cause;
- }
- else
- {
- throw e;
- }
- }
- }
- }
-
- public void updateModel(FacesContext context)
- {
- if (!isValid()) return;
- if (!isLocalValueSet()) return;
- ValueExpression expression = getValueExpression("value");
- if (expression == null) return;
- try
- {
- expression.setValue(context.getELContext(), getLocalValue());
- setValue(null);
- setLocalValueSet(false);
- }
- catch (Exception e)
- {
- context.getExternalContext().log(e.getMessage(), e);
- _MessageUtils.addErrorMessage(context, this, UPDATE_MESSAGE_ID, new Object[]{_MessageUtils.getLabel(context,this)});
- setValid(false);
-
- /* we are not allowed to throw exceptions here - we still need the full stack-trace later on
- * to process it later in our error-handler
- */
- queueExceptionInRequest(context, expression, e);
- }
- }
-
- /**
- * For development and production, we want to offer a single point
- * to which error-handlers can attach. So we queue up all ocurring
- * exceptions and later pass them to the configured error-handler.
- *
- * @param context
- * @param expression
- * @param e
- */
- private void queueExceptionInRequest(FacesContext context, ValueExpression expression, Exception e) {
- List li = (List) context.getExternalContext().getRequestMap().get(ERROR_HANDLING_EXCEPTION_LIST);
- if(null==li) {
- li = new ArrayList();
- context.getExternalContext().getRequestMap().put(ERROR_HANDLING_EXCEPTION_LIST, li);
-
- li.add(new FacesException("Exception while setting value for expression : "+
- expression.getExpressionString()+" of component with path : "
- + _ComponentUtils.getPathToComponent(this),e));
- }
- }
-
- protected void validateValue(FacesContext context,Object convertedValue)
- {
- boolean empty = convertedValue == null ||
- (convertedValue instanceof String
- && ((String)convertedValue).length() == 0);
-
- if (isRequired() && empty)
- {
- if(getRequiredMessage() != null) {
- String requiredMessage = getRequiredMessage();
- context.addMessage(this.getClientId(context),new FacesMessage(FacesMessage.SEVERITY_ERROR,requiredMessage,requiredMessage));
- } else {
- _MessageUtils.addErrorMessage(context, this, REQUIRED_MESSAGE_ID,new Object[]{_MessageUtils.getLabel(context,this)});
- }
- setValid(false);
- return;
- }
-
- if (!empty)
- {
- _ComponentUtils.callValidators(context, this, convertedValue);
- }
-
- }
-
- /**
- * Determine whether the new value is valid, and queue a ValueChangeEvent
- * if necessary.
- * <p>
- * The "submitted value" is converted to the necessary type; conversion
- * failure is reported as an error and validation processing terminates
- * for this component. See documentation for method getConvertedValue
- * for details on the conversion process.
- * <p>
- * Any validators attached to this component are then run, passing
- * the converted value.
- * <p>
- * The old value of this component is then fetched (possibly involving
- * the evaluation of a value-binding expression, ie invoking a method
- * on a user object). The old value is compared to the new validated
- * value, and if they are different then a ValueChangeEvent is queued
- * for later processing.
- * <p>
- * On successful completion of this method:
- * <ul>
- * <li> isValid() is true
- * <li> isLocalValueSet() is true
- * <li> submittedValue is reset to null
- * <li> a ValueChangeEvent is queued if the new value != old value
- * </ul>
- */
- public void validate(FacesContext context)
- {
- if (context == null) throw new NullPointerException("context");
-
- try {
-
- Object submittedValue = getSubmittedValue();
- if (submittedValue == null) return;
-
- Object convertedValue = getConvertedValue(context, submittedValue);
-
- if (!isValid()) return;
-
- validateValue(context, convertedValue);
-
- if (!isValid()) return;
-
- Object previousValue = getValue();
- setValue(convertedValue);
- setSubmittedValue(null);
- if (compareValues(previousValue, convertedValue))
- {
- queueEvent(new ValueChangeEvent(this, previousValue, convertedValue));
- }
- }
- catch (Exception ex)
- {
- throw new FacesException("Exception while validating component with path : "+_ComponentUtils.getPathToComponent(this),ex);
- }
-
- }
-
- /**
- * Convert the provided object to the desired value.
- * <p>
- * If there is a renderer for this component, then call the renderer's
- * getConvertedValue method. While this can of course be implemented in
- * any way the renderer desires, it typically performs exactly the same
- * processing that this method would have done anyway (ie that described
- * below for the no-renderer case).
- * <p>
- * Otherwise:
- * <ul>
- * <li>If the submittedValue is not a String then just return the
- * submittedValue unconverted.
- * <li>If there is no "value" value-binding then just return the
- * submittedValue unconverted.
- * <li>Use introspection to determine the type of the target
- * property specified by the value-binding, and then use
- * Application.createConverter to find a converter that can
- * map from String to the required type. Apply the converter
- * to the submittedValue and return the result.
- * </ul>
- */
- protected Object getConvertedValue(FacesContext context, Object submittedValue)
- {
- try
- {
- Renderer renderer = getRenderer(context);
- if (renderer != null)
- {
- return renderer.getConvertedValue(context, this, submittedValue);
- }
- else if (submittedValue instanceof String)
- {
- Converter converter = _SharedRendererUtils.findUIOutputConverter(context, this);
- if (converter != null)
- {
- return converter.getAsObject(context, this, (String)submittedValue);
- }
- }
- }
- catch (ConverterException e)
- {
- String converterMessage = getConverterMessage();
- if(converterMessage != null) {
- context.addMessage(getClientId(context),new FacesMessage(FacesMessage.SEVERITY_ERROR,converterMessage,converterMessage));
- } else {
- FacesMessage facesMessage = e.getFacesMessage();
- if (facesMessage != null)
- {
- context.addMessage(getClientId(context), facesMessage);
- }
- else
- {
- _MessageUtils.addErrorMessage(context, this, CONVERSION_MESSAGE_ID,new Object[]{_MessageUtils.getLabel(context,this)});
- }
- }
- setValid(false);
- }
- return submittedValue;
- }
-
-
-
- protected boolean compareValues(Object previous,
- Object value)
- {
- return previous==null?(value!=null):(!previous.equals(value));
- }
-
-
- /**
- * @since 1.2
- */
- public void resetValue()
- {
- setSubmittedValue(null);
- setValue(null);
- setLocalValueSet(false);
- setValid(true);
- }
-}
View
27 api/src/main/java-templates/javax/faces/component/UINamingContainerTemplate.java
@@ -1,27 +0,0 @@
-/*
-* Copyright 2004-2006 The Apache Software Foundation.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.faces.component;
-
-/**
- * @author Andreas Berger (latest modification by $Author$)
- * @version $Revision$ $Date$
- * @since 1.2
- */
-public class UINamingContainerTemplate
- extends UIComponentBase
- implements NamingContainer
-{
-}
View
30 api/src/main/java-templates/javax/faces/component/UIOutputTemplate.java
@@ -1,30 +0,0 @@
-/*
-* Copyright 2004-2006 The Apache Software Foundation.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.faces.component;
-
-/**
- * @author Andreas Berger (latest modification by $Author$)
- * @version $Revision$ $Date$
- * @since 1.2
- */
-public class UIOutputTemplate extends UIComponentBase
- implements ValueHolder
-{
- public Object getLocalValue()
- {
- return _value;
- }
-}
View
102 api/src/main/java-templates/javax/faces/component/UISelectBooleanTemplate.java
@@ -1,102 +0,0 @@
-/*
-* Copyright 2004-2006 The Apache Software Foundation.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.faces.component;
-
-import javax.faces.el.ValueBinding;
-import javax.el.ValueExpression;
-
-/**
- * @author Andreas Berger (latest modification by $Author$)
- * @version $Revision$ $Date$
- * @since 1.2
- */
-public class UISelectBooleanTemplate extends UIInput
-{
-
- public void setSelected(boolean selected)
- {
- setValue(Boolean.valueOf(selected));
- }
-
- public boolean isSelected()
- {
- Boolean value = (Boolean)getSubmittedValue();
- if( value == null )
- value = (Boolean)getValue();
-
- return value != null ? value.booleanValue() : false;
- }
-
- /**
- * @deprecated Use getValueExpression instead
- */
- public ValueBinding getValueBinding(String name)
- {
- if (name == null) throw new NullPointerException("name");
- if (name.equals("selected"))
- {
- return super.getValueBinding("value");
- }
- else
- {
- return super.getValueBinding(name);
- }
- }
-
- /**
- * @deprecated Use setValueExpression instead
- */
- public void setValueBinding(String name,
- ValueBinding binding)
- {
- if (name == null) throw new NullPointerException("name");
- if (name.equals("selected"))
- {
- super.setValueBinding("value", binding);
- }
- else
- {
- super.setValueBinding(name, binding);
- }
- }
-
- public ValueExpression getValueExpression(String name)
- {
- if (name == null) throw new NullPointerException("name");
- if (name.equals("selected"))
- {
- return super.getValueExpression("value");
- }
- else
- {
- return super.getValueExpression(name);
- }
- }
-
- public void setValueExpression(String name,
- ValueExpression binding)
- {
- if (name == null) throw new NullPointerException("name");
- if (name.equals("selected"))
- {
- super.setValueExpression("value", binding);
- }
- else
- {
- super.setValueExpression(name, binding);
- }
- }
-}
View
60 api/src/main/java-templates/javax/faces/component/UISelectOneTemplate.java
@@ -1,60 +0,0 @@
-/*
-* Copyright 2004-2006 The Apache Software Foundation.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.faces.component;
-
-import javax.faces.context.FacesContext;
-
-/**
- * @author Andreas Berger (latest modification by $Author$)
- * @version $Revision$ $Date$
- * @since 1.2
- */
-public class UISelectOneTemplate extends UIInput
-{
- public static final String INVALID_MESSAGE_ID = "javax.faces.component.UISelectOne.INVALID";
-
- /**
- * Verify that the result of converting the newly submitted value is
- * <i>equal</i> to the value property of one of the child SelectItem
- * objects. If this is not true, a validation error is reported.
- *
- * @see javax.faces.component.UIInput#validateValue(javax.faces.context.FacesContext,java.lang.Object)
- */
- protected void validateValue(FacesContext context, Object value)
- {
- super.validateValue(context, value);
-
- if (!isValid() || value == null)
- {
- return;
- }
-
- _SelectItemsUtil._ValueConverter converter = new _SelectItemsUtil._ValueConverter()
- {
- public Object getConvertedValue(FacesContext context, String value)
- {
- return UISelectOne.this.getConvertedValue(context, value);
- }
- };
-
- // selected value must match to one of the available options
- if (!_SelectItemsUtil.matchValue(context, value, new _SelectItemsIterator(this), converter))
- {
- _MessageUtils.addErrorMessage(context, this, INVALID_MESSAGE_ID, new Object[]{_MessageUtils.getLabel(context,this)});
- setValid(false);
- }
- }
-}
View
365 api/src/main/java-templates/javax/faces/component/UIViewRootTemplate.java
@@ -1,365 +0,0 @@
-/*
-* Copyright 2004-2006 The Apache Software Foundation.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.faces.component;
-
-import javax.el.MethodExpression;
-import javax.el.ValueExpression;
-import javax.faces.FactoryFinder;
-import javax.faces.context.ExternalContext;
-import javax.faces.context.FacesContext;
-import javax.faces.event.*;
-import javax.faces.lifecycle.Lifecycle;
-import javax.faces.lifecycle.LifecycleFactory;
-import javax.faces.webapp.FacesServlet;
-import java.util.*;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-/**
- * @author Andreas Berger (latest modification by $Author$)
- * @version $Revision$ $Date$
- * @since 1.2
- */
-public class UIViewRootTemplate
- extends UIComponentBase
-{
- private static final int ANY_PHASE_ORDINAL = PhaseId.ANY_PHASE.getOrdinal();
- public static final String UNIQUE_ID_PREFIX = "j_id";
-
- private final Logger logger = Logger.getLogger(UIViewRootTemplate.class.getName());
-
- // todo: is it right to save the state of _events and _phaseListeners?
- /**/ // removes the generated methods so only state saving stays
- /**/// getEvents
- /**/// setEvents
- /**/// getUniqueIdCounter
- /**/// setUniqueIdCounter
- /**/// getPhaseListeners
- /**/// getLocale
- /**/ private List<FacesEvent> _events = null;
- /**/ private long _uniqueIdCounter = 0;
- /**/ private Locale _locale;
- /**/ private Collection<PhaseListener> _phaseListeners;
- /**/ private MethodExpression getBeforePhaseListener() { return null; }
- /**/ private MethodExpression getAfterPhaseListener() { return null; }
- /**/ public String getFamily() { return null; }
-
- private transient Lifecycle _lifecycle = null;
-
- public void queueEvent(FacesEvent event)
- {
- checkNull(event, "event");
- if (_events == null)
- {
- _events = new ArrayList<FacesEvent>();
- }
- _events.add(event);
- }
-
-
- public void processDecodes(final FacesContext context)
- {
- checkNull(context, "context");
- process(context, PhaseId.APPLY_REQUEST_VALUES, new Processor()
- {
- public void process()
- {
- UIViewRootTemplate.super.processDecodes(context);
- }
- }, true);
- }
-
- public void processValidators(final FacesContext context)
- {
- checkNull(context, "context");
- process(context, PhaseId.PROCESS_VALIDATIONS, new Processor()
- {
- public void process()
- {
- UIViewRootTemplate.super.processValidators(context);
- }
- }, true);
- }
-
- public void processUpdates(final FacesContext context)
- {
- checkNull(context, "context");
- process(context, PhaseId.UPDATE_MODEL_VALUES, new Processor()
- {
- public void process()
- {
- UIViewRootTemplate.super.processUpdates(context);
- }
- }, true);
- }
-
- public void processApplication(final FacesContext context)
- {
- checkNull(context, "context");
- process(context, PhaseId.INVOKE_APPLICATION, null, true);
- }
-
- public void encodeBegin(FacesContext context)
- throws java.io.IOException
- {
- checkNull(context, "context");
-
- boolean skipPhase = false;
-
- try
- {
- skipPhase = notifyListeners(context, PhaseId.RENDER_RESPONSE, getBeforePhaseListener(), true);
- }
- catch (Exception e)
- {
- // following the spec we have to swallow the exception
- logger.log(Level.SEVERE, "Exception while processing phase listener: " + e.getMessage(), e);
- }
-
- if(!skipPhase)
- {
- super.encodeBegin(context);
- }
- }
-
- public void encodeEnd(FacesContext context) throws java.io.IOException
- {
- checkNull(context, "context");
- super.encodeEnd(context);
- try
- {
- notifyListeners(context, PhaseId.RENDER_RESPONSE, getAfterPhaseListener(), false);
- }
- catch (Exception e)
- {
- // following the spec we have to swallow the exception
- logger.log(Level.SEVERE, "Exception while processing phase listener: " + e.getMessage(), e);
- }
- }
-
- /*
- * Provides a unique id for this component instance.
- */
- public String createUniqueId()
- {
- ExternalContext extCtx = FacesContext.getCurrentInstance().getExternalContext();
- StringBuilder bld = __getSharedStringBuilder();
- return extCtx.encodeNamespace(bld.append(UNIQUE_ID_PREFIX).append(_uniqueIdCounter++).toString());
- }
-
- /**
- * Gets The locale for this ViewRoot.
- *
- * @return the new locale value
- */
- public Locale getLocale()
- {
- if (_locale != null)
- {
- return _locale;
- }
- ValueExpression expression = getValueExpression("locale");
- if (expression != null)
- {
- return (Locale) expression.getValue(getFacesContext().getELContext());
- }
- else
- {
- Object locale = getFacesContext().getApplication().getViewHandler().calculateLocale(getFacesContext());
-
- if (locale instanceof Locale)
- {
- return (Locale) locale;
- }
- else if (locale instanceof String)
- {
- return stringToLocale((String)locale);
- }
- }
-
- return getFacesContext().getApplication().getViewHandler().calculateLocale(getFacesContext());
- }
-
- private boolean process(FacesContext context, PhaseId phaseId, Processor processor, boolean broadcast)
- {
- if (!notifyListeners(context, phaseId, getBeforePhaseListener(), true))
- {
- if (processor != null)
- processor.process();
-
- if (broadcast)
- {
- _broadcastForPhase(phaseId);
- if (context.getRenderResponse() || context.getResponseComplete())
- {
- clearEvents();
- }
- }
- }
- return notifyListeners(context, phaseId, getAfterPhaseListener(), false);
- }
-
- private boolean notifyListeners(FacesContext context, PhaseId phaseId, MethodExpression listener, boolean beforePhase)
- {
- boolean skipPhase = false;
-
- if (listener != null || (_phaseListeners != null && !_phaseListeners.isEmpty()))
- {
- PhaseEvent event = createEvent(context, phaseId);
-
- if (listener != null)
- {
- listener.invoke(context.getELContext(), new Object[]{event});
- skipPhase = context.getResponseComplete() || context.getRenderResponse();
- }
-
- if (_phaseListeners != null && !_phaseListeners.isEmpty())
- {
- for (PhaseListener phaseListener : _phaseListeners)
- {
- PhaseId listenerPhaseId = phaseListener.getPhaseId();
- if (phaseId.equals(listenerPhaseId) || PhaseId.ANY_PHASE.equals(listenerPhaseId))
- {
- if (beforePhase)
- {
- phaseListener.beforePhase(event);
- }
- else
- {
- phaseListener.afterPhase(event);
- }
- skipPhase = context.getResponseComplete() || context.getRenderResponse();
- }
- }
- }
- }
-
- return skipPhase;
- }
-
- private PhaseEvent createEvent(FacesContext context, PhaseId phaseId)
- {
- if (_lifecycle == null)
- {
- LifecycleFactory factory = (LifecycleFactory) FactoryFinder.getFactory(FactoryFinder.LIFECYCLE_FACTORY);
- String id = context.getExternalContext().getInitParameter(FacesServlet.LIFECYCLE_ID_ATTR);
- if (id == null)
- {
- id = LifecycleFactory.DEFAULT_LIFECYCLE;
- }
- _lifecycle = factory.getLifecycle(id);
- }
- return new PhaseEvent(context, phaseId, _lifecycle);
- }
-
- private void _broadcastForPhase(PhaseId phaseId)
- {
- if (_events == null)
- {
- return;
- }
-
- boolean abort = false;
-
- int phaseIdOrdinal = phaseId.getOrdinal();
- for (ListIterator<FacesEvent> listiterator = _events.listIterator(); listiterator.hasNext();)
- {
- FacesEvent event = listiterator.next();
- int ordinal = event.getPhaseId().getOrdinal();
- if (ordinal == ANY_PHASE_ORDINAL ||
- ordinal == phaseIdOrdinal)
- {
- UIComponent source = event.getComponent();
- try
- {
- source.broadcast(event);
- }
- catch (AbortProcessingException e)
- {
- // abort event processing
- // Page 3-30 of JSF 1.1 spec: "Throw an AbortProcessingException, to tell the JSF implementation
- // that no further broadcast of this event, or any further events, should take place."
- abort = true;
- break;
- }
- finally
- {
- try
- {
- listiterator.remove();
- }
- catch (ConcurrentModificationException cme)
- {
- int eventIndex = listiterator.previousIndex();
- _events.remove(eventIndex);
- listiterator = _events.listIterator();
- }
- }
- }
- }
-
- if (abort)
- {
- // TODO: abort processing of any event of any phase or just of any event of the current phase???
- clearEvents();
- }
- }
-
-
- private void clearEvents()
- {
- _events = null;
- }
-
- private void checkNull(Object value, String valueLabel)
- {
- if (value == null)
- {
- throw new NullPointerException(valueLabel + " is null");
- }
- }
-
- private interface Processor
- {
- void process();
- }
-
- private Locale stringToLocale(String localeStr)
- {
- // locale expr: \[a-z]{2}((-|_)[A-Z]{2})?
-
- if (localeStr.contains("_") || localeStr.contains("-"))
- {
- if (localeStr.length() == 2)
- {
- // localeStr is the lang
- return new Locale(localeStr);
- }
- }
- else
- {
- if (localeStr.length() == 5)
- {
- String lang = localeStr.substring(0,1);
- String country = localeStr.substring(3,4);
- return new Locale(lang,country);
- }
- }
-
- return Locale.getDefault();
- }
-
-}
View
33 api/src/main/java/javax/faces/FacesException.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2004 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces;
@@ -24,9 +27,9 @@
public class FacesException
extends RuntimeException
{
- private static final long serialVersionUID = 6592152487577416317L;
+ private static final long serialVersionUID = 6592152487577416317L;
- public FacesException()
+ public FacesException()
{
super();
}
View
25 api/src/main/java/javax/faces/FactoryFinder.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2004 The Apache Software Foundation.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
*
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces;
View
29 api/src/main/java/javax/faces/application/Application.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2004 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces.application;
View
29 api/src/main/java/javax/faces/application/ApplicationFactory.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2004 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces.application;
View
29 api/src/main/java/javax/faces/application/FacesMessage.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2004 The Apache Software Foundation.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
*
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces.application;
@@ -27,9 +30,9 @@
public class FacesMessage
implements Serializable
{
- private static final long serialVersionUID = 4851488727794169661L;
+ private static final long serialVersionUID = 4851488727794169661L;
- public static final String FACES_MESSAGES = "javax.faces.Messages";
+ public static final String FACES_MESSAGES = "javax.faces.Messages";
public static final FacesMessage.Severity SEVERITY_INFO = new Severity("Info", 1);
public static final FacesMessage.Severity SEVERITY_WARN = new Severity("Warn", 2);
View
29 api/src/main/java/javax/faces/application/NavigationHandler.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2004 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces.application;
View
29 api/src/main/java/javax/faces/application/StateManager.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2004 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces.application;
View
25 api/src/main/java/javax/faces/application/StateManagerWrapper.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2006 The Apache Software Foundation.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
*
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces.application;
View
25 api/src/main/java/javax/faces/application/ViewExpiredException.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2006 The Apache Software Foundation.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
*
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces.application;
View
106 api/src/main/java/javax/faces/application/ViewHandler.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2004 The Apache Software Foundation.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
*
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
*/
package javax.faces.application;
@@ -70,29 +73,29 @@
*/
public String calculateCharacterEncoding(javax.faces.context.FacesContext context)
{
- String _encoding = null;
- ExternalContext externalContext = context.getExternalContext();
+ String _encoding = null;
+ ExternalContext externalContext = context.getExternalContext();
String _contentType = (String) externalContext.getRequestHeaderMap().get("Content-Type");
- int _indexOf = _contentType == null ? -1 :_contentType.indexOf("charset");
- if(_indexOf != -1)
- {
- String _tempEnc =_contentType.substring(_indexOf); //charset=UTF-8
- _encoding = _tempEnc.substring(_tempEnc.indexOf("=")+1); //UTF-8
- }
- else
- {
- boolean _sessionAvailable = externalContext.getSession(false) != null;
- if(_sessionAvailable)
- {
- Object _sessionParam = externalContext.getSessionMap().get(CHARACTER_ENCODING_KEY);
- if (_sessionParam != null)
- {
- _encoding = _sessionParam.toString();
- }
- }
- }
-
- return _encoding;
+ int _indexOf = _contentType == null ? -1 :_contentType.indexOf("charset");
+ if(_indexOf != -1)
+ {
+ String _tempEnc =_contentType.substring(_indexOf); //charset=UTF-8
+ _encoding = _tempEnc.substring(_tempEnc.indexOf("=")+1); //UTF-8
+ }
+ else
+ {
+ boolean _sessionAvailable = externalContext.getSession(false) != null;
+ if(_sessionAvailable)
+ {
+ Object _sessionParam = externalContext.getSessionMap().get(CHARACTER_ENCODING_KEY);
+ if (_sessionParam != null)
+ {
+ _encoding = _sessionParam.toString();
+ }
+ }
+ }
+
+ return _encoding;
}
/**
@@ -131,18 +134,29 @@ public String calculateCharacterEncoding(javax.faces.context.FacesContext contex
* This method is also invoked when navigation occurs from one view to another, where
* the viewId passed is the id of the new view to be displayed. Again it is the responsibility
* of renderView to then populate the viewroot with descendants.
+ * <p>
+ * The locale and renderKit settings are inherited from the current UIViewRoot that is
+ * configured before this method is called. That means of course that they do NOT
+ * get set for GET requests, including navigation that has the redirect flag set.
*/
public abstract javax.faces.component.UIViewRoot createView(javax.faces.context.FacesContext context,
String viewId);
/**
* Return a URL that a remote system can invoke in order to access the specified view.
+ * <p>
+ * Note that the URL a user enters and the viewId which is invoked can be
+ * different. The simplest difference is a change in suffix (eg url "foo.jsf"
+ * references view "foo.jsp").
*/
public abstract String getActionURL(javax.faces.context.FacesContext context,
String viewId);
/**
- * Return a URL that a remote system can invoke in order to access the specified resource..
+ * Return a URL that a remote system can invoke in order to access the specified resource.
+ * <p>
+ * When path starts with a slash, it is relative to the webapp root. Otherwise it is
+ * relative to the value returned by getActionURL.
*/
public abstract String getResourceURL(javax.faces.context.FacesContext context,
String path);
@@ -155,18 +169,18 @@ public abstract String getResourceURL(javax.faces.context.FacesContext context,
*/
public void initView(javax.faces.context.FacesContext context) throws FacesException
{
- String _encoding = this.calculateCharacterEncoding(context);
- if(_encoding != null)
- {
- try
- {
- context.getExternalContext().setRequestCharacterEncoding(_encoding);
- }
- catch(UnsupportedEncodingException uee)
- {
- throw new FacesException(uee);
- }
- }
+ String _encoding = this.calculateCharacterEncoding(context);
+ if(_encoding != null)
+ {
+ try
+ {
+ context.getExternalContext().setRequestCharacterEncoding(_encoding);
+ }
+ catch(UnsupportedEncodingException uee)
+ {
+ throw new FacesException(uee);
+ }
+ }
}
/**
View
39 api/src/main/java/javax/faces/application/ViewHandlerWrapper.java
@@ -1,17 +1,20 @@
/*
- * Copyright 2006 The Apache Software Foundation.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
*
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+