Results 1 to 4 of 4

Thread: override finder default naming

  1. #1
    Join Date
    Sep 2008
    Posts
    7

    Default override finder default naming

    is it possible to override the default naming?

    for example i have domain:
    Code:
    @RooJavaBean
    @RooToString
    @RooEntity(finders = { "findPropertysByOrganization" })
    public class Property {
    
        @OneToOne
        private Address address;
    
        @ManyToOne
        private Organization organization;
    
        @OneToMany(cascade = CascadeType.ALL, mappedBy = "property")
        private Set<ForeclosureNotice> foreclosureNotices = new HashSet<ForeclosureNotice>();
    
        @OneToMany(cascade = CascadeType.ALL)
        private Set<Document> documents = new HashSet<Document>();
    }
    Notice the finder is 'findPropertysByOrganization'. Id like 'findPropertiesByOrganization'. Not critical, just a PITA.

  2. #2
    Join Date
    Mar 2010
    Posts
    7

    Default

    I can't seem to find the documentation for it, but I believe you can use the annotation @RooPlural("properties") on your entity.

  3. #3
    Join Date
    Sep 2008
    Posts
    7

    Default

    thx. i'll give that a shot and report back.

  4. #4
    Join Date
    Sep 2008
    Posts
    7

    Default

    yup, that worked. thx.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •