You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Jochen Mader <pf...@gmail.com> on 2012/11/17 13:19:50 UTC

Why is SortParam.getProperty generic?

It might be due to the fact that I am sick but I don't get why
SortParam.getProperty doesn't return a String but T.
So far I always used getProperty as vasis for a PropertyModel to resolve things.
Any hint would be appreciated,
Jochen

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Why is SortParam.getProperty generic?

Posted by Jesse Long <jp...@unknown.za.net>.
I use sort parameters of type Field<Table> where field is a meta data 
type describing a field in (or reachable through joins from) the table 
represented by the Table class.

My data provider then uses the currently selected Field to create the 
"ORDER BY" part of the SQL.

Cheers,
Jesse

On 17/11/2012 16:42, Sven Meier wrote:
> It's just that some devs wanted to use other things than strings to 
> identify the sort order:
>
>   https://issues.apache.org/jira/browse/WICKET-4535
>
> Perhaps Jesse has an example?
>
> Sven
>
>
> On 11/17/2012 01:19 PM, Jochen Mader wrote:
>> SortParam.getProperty doesn't return a String butIt might be due to 
>> the fact that I am sick but I don't get why
>>   T.
>> So far I always used getProperty as vasis for a PropertyModel to 
>> resolve things.
>> Any hint would be appreciated,
>> Jochen
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Why is SortParam.getProperty generic?

Posted by Jochen Mader <pf...@gmail.com>.
I was just about to answer my own question.
We migrated a big part of our application to use LambdaJ instead of
PropertyModels. With getProperty being generic it's now possible to
use it instead of passing around strings.
Thanks,
Jochen

On Sat, Nov 17, 2012 at 4:01 PM, Jochen Mader <pf...@gmail.com> wrote:
> On Sat, Nov 17, 2012 at 3:42 PM, Sven Meier <sv...@meiers.net> wrote:
>> It's just that some devs wanted to use other things than strings to identify
>> the sort order:
>>
>>   https://issues.apache.org/jira/browse/WICKET-4535
>>
>> Perhaps Jesse has an example?
>>
>> Sven
>>
>>
>> On 11/17/2012 01:19 PM, Jochen Mader wrote:
>>>
>>> SortParam.getProperty doesn't return a String butIt might be due to the
>>> fact that I am sick but I don't get why
>>>
>>>   T.
>>> So far I always used getProperty as vasis for a PropertyModel to resolve
>>> things.
>>> Any hint would be appreciated,
>>> Jochen
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> For additional commands, e-mail: users-help@wicket.apache.org
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Why is SortParam.getProperty generic?

Posted by Jochen Mader <pf...@gmail.com>.
On Sat, Nov 17, 2012 at 3:42 PM, Sven Meier <sv...@meiers.net> wrote:
> It's just that some devs wanted to use other things than strings to identify
> the sort order:
>
>   https://issues.apache.org/jira/browse/WICKET-4535
>
> Perhaps Jesse has an example?
>
> Sven
>
>
> On 11/17/2012 01:19 PM, Jochen Mader wrote:
>>
>> SortParam.getProperty doesn't return a String butIt might be due to the
>> fact that I am sick but I don't get why
>>
>>   T.
>> So far I always used getProperty as vasis for a PropertyModel to resolve
>> things.
>> Any hint would be appreciated,
>> Jochen
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Why is SortParam.getProperty generic?

Posted by Sven Meier <sv...@meiers.net>.
It's just that some devs wanted to use other things than strings to 
identify the sort order:

   https://issues.apache.org/jira/browse/WICKET-4535

Perhaps Jesse has an example?

Sven


On 11/17/2012 01:19 PM, Jochen Mader wrote:
> SortParam.getProperty doesn't return a String butIt might be due to the fact that I am sick but I don't get why
>   T.
> So far I always used getProperty as vasis for a PropertyModel to resolve things.
> Any hint would be appreciated,
> Jochen
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org