Wiki source code of Add a Jar Dependency

Version 9.1 by Pascal Robert on 2010/10/03 00:50

Show last authors
1 You'll often need to work with 3rd party Jars, as well as your own reusable code.
2
3 Adding these to your project is very simple.
4
5 1. By default WOLips will create a {{code language="none"}}Libraries{{/code}} folder in your project directory. Populate this with any jars you like.
6 1. In Eclipse, right-click (or ctrl-click) on the jar and choose {{code language="none"}}Build Path > Add to Build Path{{/code}}. This simply adjusts your project classpath but doesn't affect your final build.
7 1. For frameworks, you should turn on the Export checkbox in the build path window as hown below in Fig. 1. Doing so ensures that other WebObjects projects the reference the framework "see" the jar library in their Eclipse build path.
8
9 {{info title="Fig. 1 Export jars when in a framework"}}
10 [[image:attach:Picture 11.jpg]]
11 {{/info}}