[jbossseam-issues] [JBoss JIRA] Updated: (JBSEAM-1514) seam-gen should normalize project name

Dan Allen (JIRA) jira-events at lists.jboss.org
Wed Jun 20 16:02:51 EDT 2007


     [ http://jira.jboss.com/jira/browse/JBSEAM-1514?page=all ]

Dan Allen updated JBSEAM-1514:
------------------------------

    Attachment: NormalizeProjectNameTask-v1.java

NormalizeProjectNameTask-v1.java must be moved to src/gen/org/jboss/seam/tool/NormalizeProjectNameTask.java  This file is the ant task for filtering the project name.  Right now it just replaces spaces and hyphens with underscore characters, but the hope is that it becomes a more advanced filter in the future.

> seam-gen should normalize project name
> --------------------------------------
>
>                 Key: JBSEAM-1514
>                 URL: http://jira.jboss.com/jira/browse/JBSEAM-1514
>             Project: JBoss Seam
>          Issue Type: Patch
>          Components: Tools
>    Affects Versions: 1.3.0.ALPHA
>         Environment: Java HotSpot(TM) Server VM (build 1.5.0_12-b04, mixed mode)
> seam CVS HEAD
>            Reporter: Dan Allen
>         Attachments: JBSEAM-1514-build_xml-v1.patch, NormalizeProjectNameTask-v1.java
>
>   Original Estimate: 15 minutes
>  Remaining Estimate: 15 minutes
>
> seam-gen uses the name of the project in a lot of (dangerous) places when generating the code and configurations.  If a project created with seam-gen is going to work correctly, this name must have "safe" characters (safe for JNDI, safe for value binding expressions, etc).  Currently, if the person using seam-gen enters a space character or a hyphen in the name (two very standard use cases), then the resulting project will not work correctly.
> I have provided a patch that will normalize this name.  It is implemented as an Ant task that filters the name for spaces and hyphens and replaces them with underscores.  It then does a second pass to eliminate duplicate underscore characters.  Granted, doing this filtering will not honor the exact name for the project that the user provides, but then again, what is the use if the project is broken.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the seam-issues mailing list