[OS-JIRA] Created: (CAY-140) Add "import" to subclass generation

From: jir..bjectstyle.org
Date: Tue Jun 08 2004 - 17:47:46 EDT

  • Next message: jir..bjectstyle.org: "[OS-JIRA] Created: (CAY-141) ProcedureQuery must support all GenericSelectQuery features."

    Message:

      A new issue has been created in JIRA.

    ---------------------------------------------------------------------
    View the issue:

      http://objectstyle.org/jira/secure/ViewIssue.jspa?key=CAY-140

    Here is an overview of the issue:
    ---------------------------------------------------------------------
            Key: CAY-140
        Summary: Add "import" to subclass generation
           Type: Improvement

         Status: Assigned
       Priority: Major

        Project: Cayenne
     Components:
                 CayenneModeler GUI
       Versions:
                 1.0 [STABLE]
                 1.1 [DEV]

       Assignee: Andrus Adamchik
       Reporter: Michael Gentry

        Created: Tue, 8 Jun 2004 5:46 PM
        Updated: Tue, 8 Jun 2004 5:46 PM

    Description:
    To aid readability on smaller screens (especially laptops), perhaps the subclasses could be generated something like:

    -------->8 cut here 8<--------
    package com.foobar.organization.application;

    import com.foobar.organization.application.auto.MyDandyNewEntity;

    public class MyDandyNewEntity extends _MyDandyNewEntity
    {
    ...
    }
    -------->8 cut here 8<--------

    Instead of:

    -------->8 cut here 8<--------
    package com.foobar.organization.application;

    public class MyDandyNewEntity extends com.foobar.organization.application.auto._MyDandyNewEntity
    {
    ...
    }
    -------->8 cut here 8<--------

    (Note, the "public class" line wraps here, but it's much longer than the first one.) I know this is minor (and should be easy to change), but it looks much nicer on a small screen and doesn't require horizontal scrolling. Plus, to me, it's very obvious that all the superclasses start with an "_" in the first one.

    Thanks,

    /dev/mrg

    PS. Here is my guess for the change (haven't tested it):

    #if( ${classGen.isUsingPackage()} )
    package ${classGen.packageName};
    #end

    #if( ${classGen.isUsingSuperPackage()} )
    import ${classGen.superPackageName};
    #end

    public class ${classGen.className} extends ${classGen.superPrefix}${classGen.className}
    {

    }

    PS. Yes, I could make a custom template, but this seems easy enough to change for everyone.

    ---------------------------------------------------------------------
    JIRA INFORMATION:
    This message is automatically generated by JIRA.

    If you think it was sent incorrectly contact one of the administrators:
       http://objectstyle.org/jira/secure/Administrators.jspa

    If you want more information on JIRA, or have a bug to report see:
       http://www.atlassian.com/software/jira



    This archive was generated by hypermail 2.0.0 : Tue Jun 08 2004 - 17:47:47 EDT