[hibernate-issues] [Hibernate-JIRA] Commented: (HSHARDS-43) Can not sort on fields with private getters

Aviad Lichtenstadt (JIRA) noreply at atlassian.com
Tue Aug 28 05:00:58 EDT 2007


    [ http://opensource.atlassian.com/projects/hibernate/browse/HSHARDS-43?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_27953 ] 

Aviad Lichtenstadt commented on HSHARDS-43:
-------------------------------------------

The patch i attached contains some bugs:
it will be good only for methods declared in the object itself and not any method that belong to super class

i am attaching a patch to the patch that should resolve this issue.

it runs in a loop on the object and all the super hierarchy until the method is found.
in cases were the method is not found a NoSuchMethodException will be created and thrown.

> Can not sort on fields with private getters
> -------------------------------------------
>
>                 Key: HSHARDS-43
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HSHARDS-43
>             Project: Hibernate Shards
>          Issue Type: Bug
>          Components: strategy
>    Affects Versions: 3.0.0.Beta2
>         Environment: hibernate 3.2.0
>            Reporter: Aviad Lichtenstadt
>            Assignee: Max Ross
>            Priority: Minor
>         Attachments: PrivateGetters.txt, PrivateGettersSecondEdition.txt
>
>
> Build a criteria.
> add order to the criteria
> the order field should be one with only private getters and setters
> an exception is thrown saying that there is no such method in the object
> I am applying a patch that fixes this issue

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the hibernate-issues mailing list