Running TConnect sample in eclipse

6 views
Skip to first unread message

fla...@gmail.com

unread,
Sep 12, 2006, 11:46:07 AM9/12/06
to IBM Content Manager
I previously opened the thread about using eclipse / tomcat with CM
APIs. This is still my ultimate goal and will push towards that. For
now I'm taking a big step back for simplicity.

I'm trying to get the IBM Sample program TConnect to work inside
eclipse.

I am using the latest Callisto build of eclipse 3.2

can be downloaded from here:

http://www-128.ibm.com/developerworks/eclipse/downloads/?S_TACT=105AGX44&S_CMP=CALLISTO

Any 3.2 build of eclipse should work fine though.

Anyway - i created a new java project and dropped TConnect in there. I
added the CM API jars to the build path and it was compiling OK.

Now here's the tricky part - CM APIs require access to "C:\Program
Files\IBM\CMGMT"

You can't add a folder as an external Jar to eclipse. So here's what I
did.

I switched to resource perspective and manually hacked the ".classpath"
file to add the folder as a lib entry.

<classpathentry kind="lib" path="C:/Program Files/IBM/Cmgmt"/>

This worked. I can run TConnect without error. However - eclipse
won't create any new builds.

I get this in the "Problems" pane:

"Required library cannot denote external folder: 'C:\Program
Files\ibm\CMgmt' for project TConnect"

The question is:

What is the correct way to tell eclipse about the cmgmt folder?

After I know this I think I'm set for developing CM apps in eclipse.

fla...@gmail.com

unread,
Sep 12, 2006, 1:45:54 PM9/12/06
to IBM Content Manager
Some updates:

**
I also tried running TConnect in the NetBeans 5.0 environment. I had
success with this. NetBeans allows you to add a folder right to your
project.

I was able to get TConnect working in short order. This is a testament
to NetBeans since I have not written a single program in that
environment and I've written many in eclipse - yet I could get TConnect
working in NetBeans and not eclipse!

This is nice, but our company is switching to eclipse development, not
NetBeans.

If anyone has insight on setting up the CMgmt folder in an eclipse
project that would be helpful!

**
For those who may not know - the TConnect sample is available to you if
you install EIP / II4C development workstation. I can be located in
your CMBROOT/Samples/java/beans directory
**

Another thing I tried is zipping up the CMgmt directory and adding it
to eclipse as a zip file. It allowed me to add the zip file but the
java application errored out because it couldn't locate the ini file.

fla...@gmail.com

unread,
Sep 12, 2006, 1:54:25 PM9/12/06
to IBM Content Manager
Another update.

I tried zipping up just the .ini and .properties files from within
CMgmt (Not zipping the folder itself)

I then added the zip file to the project as an external jar and this
worked.

So - this is one workaround that can be used. If anyone else comes up
with a better way post back here

Thanks!

Reply all
Reply to author
Forward
0 new messages