[jira] [Closed] (WICKET-5478) Wrong JavaDoc for WicketTester

2017-08-05 Thread Oliver B. Fischer (JIRA)

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

Oliver B. Fischer closed WICKET-5478.
-

> Wrong JavaDoc for WicketTester
> --
>
> Key: WICKET-5478
> URL: https://issues.apache.org/jira/browse/WICKET-5478
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 6.13.0
>Reporter: Oliver B. Fischer
>Assignee: Martin Grigorov
>Priority: Minor
>  Labels: doc, javadoc
> Fix For: 6.14.0, 7.0.0-M1
>
>
> The JavaDoc of {{WicketTester}} gives the following code example;
>  public void testRenderYourPage()
>  {
> // provide page instance source for WicketTester
> tester.startPage(new TestPageSource()
> {
> public Page getTestPage()
> {
> return new YourPage("mock message");
> }
> });
> tester.assertRenderedPage(YourPage.class);
> tester.assertLabel("yourMessage", "mock message");
> // assert feedback messages in INFO Level
> tester.assertInfoMessages(new String[] { "Wicket Rocks ;-)" });
>  }
> This example seems to be invalid since neither the class TestPageSource 
> exists nor a fitting method in WicketTester.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Created] (WICKET-5478) Wrong JavaDoc for WicketTester

2014-01-21 Thread Oliver B. Fischer (JIRA)
Oliver B. Fischer created WICKET-5478:
-

 Summary: Wrong JavaDoc for WicketTester
 Key: WICKET-5478
 URL: https://issues.apache.org/jira/browse/WICKET-5478
 Project: Wicket
  Issue Type: Bug
  Components: wicket
Affects Versions: 6.13.0, 6.14.0
Reporter: Oliver B. Fischer
Priority: Minor


The JavaDoc of {{WicketTester}} gives the following code example;

 public void testRenderYourPage()
 {
// provide page instance source for WicketTester
tester.startPage(new TestPageSource()
{
public Page getTestPage()
{
return new YourPage(mock message);
}
});
tester.assertRenderedPage(YourPage.class);
tester.assertLabel(yourMessage, mock message);
// assert feedback messages in INFO Level
tester.assertInfoMessages(new String[] { Wicket Rocks ;-) });
 }

This example seems to be invalid since neither the class TestPageSource exists 
nor a fitting method in WicketTester.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)


[jira] [Commented] (WICKET-5470) Remove 'final' from org.apache.wicket.markup.html.form.EnumChoiceRenderer#getDisplayValue

2014-01-13 Thread Oliver B. Fischer (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-5470?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13869392#comment-13869392
 ] 

Oliver B. Fischer commented on WICKET-5470:
---

Hi Martin,

that do you think about the following solution?

public final Object getDisplayValue(T object)
{
  final String value = getDisplayValueRaw(object);

  return postprocess(value);
} 


 Remove 'final' from 
 org.apache.wicket.markup.html.form.EnumChoiceRenderer#getDisplayValue
 -

 Key: WICKET-5470
 URL: https://issues.apache.org/jira/browse/WICKET-5470
 Project: Wicket
  Issue Type: Improvement
  Components: wicket
Affects Versions: 6.13.0
Reporter: Martin Grigorov
Assignee: Martin Grigorov
Priority: Minor
 Fix For: 6.14.0, 7.0.0


 org.apache.wicket.markup.html.form.EnumChoiceRenderer#getDisplayValue() adds 
 unnecessary indirection by providing overrideable #postprocess() method.
 If an application doesn't want to use the default implementation to resolve a 
 display value by using i18n resources then it should provide its own custom 
 implementation of IChoiceRenderer because 
 org.apache.wicket.markup.html.form.EnumChoiceRenderer#getDisplayValue is 
 final and it will throw MissingResourceException.
 If an application needs to use different logic it should be able to override 
 #getDisplayValue(). If it needs to do something like #postprocess() then it 
 can do:
 public Object getDisplayValue() {
   Object orig = super.getDisplayValue();
   return manipulate(orig);
 }



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)


[jira] [Commented] (WICKET-5470) Remove 'final' from org.apache.wicket.markup.html.form.EnumChoiceRenderer#getDisplayValue

2014-01-13 Thread Oliver B. Fischer (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-5470?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13869413#comment-13869413
 ] 

Oliver B. Fischer commented on WICKET-5470:
---

ok

 Remove 'final' from 
 org.apache.wicket.markup.html.form.EnumChoiceRenderer#getDisplayValue
 -

 Key: WICKET-5470
 URL: https://issues.apache.org/jira/browse/WICKET-5470
 Project: Wicket
  Issue Type: Improvement
  Components: wicket
Affects Versions: 6.13.0
Reporter: Martin Grigorov
Assignee: Martin Grigorov
Priority: Minor
 Fix For: 6.14.0, 7.0.0


 org.apache.wicket.markup.html.form.EnumChoiceRenderer#getDisplayValue() adds 
 unnecessary indirection by providing overrideable #postprocess() method.
 If an application doesn't want to use the default implementation to resolve a 
 display value by using i18n resources then it should provide its own custom 
 implementation of IChoiceRenderer because 
 org.apache.wicket.markup.html.form.EnumChoiceRenderer#getDisplayValue is 
 final and it will throw MissingResourceException.
 If an application needs to use different logic it should be able to override 
 #getDisplayValue(). If it needs to do something like #postprocess() then it 
 can do:
 public Object getDisplayValue() {
   Object orig = super.getDisplayValue();
   return manipulate(orig);
 }



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)


[jira] [Created] (WICKET-5394) DefaultDataTable should use factory methods for toolbars

2013-10-24 Thread Oliver B. Fischer (JIRA)
Oliver B. Fischer created WICKET-5394:
-

 Summary: DefaultDataTable should use factory methods for toolbars
 Key: WICKET-5394
 URL: https://issues.apache.org/jira/browse/WICKET-5394
 Project: Wicket
  Issue Type: Improvement
  Components: wicket-extensions
Affects Versions: 6.11.0
Reporter: Oliver B. Fischer


The constructor of the class DefaultDataTable should use factory methods as 
many other wicket classes to create its three toolbars instead of creating them 
directly. This would allow us to customize it as we want. Currently I have to 
copy the constructor in my subclass to alter the toolbars.




--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (WICKET-5394) DefaultDataTable should use factory methods for toolbars

2013-10-24 Thread Oliver B. Fischer (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-5394?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13804340#comment-13804340
 ] 

Oliver B. Fischer commented on WICKET-5394:
---

I got it, I have to inherit from DataTable. Please close the issue. Thx.

 DefaultDataTable should use factory methods for toolbars
 

 Key: WICKET-5394
 URL: https://issues.apache.org/jira/browse/WICKET-5394
 Project: Wicket
  Issue Type: Improvement
  Components: wicket-extensions
Affects Versions: 6.11.0
Reporter: Oliver B. Fischer

 The constructor of the class DefaultDataTable should use factory methods as 
 many other wicket classes to create its three toolbars instead of creating 
 them directly. This would allow us to customize it as we want. Currently I 
 have to copy the constructor in my subclass to alter the toolbars.



--
This message was sent by Atlassian JIRA
(v6.1#6144)