Menu

#6 Java 5 compliance

open
nobody
None
5
2009-12-01
2009-12-01
No

Hi there,

I have system env with only java 5 (6 is not allowed). The dita2wiki tool unfortunately has some very few/trivial java 6 code (like 7 lines in total), related with the String.isEmpty() function that could be easily replaced to an equivalent that complies to Java 5.

Would it be possible to make it java 5 compliant?

thanks,
Igor

Discussion

  • Lisa Dyer

    Lisa Dyer - 2009-12-02

    Hi Igor,

    The next release is being planned, and I'll put this issue in queue, but we're not sure about timing. DITA2Confluence 1.2.2 is just out, so it'll be some months until the next release.

    If you are inclined to submit those code changes to the project, well that would be most welcome, and we could get a patch out quicker:) Any chance of that?

    - lisa

     
  • Igor Jacy Lino Campista

    Hi Lisa

    Yeah sure. The code changes I have done locally, so they are done. How to do I submit code changes?

    -Igor

     
  • Lisa Dyer

    Lisa Dyer - 2009-12-09

    Hi Igor,

    I think it's easiest if you email your diffs to me (since we haven't yet worked out the process fully in the SourceForge SVN). Would this work for you? lisa dot dyer at lombardi dot com. We will then integrate in our env and then promote to SourceForge, either as a patch or 1.2.3 GA.

    Thanks!

    - lisa

     
  • Igor Jacy Lino Campista

    Patched files that compile in Java 5 (replaced a String.isEmpty() to equivalent))

     
  • Igor Jacy Lino Campista

    Hi Lisa,

    I have attached the files that I modified with the latest release you did some days ago.

    The error messages I corrected are:

    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] this.modules = listOfModules.equals("${modules}") || listOfModules.isEmpty() ?
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\AntTask.java:162: cannot find symbol
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] if (modules != null && !modules.isEmpty()) {
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\ConfluenceConfig.java:308: cannot find symbol
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] || configFilename.isEmpty())) {
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\ConfluenceConfig.java:328: cannot find symbol
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] || contentFilename.isEmpty())) {
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\ConfluenceConfig.java:437: cannot find symbol
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] if (!contentModule.getAttribute("ditaval").isEmpty()) {
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\ConfluenceConfig.java:489: cannot find symbol
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] if (!labelsAsString.isEmpty()) {
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\ConfluenceHelper.java:321: cannot find symbol
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] if(!newCommentContent.isEmpty()){
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\DitaBookProcessor.java:101: cannot find symbo
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] && !config.getDitavalFile().isEmpty()) {
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\DitaBookProcessor.java:288: cannot find symbo
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] spaceName = spaceName.isEmpty() ? guideSpaceKey : spaceName;
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\DitaMapProcessor.java:155: cannot find symbol
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] if (!config.getSpaceHomePage().isEmpty()) {
    [javac] ^
    [javac] C:\dita2confluence1.2.2.source-original\src\com\lombardisoftware\confluence\dita2confluence\DitaMapProcessor.java:161: cannot find symbol
    [javac] symbol : method isEmpty()
    [javac] location: class java.lang.String
    [javac] if (!config.getParentPageTitle().isEmpty()) {
    [javac] ^

     
  • Lisa Dyer

    Lisa Dyer - 2009-12-11

    Sweet, thank you!! Will take this into testing soon, and then update this thread with the release plan (probably a patch).

    Cheers,

    - lisa

     
  • Igor Jacy Lino Campista

    Hi Lisa,

    Wondering if there is any release plan in the coming future?

    Thanks,
    Igor

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.