You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-dev@db.apache.org by "Thomas Fox (JIRA)" <ji...@apache.org> on 2011/06/25 20:39:47 UTC

[jira] [Resolved] (TORQUE-161) Create filler methods for related objects

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

Thomas Fox resolved TORQUE-161.
-------------------------------

       Resolution: Fixed
    Fix Version/s: 4.0

> Create filler methods for related objects
> -----------------------------------------
>
>                 Key: TORQUE-161
>                 URL: https://issues.apache.org/jira/browse/TORQUE-161
>             Project: Torque
>          Issue Type: New Feature
>            Reporter: Thomas Fox
>            Assignee: Thomas Fox
>             Fix For: 4.0
>
>
> Currently, foreing relations can be filled either by lazy loading or by doSelectJoin... methods.
> The former causes one db hit per object and the latter causes much unnecessary data to be transferred if more than thwo related tables are filled.
> Therefore, it should be possible to fill related objects by filler methods which take a Collection of objects and load the objects related by a foreign key.
> The fill should happen by generating new filler methods in the peer classes. In order not to bloat the public API, the generation of these methods can be switched on by a generation option. The default is that the filler methods are not created.
> For example, if the Book table has a foreign key on the author table, the methods Book.Peer.fillAuthors(List<Book>) and AuthorPeer.fillBooks(List<Author>) should be generated. They return the list of related objects, so cascaded filling is easy.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org