jsr344-experts@javaserverfaces-spec-public.java.net

[jsr344-experts] PhaseId API review

From: Andy Schwartz <andy.schwartz_at_oracle.com>
Date: Tue, 12 Mar 2013 18:11:58 -0400

Gang -

Minor comments on PhaseId...

Index: javax/faces/event/PhaseId.java
===================================================================
--- javax/faces/event/PhaseId.java (revision 8845)
+++ javax/faces/event/PhaseId.java (revision 11719)

+ /**
+ * <p class="changed_added_2_2">Return a <code>PhaseId</code>
+ * representation of the arcument <code>phase</code>.</p>

Typo: arcument -> argument.

+ *
+ * @param phase the String for which the corresponding
+ * <code>PhaseId</code> should be returned.
+ *
+ * @throws <code>NullPointerException</code> if argument
<code>phase</code> is
+ * <code>null</code>.
+ *
+ * @throws <code>FacesException</code> if the <code>PhaseId</code>
+ * corresponding to the argument <code>phase</code> cannot be found.

This should be IllegalArgumentException.

+ *
+ * @since 2.2
+ */
+
+ public static PhaseId phaseIdValueOf(String phase) {

The Mojarra implementation does a case insensitive check for all of the
names except for ANY_PHASE_NAME.

The case sensitivity behavior should be consistent across all values and
should be specified.

Andy