Showing posts with label eclipse. Show all posts
Showing posts with label eclipse. Show all posts

Monday, February 6, 2012

force eclipse to recognize war maven projects

run maven command
mvn -Dwtpversion=2.0 compile eclipse:eclipse

then refresh the project

Friday, August 22, 2008

linking pojo projects into a gwt project in eclipse

1. export the pojo project as a jar file. make sure the source code is included
2. import the jar file into the gwt project as an external jar

Tuesday, January 8, 2008

organize eclipse project folders

organize a project's source folders in such a way that:

  1. all source files are stored in the src folder
  2. all configuration files such as xml, properties, and conf files are stored in the conf folder
  3. all compiled classes are put in the bin folder
  4. exported jar file(s) are stored in the dist folder
  5. project specific configuration files (i.e. .jardesc, manifest.mf) are stored in the etc folder


==========
  1. right click Package Explorer and select New>Create a New Project
  2. select Java Project and click Next
  3. specify the project's name and make sure Create separate source and output folders is selected in the Project Layout panel
  4. click Next
  5. click the Create new source folder link and create the src and conf folders
  6. click Finish
  7. right click the project name and add the bin, dist, etc folders
  8. create a new manifest file in the etc folder and name it manifest.mf
  9. make sure ". conf" is part of the Class-path so that configuration files stored in it can be accessed by your classes

easily share eclipse user libraries (windows)

Use when:
1. working on a project on more that two computers (ie. work and home pc)
2. working on multiple projects that share common libraries
3. projects need to be easily passed around with minimal configuration
4. multiple developers are working on single project



========

  1. store all java libraries on a single folder. make sure each library is in its own folder.
  2. create a network share on this folder, and have it mapped to J: drive. if multiple machines are going to access the same set of libraries, have one of them act as a repository for the libraries and have the others map J: drive to it.
  3. in eclipse, goto Window>Preferences>Java>Build Path>User Libraries and create User Libraries for each entry in J:. no need to run steps 3-6 on all machines.
  4. click Export.
  5. click Select All and specify a filename for the .userlibraries file.
  6. click OK to export and save your settings.
  7. copy and distribute the .userlibraries file to all the other machines.
  8. in their User Libraries window, click Import and look for the copied .userlibraries file.
  9. click OK and save your settings.