Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 567211
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T13:03:33+00:00 2026-05-13T13:03:33+00:00

@org.jboss.seam.annotations.security.management.UserRoles exposed in the User interface returns a simple List method. seam-gen doesn’t generate

  • 0

@org.jboss.seam.annotations.security.management.UserRoles exposed in the User interface returns a simple List method.

seam-gen doesn’t generate EntityQuery interfaces for @ManyToMany members like the getUserRoles mentioned above.

How do we enable this, so that the resultant roles are shown in a paginated fashion.

Edit 1:

This is the declaration in User.java

@ManyToMany(cascade = {CascadeType.MERGE, CascadeType.PERSIST, CascadeType.REFRESH}, fetch = FetchType.LAZY)
@JoinTable(name = "user_role", joinColumns = @JoinColumn(name = "user_id), inverseJoinColumns = @JoinColumn(name = "role_id"))
@UserRoles
private List<Role> userRoles = new ArrayList<Role>(0);

This is the declaration in Role.java

@Entity
@Table(name = "role", uniqueConstraints = @UniqueConstraint(columnNames = "name"))
public class Role {
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T13:03:33+00:00Added an answer on May 13, 2026 at 1:03 pm

    As said by Pete Muir, Seam lead developer

    Seam-gen does not support @ManyToMany relationship

    It does not generate the User Interface when using @ManyToMany. Although Seam-gen makes your life easier, sometimes, you have to do your job manually.

    Before going on

    1. Seam-gen uses Hibernate’s reverse-engineering-tool
    2. If a foreign key is missing in the table, Seam-gen can not suppose one table is related to another

    …

    So my advice is:

    1. Split your @ManyToMany relationship into @OneToMany – @ManyToOne relationship
    2. Set up reverse-engineering configuration

    The reverse-engineering configuration file that Seam-gen uses is resources/seam-gen.reveng.xml inside the generated project.

    Maybe you want to see

    Controlling reverse engineering

    Reverse engineering support in database and drivers

    Added to original answer

    Seam uses Ant to generate your app. Its build.xml file is located in the <SEAM_HOME>/seam-gen/build.xml

    There, you will see a target called generate-ui as follows

    <target name="generate-ui"
    

    It uses a Ant Tool called hbmtemplate. It is a Template based Engine in which can be controlled by a user provided template or class. So if you want a custom behavior, you should provide your own Freemarker template. In <SEAM_HOME>/seam-gen/view directory, you can see a lot of Template files (.flt extension)

    regards,

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 319k
  • Answers 320k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Yep, they're using long polling comet. Open Fiddler and you'll… May 14, 2026 at 12:16 am
  • Editorial Team
    Editorial Team added an answer By very chance I found what is wrong... I googled… May 14, 2026 at 12:16 am
  • Editorial Team
    Editorial Team added an answer In Effective Java, Chapter 7 (Methods), Item 40 (Design method… May 14, 2026 at 12:16 am

Related Questions

I'm trying to create a combobox on a sean project and the sean tags
My form validation works great, but the messages use the JSF component name and
I'm trying to run the Tomcat with JBoss Embedded jpa booking example. I run
I generated a new form using sean-gen (seam new-form) and added another field to
Seam will fire different kinds of events that relate to particular scopes, tasks, or

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.