facebook

Importing a Struts application

💡
Our Forums Have Moved

For help with installation, bugs reports or feature requests, please head over to our new forums.
Genuitec Community on GitHub

  1. MyEclipse IDE
  2.  > 
  3. General Development
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #212010 Reply

    Amir Kader
    Member

    Hi,
    I’m new to my eclipse and am trying to import a struts application that I have as a WAR file into a my eclipse project. The problem I’m having is I don’t have the source code for the classes of WAR project and when I configure my project to add those classes to the buidpath through a classes folder, those packages still don’t resolve in the IDE?

    Is there some place specific I need to place the compiled classes?

    Thanks

    #212014

    Riyad Kalla
    Member

    Can you please post all the information we request in the [URL=http://www.myeclipseide.com/PNphpBB2+file-viewtopic-t-393.html]Posting Guidelines[/URL] thread at the top of this forum? That will give us some context so that we can determine if this is an installation issue, a configuration problem, or a bug. Thanks.

    Also please provide the structure of the exploded WAR file… where the classes dir is, what your output dir is set to, what libraries are needed, etc.

    MyEclipse will typically set your default Output path to WebRoot/WEB-INF/classes, and if this is the ONLY location of your files (since you have no source) then its likely that Eclipse cleared the directory when it “cleaned” the output folder before rebuilding the project… so your problem might eb that the class files got deleted.

    #212015

    Amir Kader
    Member

    Sure..
    Windows XP
    Eclipse 3.0
    MyEclipse 3.7.2

    The exploded WAR:
    scscis2
    +ui
    +WEB-INF
    +classes
    + com…
    +resources
    +lib
    +tlds

    the output directory for the project: scscis2/WebRoot/WEB-INF/classes

    but I created a classes2 directory as an classes library folder and placed imported all the classes\packages to it. But when I open up certain jsps in the IDE I get the error marker that ‘can not load class com.stellent.*’

    Since the classes2 directory is now part of the classpath, shouldn’t those classes be resolved?

    Thanks for the help.

    #212020

    Riyad Kalla
    Member

    I couldn’t tell from your tree what the hierarchy for this project was, is WEB-INF directly under the root of this project or is it under the “ui” folder? We will need to get this project imported as a valid project before resolution and completion will work correct.

    If WEB-INF *is* in the root of your project, then that is a feature (having the webroot == your project root) that is not the version of MyEclipse you are running but IS in the 3.8 GA release that we are hoping to release any day now. So let me know what the setup is so we can figure out what would work best here.

    #212028

    Amir Kader
    Member

    Sorry about that. I should have previewed the message. So this is the exploded WAR directory structure.

    /scscis
    —-/ui/*
    —-/WEB-INF
    ——–/classes
    ————/com/*
    ————/resources/application.properties
    ——–/lib
    ——–/tlds

    #212032

    Riyad Kalla
    Member

    Ahh… then set your “Web root” to be “/ui” and and your “/ui/WEB-INF/classes” directory to your class path and don’t set an output dir for the project… if Eclipse requires you to, set it to something random like /bin… don’t set it to your classes dir because Eclipse may “Clean” that directory before a build and erase your class files… and since you dont’ have source for them, that could prove to be a PIA.

Viewing 6 posts - 1 through 6 (of 6 total)
Reply To: Importing a Struts application

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