[jsr-314-open] More spec issues

Simon Lessard Simon_Lessard at DMR.CA
Tue Mar 31 10:25:12 EDT 2009


Hi,
 
I'm working on MyFaces. Alright for the other comments.
 
 
Regards,
 
~ Simon
 

________________________________

From: JSR 314 Open Mailing list on behalf of Ed Burns
Sent: Fri 3/27/2009 9:55 PM
To: JSR-314-OPEN at JCP.ORG
Subject: Re: [jsr-314-open] More spec issues



>>>>> On Fri, 27 Mar 2009 11:15:08 -0400, Simon Lessard <Simon_Lessard at DMR.CA> said:

SL> Hi all,
SL> I have a couple more issues I found while implementing the latest
SL> spec:

Thanks.  Can you share with the EG if you're doing a complete new Impl?
This would be big news for me because AFAIK, Sun and Apache are the only
ones doing new JSF2 impls.

SL> * ViewHandler.FACELETS_VIEW_MAPPINGS_PARAM_NAME: The doc says that

I'll let others chime in on that one.  The behavior as specified seems
useful to me.

SL> * ViewHandler.getPageDeclarationLanguage(): JavaDoc gives two
SL> default implementations, one invoking the factory from FactoryFinder
SL> (useful) and the throws UnsupportedOperationException
SL> one. Personally, I'd keep only the real method here as the
SL> processing doesn't involve any private/non standard API;

I see your point, but we did it this way to allow JSF 1.2 ViewHandlers
to easily be detected, so we'll leave this the same as well.

SL> * AjaxBehavior.getHints(): JavaDoc says it should return an emprt
SL> Set (like ClientBehaviorBase), making the method declaration in
SL> AjaxBehavior useless. However Mojarra returns a Set containing
SL> SUBMITTING, so I assume the code is right and the JavaDoc wrong
SL> here;

Roger integrted this one.

SL> * UIComponentBase.initialStateMarked(): This method is not defined
SL> in the JavaDoc while the two others from PartialStateHolder are.

I think this one's ok as is.

SL> * ExternalContext.getRequestCookieMap(): Can the return value be
SL> changed from Map<String,Object> to Map<String, Cookie> please?

We can't do that because Cookie is declared in the Servlet spec, and
Portlet people wouldn't be happy if we added that to our API.

SL> * PageDeclarationLanguageFactory.getPageDeclarationLanguage(String
SL> viewId): The JavaDoc says that ClassNotFoundException should be
SL> thrown when no valid PLD can be found. However,
SL> ClassNotFoundException is a checked exception and the method does
SL> not that this exception in its throws clause. The doc should either
SL> says to wrap it in a FacesException or add ClassNotFoundException to
SL> the throws clause;

I've removed the @throws ClassNotFoundException

SL> * ExceptionHandler.handle(): The spec specifies that this method
SL> should only throw a FacesException if an internal error occurs while
SL> handling the exception. However, it also says to throw either
SL> ServletException or PortletException depending on the environment
SL> and those are checked exception not declared in the throws
SL> clause. Mojarra wrap them in a FacesException, so the spec mighth
SL> ave to be ajusted to reflect that.

SL> That's all for now,



SL> ~ Simon




SL> ________________________________

SL> From: JSR 314 Open Mailing list on behalf of Ed Burns
SL> Sent: Fri 3/27/2009 10:30 AM
SL> To: JSR-314-OPEN at JCP.ORG
SL> Subject: Rename: PDL->VDL



SL> We have "View" everywhere else, so we should rename
SL> PageDeclarationLanguage to ViewDeclarationLanguage.

SL> I'm taking care of this now.

SL> Ed
SL> --
SL> | ed.burns at sun.com  | office: 408 884 9519 OR x31640
SL> | homepage:         | http://ridingthecrest.com/


SL> <HTML dir=ltr><HEAD><TITLE>Rename: PDL->VDL</TITLE>
SL> <META http-equiv=Content-Type content="text/html; charset=unicode">
SL> <META content="MSHTML 6.00.6000.16674" name=GENERATOR></HEAD>
SL> <BODY>
SL> <P><FONT face=Arial size=2>Hi all,</FONT></P>
SL> <P><FONT face=Arial size=2>I have a couple more issues I found while implementing the latest spec:</FONT></P>
SL> <UL>
SL> <LI><FONT face=Arial size=2>ViewHandler.FACELETS_VIEW_MAPPINGS_PARAM_NAME: The doc says that the implementation should also read original Facelets' param for the purpose of defining mappings. I don't think that's a good idea. Facelets was not a standard up to that point and users shouldn't really expect no migration effort at all. I know that enforcing that param would allow xisting applications using facelet.jar to be deployed in 2.0 environment, but to my knòwledge, no other spec read some non standard context params (I may be wrong though). If we do enforce the original parameters, then we'll be stuck with it forever so at least let use only that one and not define a new one;</FONT></LI>
SL> <LI><FONT face=Arial size=2>ViewHandler.getPageDeclarationLanguage(): JavaDoc gives two default implementations, one invoking the factory from FactoryFinder (useful) and the throws UnsupportedOperationException one. Personally, I'd keep only the real method here as the processing doesn't involve any private/non standard API;</FONT></LI>
SL> <LI><FONT face=Arial size=2>AjaxBehavior.getHints(): JavaDoc says it should return an emprt Set (like ClientBehaviorBase), making the method declaration in AjaxBehavior useless. However Mojarra returns a Set containing SUBMITTING, so I assume the code is right and the JavaDoc wrong here;</FONT></LI>
SL> <LI><FONT face=Arial size=2>UIComponentBase.initialStateMarked(): This method is not defined in the JavaDoc while the two others from PartialStateHolder are.</FONT></LI>
SL> <LI><FONT face=Arial size=2>ExternalContext.getRequestCookieMap(): Can the return value be changed from Map&lt;String,Object&gt; to Map&lt;String, Cookie&gt; please?</FONT></LI>
SL> <LI><FONT face=Arial size=2>PageDeclarationLanguageFactory.getPageDeclarationLanguage(String viewId): The JavaDoc says that ClassNotFoundException should be thrown when no valid PLD can be found. However, ClassNotFoundException is a checked exception and the method does not that this exception in its throws clause. The doc should either says to wrap it in a FacesException or add ClassNotFoundException to the throws clause;</FONT></LI>
SL> <LI><FONT face=Arial size=2>ExceptionHandler.handle(): The spec specifies that this method should only throw a FacesException if an internal error occurs while handling the exception. However, it also says to throw either ServletException or PortletException depending on the environment and those are checked exception not declared in the throws clause. Mojarra wrap them in a FacesException, so the spec mighth ave to be ajusted to reflect that.</FONT></LI></UL>
SL> <P><FONT face=Arial size=2>That's all for now,</FONT></P>
SL> <P><FONT face=Arial size=2></FONT>&nbsp;</P>
SL> <P><FONT face=Arial size=2>~ Simon</FONT></P>
SL> <P><BR></P>
SL> <DIV dir=ltr>
SL> <HR tabIndex=-1>
SL> </DIV>
SL> <DIV dir=ltr><FONT face=Tahoma size=2><B>From:</B> JSR 314 Open Mailing list on behalf of Ed Burns<BR><B>Sent:</B> Fri 3/27/2009 10:30 AM<BR><B>To:</B> JSR-314-OPEN at JCP.ORG<BR><B>Subject:</B> Rename: PDL-&gt;VDL<BR></FONT><BR></DIV>
SL> <DIV>
SL> <P><FONT size=2>We have "View" everywhere else, so we should rename<BR>PageDeclarationLanguage to ViewDeclarationLanguage.<BR><BR>I'm taking care of this now.<BR><BR>Ed<BR>--<BR>| ed.burns at sun.com&nbsp; | office: 408 884 9519 OR x31640<BR>| homepage:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | <A href="http://ridingthecrest.com/">http://ridingthecrest.com/</A><BR></FONT></P></DIV></BODY></HTML>

--
| ed.burns at sun.com  | office: 408 884 9519 OR x31640
| homepage:         | http://ridingthecrest.com/


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jsr-314-open-mirror/attachments/20090331/c3a6b425/attachment.html 


More information about the jsr-314-open-mirror mailing list