facebook

Bug in XDoclet EJB Util Class generation

  1. MyEclipse Archived
  2.  > 
  3. Bugs
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #201262 Reply

    I am creating a series of Entity EJBs, using java.lang.Integer for their primary keys. XDoclet generates a Util class under the .interfaces package for each Entity bean class.
    In this Util class (e.g. CustomerBeanUtil), a severe compilation error (under Eclipse) occurs in this method:
    private static String hexFormat(int i, int j) {
    String s = Integer.toHexString(i);
    return padHex(s, j) + s;
    }
    Namely, “The method Integer.toHexString is undefined for the type Integer.”

    I checked java.lang.Integer and it does have a method toHexString, which puzzled me.
    However, I looked further and discovered that XDoclet generates an Integer class of its own in a local package, java.lang on my own PC. This local Integer class does not have the method, toHexString. This seems to be the reason for the severe compilation error in my Eclipse IDE.

    Details:
    What operating system and version are you running?
    OS: Windows XP 5.1.2600
    What JDK version are you using to run Eclipse? (java -version)
    What JDK version are you using to launch your application server?
    Both J2SE 1.4.2_02
    What Eclipse version and build id are you using? (Help > About Eclipse Platform)
    Eclipse 2.1.2 Build 200311030802
    What MyEclipse version are you using? (Help > About Eclipse Platform > Features)
    MyEclipse Version 2.6.4
    – Was Eclipse freshly installed for MyEclipse?
    No
    – If not, was it upgraded to its current version using the update manager?
    No
    – Are any other external plugins installed?
    Yes
    – How many plugins in the <eclipse>/plugins directory are like org.eclipse.pde.*
    7
    What application server are you using?
    JBoss 3.2.2
    Are there any errors in the Eclipse log? (<workspace>/.metadata/.log)
    No

    #201271 Reply

    Scott Anderson
    Participant

    Kenneth,

    This behavior is basic XDoclet functionality and seems related to this known bug in XDoclet:
    http://opensource.atlassian.com/projects/xdoclet/secure/ViewIssue.jspa?key=XDT-736

    –Scott
    MyEclipse Support

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: Bug in XDoclet EJB Util Class generation

You must be logged in to post in the forum log in