Announcement Announcement Module
No announcement yet.
compile problem indicator Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • compile problem indicator


    My Spring config files show a compilation problem icon at the line <beans>:

    <?xml version="1.0" encoding="UTF-8" ?>
    <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "">
    - Application context definition for "webapp" DispatcherServlet.

    Hovering over the icon I get the message: Unexpected element "{}beans" {}beans. The code colouring is broken too.

    I don't understand why, and didn't notice when it happened. My app compiles and runs OK.

    The same icon also appears at the root of my app. If I introduce an error into my code, the error is clearly indicated in the source file, but it is no longer appears in the package explorer.

    Any suggestions easier than a fresh install of everything??


    John Pedersen

    Eclipse 3.1, Spring 1.2.6, Spring IDE 1.2.4

  • #2
    fresh install of eclipse 3.1.1 - no difference!


    • #3
      Could it be that eclipse interprets your spring configuration file as an ant build file?
      Perhaps you might check the file associations in your preferences to ensure that you open the file with the right editor.



      • #4
        Thanks Andreas - I am sure you have hit the nail on the head there - but how do I get it working again?

        I have messed about with the settings in File Preferences. I have tried removing *.xml, and then adding it again, but as soon as I add it, I get this list of associated editors:

        Text Editor (locked by 'XML' content type) (locked by 'Ant buildfile' content type)
        Ant Editor (locked by 'Ant buildfile' content type)

        Can't seem to unlock it...


        • #5
          I am no expert here. I can just say that I also have these "locked" informations. So it might be normal.
          Maybe you can try to set the default editor to <insert your xml editor here> in the "File Associations" tab.



          • #6
            Tried fiddling with the default editor settings - it didn't help.

            I tried removing *.xml from File associations, and then removing Spring Project Nature. Added *.xml, and then added Spring Project Nature again.

            Things have changed a little - I still get the compile problem icon at the project root. Syntax highlighting has now gone completely. The 'S' icon is correctly placed on the file files listed in Package Explorer, so the Spring IDE is working to some extent. I have warning symbols beside some property declarations which refer to beans in another xml file (I checked that file is still part of the Spring config)

            Ugh - a mess!


            • #7
              If not too complex, I think it would help to create a new workspace.
              All settings (preferences) would then have their default values again.



              • #8
                New workspace - that is what I had to do in the end.

                Ah well, tied it in with some overdue reorganising.

                Thanks for the help.