不可不看,JSF1.2 changes

变化还是挺多的,仔细看看,可以省掉很多郁闷的时间哦。

The numbers in the text below refer to issue numbers in the issue tracker found at
<https://javaserverfaces-spec-public.dev.java.net/servlets/ProjectIssues>.
■ 2 - Clarify that for client side state saving, the state should be encrypted for security.
■ 3 - Clarify the specification with respect to constraint violations for tags in the Core Tag
Library.
■ 4 - Added headerClass and footerClass attributes at the “h:column” level. Please
see Section 8.5 “Standard HTML RenderKit Implementation” for more details.
■ 5 - Clarified the use of a string literal for the “action” attribute on ActionSource
components.
■ 6 - Introduced a new optional “label” attribute for input components that will provide an
association between a component, and the message that the component (indirectly)
produced. Please refer to Section 8.5 “Standard HTML RenderKit Implementation” and
Section 2.5.2.4 “Localized Application Messages” for more details.
■ 8 - Made UViewRoot a source of PhaseEvent(s) for all phases of the request processing
lifecycle except RestoreView. Provided additional “before” and “after” phase listener
attributes for the <f:view> tag. Please see Section 4.1.17 “UIViewRoot” for more details.
■ 9 - Clarified the behavior of PhaseListener implementations in the following way: they
must guarantee that if “beforePhase()” is called, then “afterPhase()” must also be called,
regardless of any thrown exceptions. Please see Section 11.3 “PhaseListener” for more
specifics.
■ 11 - Provide a unique window identifier (in addition to the “viewid”) to accomodate
applications that have mutiple instances of the same view, but perhaps in different
browser windows or frames.

13 - Specified “by type” converter registration for BigDecimal and BigInteger.
■ 15 - Enhanced the usage of the “Decorator Pattern” for ViewHandler, StateManager and
ResponseWriter classes by providing abstract wrapper classes to make it easier to override
a subset of the total methods for those classes. Please see Section 10.4.5 “Delegating
Implementation Support” for more details.
■ 16 - Provided additional I18n attributes “dir and “lang” for the tags: <h:outputText>,
<h:outputFormat>, <h:messages>, <h:message>. Please see Section 8.5 “Standard HTML
RenderKit Implementation” for descriptions of these components.
■ 17 - Introduced a new optional “layout” attribute on the “PanelGroup” component that
controls the rendering of either a “div” or “span” HTML element. Please see Section 8.5
“Standard HTML RenderKit Implementation” for more details.
■ 18 - When a resource lookup is done on the java.util.Map (loaded from <f:loadBundle>)
using a key, and the key is not found in the Map, return the literal string ???KEY???
where KEY is the key being looked up in the Map (instead of throwing a
MissingResourceException). Throw a JspException if the named bundle identified by
<f:loadBundle> does not exist. Please see Section 9.4.7 “<f:loadBundle>”.
■ 20 - Specify that the event queue should be cleared after each phase (except
RestoreViewPhase and RenderResponse) if “responseComplete” or “renderResponse” has
been set on the FacesContext.
■ 21 - Provided an additional “binding” attribute for the core Converter, Listener and
Validator tags that would be used as a ValueExpression to alternatively create the
Converter, Listener or Validator instance. Please see Section 9.4 “JSF Core Tag Library”
for more details.
■ 27 - <h:messages> now renders HTML list elements (“<ul>”,”<li>”) if the “layout”
attribute is “list” or the “layout” attribute is not specified. If the “layout” is “table”, an
HTML “table” element is rendered instead of an outer “span”. Please see Section 8.5
“Standard HTML RenderKit Implementation” for more details.
■ 29 - Allow the use of user-defined “onclick” Javascript on CommandLink.
■ 30 - Make the “commandButton” “image” attribute render the same as the
“graphicImage” “img” attribute for consistency. Please see Section 8.5 “Standard HTML
RenderKit Implementation” for more information.
■ 35 - Provided a new facet for DataTable Renderer that allows the rendering of a table
“caption” element immediately following the “table” element. Also provided style sheet
attributes for this new element. Please see Section 8.5 “Standard HTML RenderKit
Implementation” for a descrption of this component.
■ 43 - Migrated over to using XML Schema (from DTD) for configuation file validation.
Please see Section 1.1 “XML Schema Definition”.
■ 45 - Avoided concurrent read issues by using a java.util.HashMap instead of
java.util.WeakHashMap for a component’s Property Descriptor Map. This also fixes the
performance problem as identified in the forum. Please refer to the Property Descriptor
methods and the constructor in javax.faces.component.UIComponentBase.
■ 47 - Introduced a mechanism to detect if a request is a postback.

48 - Specify the algorithm used for client id generation as well as provide a way to allow
the page author to specify exactly what the client Id should be, and preventing Faces from
altering it.
■ 50 - Allow an application to specify multiple render kits by introducing an optional
“renderKitId” attribute on “<f:view>”. It is no longer required to write a custom
ViewHandler to incorporate a different render kit. Please refer to Section 8.3
“ResponseStateManager” and Section 9.4.20 “<f:view>” for more details.
■ 51 - Clarify the specification with respect to “Application Startup Behavior”. Allow
implementations to check for the presence of a servlet-class definition in a web
application deployment descriptor as a means to abort the configuration and save startup
time.
■ 54 - Added new extension elements to the Faces XML schema. Please see Section 1.1
“XML Schema Definition”.
■ 55 - For postback requests, in the “RestoreViewPhase”, during ValueExpression
examination for each component in the component tree, specify that calling the
setValue() method on each ValueExpression, should be done in a “parent-first”
fashion, calling the setValue() method and then traversing the children.
■ 58 - Enabed “protected” access to internal “DataModel” in UIData.
■ 59 - Avoid EL expression evaluation for “value” attribute on “AttributeTag”.
“AttributeTag” now passes the expression to UIComponent for evaluation.
■ 65 - Added standard converter messages. Please see Section 2.5.2.4 “Localized
Application Messages” for more details.
■ 66 - Specified that “FormRenderer” must render the “name” attribute with the same value
as the “id” attribute. Please see Section 8.5 “Standard HTML RenderKit Implementation”
for more details.
■ 67 - Allow the resetting of an input component’s value by introducing a resetValue()
method on UIInput.
■ 68 - Specify that the component tree may be manipulated throughout the request
processing lifecycle, except during render. Please see Section 2.2.6 “Render Response”
for more details.
■ 69 - Permit the passing of a null value to SelectItem.setValue().
■ 72 - Improve XHTML compliance by rendering both “lang” and “xml:lang” attributes.
■ 73 - Added a new FacesException - “javax.faces.application.ViewExpiredException”.
Specified that implementations must throw this exception when an attempt to restore a
view results in failure on postback. Please see Section 2.2.1 “Restore View” for more
details.
■ 74 - Added “disabled” property to “outputLink” and “commandLink”. Please see
Section 8.5 “Standard HTML RenderKit Implementation” for more details.
■ 75 - Added “getRequestContentType” and “getResponseContentType” to ExternalContext.
■ 78 - Added a more “user-friendly” default error message for UIInput “update model”.
Please see Section 2.5.2.4 “Localized Application Messages” for more details.

80 - Specify that the JSF Core Tag Library must not contain any tags that cause JavaScript
to be rendered to the client.
■ 81 - Enable the message displayed for “required” validation, conversion, and validation to
be overridden by the page author (JSP or non-JSP)
■ 82 - Added new feature, the ability to resolve ResourceBundles via the EL without the use
of the <f:loadBundle> tag.
■ 84 - Added rendered attribute to the core f:verbatim tag. Please see Section 9.4
“JSF Core Tag Library” for more details.
■ 85 - Add new tag: f:setPropertyActionListener. Useful for pushing values into managed
beans without allowing modification of the value.
■ 86 - Specified that “OutputLinkRenderer” must render the “name” attribute with the same
value as the “id” attribute. Please see Section 8.5 “Standard HTML RenderKit
Implementation” for more details.
■ 87 - Modified specification for the setVariableResolver() and
setPropertyResolver() methods on Application to state that they may not be
called after the application has served any requests.
■ 93 - Added “escape” flag indicating the text of UISelectItem should be escaped when
rendering.
■ 95 - Allow multiple instances of FacesServlet in a single webapp, mapped with
different URI mappings, to use different implementations of Lifecycle by allowing the
lifecycle-id to be specified as an init-param in addition to the existing way of
specifying it as a context-param.
■ 98 - Specified that “SelectManyCheckboxListRenderer: and “RadioRenderer” must render
the “label” element after the “input element for each “SelectItem. Specified that the
“label” element must refer to the “input” element using the “for” attribute. Please see
Section 8.5 “Standard HTML RenderKit Implementation” for more details.
■ 99 - Specified Java EE 5 Generics usage where applicable.
■ 105 - Specified that for commandButton rendering, the “image” attribute value must not
be escaped. Specified that for graphicImage rendering, the “src” attribute value must not
be escaped.
■ 108 - Specified that JSF implementations that are part of a Java EE technology-compliant
implementation are required to validate the application resource file against the XML
schema for structural correctness. Also specified that validation is recommended, but not
required for JSF implementatons that are not part of a Java EE technology compliant
implementation. Please refer to Section 10.4.2 “Application Startup Behavior” for more
details.
■ 111 - Specified that a component must allow child components to be added to and
removed from the child list of the current component, even though the child component
returns null from getParent().
■ 118 - Specified that an implementation of Map returned from
ExternalContext.getSessionMap implement a “clear” method that calls “removeAttribute”
on each attribute in the Servlet or Portlet session.

119 - Specified that implementations running in a JSR-250 compliant container have their
managed bean methods annotated with @PostConstruct be called after the object is
instantiated, and after injection is performed, but before the bean is placed into scope.
Specified that methods annotated with @PreDestroy be called when the scope for the
bean is ending.
■ 120 - Specified in the renderkit docs that commandButton rendering can generate
javascript for “onclick” attribute.
■ 122 - Clarified renderkit docs with respect to what gets rendered for disabled command
link attributes.
■ 123 - Clarified renderkit docs with respect to dataTable attribute rendering.
■ 124 - Clarified renderkit docs with repsect to graphicImage “alt” attribute.
■ 131 - Specified that a compliant implementation must allow the registration of a converter
for class java.lang.String and java.lang.String.TYPE that will be used to convert values
for these types.
■ 133 - Removed the incorrect statement: “"It is the callers responsibility to ensure that
setViewId() is called on the returned view, passing the same viewId value." pertaining to
ViewHandler.createView()
■ 134 - Fixed backwards compatability issues.
■ 135 - Support Java EE 5 enums as valid types/
■ 138 - Change the required return type for action methods to be Object instead of String.
This allows the usage of Enums for the return type of action methods, as long as the
toString() method of the enum matches the expected value in the application configuration
resources.
■ 145 - Define new method on UIComponent, invokeOnComponent(). This will find a
component in the tree by clientId and invoke a user specified callback on it. Please see
Section 3.1.8 “Component Tree Navigation” and Section 4.1.1.3 “Methods” [of UIData]
for more details.
■ jsf-ri 127 - Specify that FacesContext methods getClientIdsWithMessages( ) and
getMessages( ) must be implemented using order-preserving structures so the items in the
iterator are returned in the order they were added with addMessage().Spec document
changes
■ 147 - Clarified grammer with respect to component id.
■ 151 - Specified standard converter for Enums
■ 152 - Specified EL coercion usage in API javadocs UISelectOne/UISelectMany (when
items are compared in validation) and standard html renderkit docs during encoding of
select components.
■ 154 - Fixed FacesTag “name” attribute discrepency - made it a String (was
ValueExpression).
■ 155 - Specified “columnClasses”, “rowClasses” descriptions for panelGrid in renderkit
docs.

160 - Added and specified ResponseWriter.writeText method that takes a UIComponent
argument.
■ The TLDDocs for the h: tag library are now a normative part of the spec.

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值