[ 
https://issues.apache.org/jira/browse/WICKET-2162?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

James Carman updated WICKET-2162:
---------------------------------

    Description: 
In 1.4-rc1 (and before) it was possible to do this:

PageParameters params = new PageParameters();
params.put("myint", 12345);

In 1.4-rc2, it is not.  This code change happened in revision 735338 which has 
the log message "changed IndexSharedResourceCodingStrategy.encode to use 
LinkedHashMap to avoid difference between Java 5 and 6. Tests should now pass 
irrespective of the jdk version" and was checked in by "jdonnerstag."

I see no reason to be so strict on the types you can add to the PageParameters 
object, especially since the toRequestParameters() method already contains 
logic to convert the values to strings for types which it supports and it has 
the getInt() and getAsInteger() methods.  Can we please back this out?

I could perhaps see adding logic to check that it is indeed a type that is 
supported by the get*() methods, however.

  was:
In 1.4-rc1 (and before) it was possible to do this:

PageParameters params = new PageParameters();
params.put("myint", 12345);

In 1.4-rc2, it is not.  This code change happened in revision 735338 which has 
the log message "changed IndexSharedResourceCodingStrategy.encode to use 
LinkedHashMap to avoid difference between Java 5 and 6. Tests should now pass 
irrespective of the jdk version" and was checked in by "jdonnerstag."

I see no reason to be so strict on the types you can add to the PageParameters 
object, especially since ValueMap already contains logic to check which types 
it supports (PageParameters overrides that for some reason) and it has the 
getInt() and getAsInteger() methods.  Can we please back this out?


> REGRESSION: PageParameters.put() No Longer Accepts Integers as Values
> ---------------------------------------------------------------------
>
>                 Key: WICKET-2162
>                 URL: https://issues.apache.org/jira/browse/WICKET-2162
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.4-RC2
>            Reporter: James Carman
>
> In 1.4-rc1 (and before) it was possible to do this:
> PageParameters params = new PageParameters();
> params.put("myint", 12345);
> In 1.4-rc2, it is not.  This code change happened in revision 735338 which 
> has the log message "changed IndexSharedResourceCodingStrategy.encode to use 
> LinkedHashMap to avoid difference between Java 5 and 6. Tests should now pass 
> irrespective of the jdk version" and was checked in by "jdonnerstag."
> I see no reason to be so strict on the types you can add to the 
> PageParameters object, especially since the toRequestParameters() method 
> already contains logic to convert the values to strings for types which it 
> supports and it has the getInt() and getAsInteger() methods.  Can we please 
> back this out?
> I could perhaps see adding logic to check that it is indeed a type that is 
> supported by the get*() methods, however.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to