How to get shark into eclipse

Hi,

this mail is in reply to "UML diagram of Shark Java source code (classes)" but I thougth it should open a new thread because it has nothing to do with UML.


Here comes what I did to get shark into eclipse.


It is in fact fairly simple thanks to the smartness of eclipse.


Create a directory for your project. Lets call it "shark-cvs-20050408"


You may of course choose different names.


Create sub directories "source", "classes"


Put shark sources into the source directory (I checked it out from CVS)


You now have a directory structure like this:


shark-cvs-20050408
+- classes
+- source
    +- CVS
    +- CVSROOT
    +- Shark
        +- modules
            :
        +- lib
            :
        +- util
            :
        :

Build shark without eclipse. This is necessary to get the DODS source files created. (You may get into the details of sharks build mechanism and just create the DODS stuff and nothing else)

Move the "shark-cvs-20050408/source/Shark/output" folder out of the way, i.e. somewhere above shark-cvs-20050408. That will save you a lot of klicking.


Now with eclipse:


Create a new Java Project.


In the "Create a Java project" window:
--------------------------------------


Project name: shark-cvs-20050408


,-Location-...
|
| [ ] Create ...
|
| [x] Create project at external location
|
| Directory: /home/.../shark-cvs-20050408
:


Klick "Next >" button


Eclipse automatically detects the source files.

In the "Java Settings" window:
------------------------------


At the bottom edit the entry for "Default output folder":


"Default output folder":
/shark-cvs-20050408/classes


In the "Source" tab of the same window:
---------------------------------------

Remove all entries ending with "Hibernate/src" unless you are willing to use hibernate.


*Be carefull to get them all.*

If you are willing to use hibernate you will later have to add some hibernate jars to your build path.


In the "Order and Export" tab of the same window:
-------------------------------------------------

Press the "Select All" button. (You may have to klick on an entry first, seems to be a bug in eclipse)


If you think all entries are already selected scroll down to be sure.


Klick the "Finish" button at the bottom.


Move the "output" folder back into its original location.

You're done and your newly created project should not be marked red (just orange).


Note that all the class files are now in the classes subdir. If you run the server from inside eclipse just add the project to the run time classpath.

If you want to put the class files into their jars you may want to add an ant builder under Project->Properties->Builders.

For my tool agent implementations I created a new project in a different location.


Regards Dirk


Vojtech Huser wrote:


I need to dig into Shark Admin and Engine code and JaWE code.
Is there anywhere in documentation an UML diagram of how the Java Classes play together ?
What classes I should look at first ?
The same I need for JaWE.
How best should I import everything in Eclipse so that it compiles ?
Has anyone uses Omondo plugin (for Eclipse) on the src so that it creates one ?
Vojtech

转贴地址:http://mail-archive.objectweb.org/shark/2005-04/msg00066.html
注:利用这种方法把Shark导入到Eclipse后,SharkEJB部分仍然有错,具体原因正在找资料解决;有解决了
如何把Shark导入到Eclipse中的问题的大虾们请多多指教,期待中......

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值