发布于 2016-04-01 23:23:22 | 104 次阅读 | 评论: 0 | 来源: 网友投递
OmniFaces JSF2 工具库
OmniFaces 是一个 JSF 2 的工具库,其目的是为了让 JSF 应用开发更加简单。
OmniFaces 2.3 发布了。
OmniFaces 是一个 JSF 2 的工具库,其目的是为了让 JSF 应用开发更加简单。
如果你厌倦了重塑JSFUtil或FacesUtil实用程序类,为每个JSF web应用程序定制组件,使用 taghandlers 等来解决JSF的缺点的话,OmniFaces可能是你要找的东西!
与那些其他JSF 2库(如PrimeFaces,BootsFaces或ButterFaces)已经熟知和喜爱的美丽的视觉导向组件相反,OmniFaces也许永远不会包含丰富的表格组件或漂亮视觉之类的东西。把OmniFaces说成是处理日常JSF API中的小缺点的实际问题和解决方法“实用工具”更为适合。
新特性:
#17 - <o:socket>for web socket based push which can be accessed via CDI@Push
72d3aae - Servlets#getRemoteAddr()to get request remote address, taking into account theX-Forwarded-Forheader
e3ee8fb - Beans#isActive(scope)to check if a scope is active without need to catchContextNotActiveException
#194 - Faces#sendFile()has now one more method accepting anOutputStreamcallback
#125 - #202 - <o:skipValidators>to skip all validation during aUICommandaction or an ajax request
a2c1473 - of:formatThousands()to round a number to nearest thousand with immediate "k", "M", "G", etc suffix and a precision of 3 digits, whereafter trailing zeroes in fraction are stripped
#204 - of:formatThousandsUnit()to round a number to nearest thousand of given unit with "k", "M", "G", etc prefix and a precision of 3 digits, whereafter trailing zeroes in fraction are stripped
#206 - of:formatNumberDefaultForLocale()to format a number in locale-default pattern of given locale
#205 - Faces#getViewName()to get base name of current view (without extension)
#196 - FullAjaxExceptionHandlernow supports a new context paramorg.omnifaces.EXCEPTION_TYPES_TO_UNWRAPwhere you can specify additional exception types to unwrap the root cause from.
#216 - FileServletnow supports customizing 404 error handling and attachment file name.
8dbd495 - Ajax#load()to load a script resource on complete of current ajax request.
改进:
#178 - <o:importConstants>will not anymore include parent of an inner class in default value ofvarattribute, so e.g.#{Parent$Inner}will now be#{Inner}
214d189 -BeanManager.INSTANCE.getReference()is deprecated in favor of Beans#getReference()
#218 - <o:commandScript>now supports declaring a namespaced function
修复:
84f6748 - WebXml#isAccessAllowed()incorrectly matched extension based URLs in prefix path checking
b3d2ea5 - When mapping FacesViews on/and triggering a 404 error, then Mojarra confusingly threw a "Response already committed" exception
#187 - <o:form>didn't render HTML attributes such asstyleClasswhen MyFaces is used
#199 - @ViewScopedfailed to initialize unload script when it's created for first time after an ajax navigation action
#200 - Components#findComponentInParents()ran in an infinite loop when illegal client ID is supplied
#208 - @ViewScopeddidn't physically remove server side JSF view state during unload
c972602 - OmniPartialViewContextwill now invalidate session before redirecting toweb.xmlform login page (fixes WildFly's agressive caching of login page response which exposes as<partial-response>XML visible in browser)
#226 - <o:tree>failed to resolve#{cc}when nested in composite component
#225 - <o:validateBean>failed on string concatenated properties like#{bean[foo += bar]}
详情请看发行日志