Uploaded image for project: 'Spring Roo'
  1. Spring Roo
  2. ROO-3584

JavaBean implementing Interface defining getters and setters

This issue belongs to an archived project. You can view it, but you can't modify it. Learn more

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.3.1.RC1
    • 1.3.1.RC2
    • GENERAL OBJECTS
    • Java 7

    Description

      Interface:

      public interface MeeInterface {
      
        public String getName();
        
        public void setName(String name);
      }
      

      JavaBean implementing Interface:

      @RooJavaBean
      public class MeeEntity implements MeeInterface {
      
      	private String name;
      }	
      

      That was no problem in Roo 1.2.x - it generated MeeEntity_Roo_JavaBean.aj containing a getName and setName, not complaining in any way. In Roo 1.3.1.RC1 writes:

      Method 'getName' already defined in ITD (ITD target 'xxx.MeeEntity_Roo_JavaBean')

      adding:

      	public String getName() {
      		return name;
      	}
      

      writes on roo shell:

      Method '[email protected]76b87d4c[methodName=setName,parameterTypes=[]]' failed to provide a body, despite being identified for ITD inclusion

      which can be fixed by adding:

      	public void setName() {
      	}
      

      Attachments

        Activity

          People

            jcgarcia Juan Carlos GarcĂ­a del Canto
            markus.strenn Markus Strenn
            Archiver:
            tmarshall Trevor Marshall

            Dates

              Created:
              Updated:
              Resolved:
              Archived: