Android eclipse之plugins

本文详细介绍了Eclipse插件的三种安装方法:直接复制法、links安装法和使用图形界面的插件安装方法。同时提供了插件安装后的检查步骤,并列举了多个常见插件的安装示例。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

写在最前面之eclipse插件安装方法

http://sunshineyao.iteye.com/blog/731445

  ^_^ ^_^火来惭愧,用eclipse快两年了都不曾知道如何安装插件(以前都是使用的MyEclipse,它自动继承了web相关的插件)。前天晚上阅读了《卓有成效的程序员》,书中提到了使用快捷键的意义,其实之前自己也意识到了快捷键的价值但只会常用的几个,此书中提到了promtper key插件,于是上网下载了一个,结果尴尬的是不会使用, 因此学习了一下插件的安装法。 
    插件的安装方法大体有以下三种: 

  第一种:直接复制法:假设你的Eclipse的在(C:\eclipse), 解压你下载的 eclipse 插件或者安装eclipse 插件到指定目录AA(c:\AA)文件夹,打开AA 文件夹,在AA文件夹里分别包含两个文件夹features和plugins ,然后把两个文件夹里的文件分别复制到eclipse下所对应的文件夹下的features 和plugins 下,一般的把插件文件直接复制 到eclipse目录里是最直接也是最愚蠢的一种方法!因为日后想要删除这些插件会非常的困难!强列的不推荐使用!! 

注意:直接将 插件包解压到plugins文件夹下之后,重启eclipse,可能不会加载新的插件。 

  解决方法是: 
  1、打开命令行,到当前eclipse的目录下,输入eclipse -clean,重新启动eclipse,这样eclipse就会加上新的插件了。 
  2、如果插件不能升效,则请将eclipse\configuration\org.eclipse.update目录删除后再启动eclipse:) 

 你可以在eclipse的菜单"Help"-->"About Eclipse SDK"-->"Feature Details" 和"Plug-in Details"中看到新安装的插件。 


  第二种(我使用的是此种方式): 
   下载下来的插件可能有这几种形式: 

一是单独的jar文件,二是plugins和features两个文件夹,三是一个单独的eclipse文 

件夹。 

links安装方法:(强推) 

1,准备工作 

如果插件是一个单独的jar文件,那么你需要做三件事, 

先建一个plugins文件夹,把jar文件放入其中, 

再建一个eclipse文件夹,把plugins放入其中, 

最后,打个比方:如果你下载的是一个名为WBPro的插件,你需要建一个WBPro文件夹 

,把刚才的eclipse文件夹放入其中。(不一定非得命名为WBPro,你可以用其他名字, 

如AAA,bb等,注:此句话可先不看)。好了,插件的大致结构出来了,如下 

WBPro/eclipse /plugins/**.jar 


如果插件是plugins和features两个文件夹(或只有plugins文件夹), 

请建一个名为eclipse的文件夹,把上面的两个文件夹放入其中, 

再建一个名为WBPro的文件夹,把刚才的eclipse文件夹放入其中,插件的大致结构如 

下:WBPro/eclipse /{plugins,features}如果插件就是一个eclipse文件夹,请新建 

一个WBPro文件夹,把eclipse放入其中,插件的结构如下:WBPro/eclipse 


2,开始安装 

找到你的eclipse ,在其下建两个文件夹,一个是extplugins,一个是links,结构如 

下{eclipse/extplugins,links}, 

把你刚才建立的插件WBPro放入extplugins中, 

然后在links文件夹下,建立一个txt文本,在里面写入:path=extplugins/WBPro,注 

意是“/”,而不是“\”,再把文本文件命名为WBPro.link,注意全名是WBPro.link, 

而不是WBPro.link.txt, 

好了,启动eclipse,在菜单栏点击window->Preferences,在弹出来的对话框中,看左 

边的导航栏,如果里面有你的插件名,如WBPro,恭喜你插件安装成功! 

  第三种: 

  第三种:使用eclipse自带的图形界面的插件安装方法:选择Help > Software Updates > Manager Configuration 
在选择Add > Extension Location 找到你要安装插件的目录就可以了。 
    如果用第3种方法,在eclipse这个目录下必须有文件.eclipseextension,如果你下的插件没有这个文件, 
那就随便eclipse安装目录下的那个文件靠过去就行了!只有有这么个文件就可以了,内容没什么用,主要是一些版本信息!例如: 

id=org.eclipse.platform name=Eclipse Platform 
version=3.1.1 


——————————————插件管理———————————————————— 
   启动eclipse,在菜单Help->Software Updates->Manage Configuration…下,启用或 

者禁用插件。 
三、其它补充: 

1. 插件可以分别安装在多个自定义的目录中。 

2. 一个自定义目录可以安装多个插件。 

3. link文件的文件名及扩展名可以取任意名称,比如RSE.txt,myplugin都可以。 

4. link文件中path=插件目录的path路径分隔要用\\或是/ 

5. link文件可以有多行path=插件目录,对应多个自定义插件目录,每一行的path参 

数都将生效。 

6. 在links目录也可以有多个link文件,每个link文件中的path参数都将生效。 

7. 插件目录可以使用相对路径。 

8. 可以在links目录中建立一个子目录,转移暂时不用的插件到此子目录中,加快 

eclipse启动。 

9. 如果安装后看不到插件,把eclipse安装目录下的 

configuration/org.eclipse.update/目录整个删除,重启eclipse。 

================================================================================================

1.green插件

安装GMF

--采用links方式安装

--http://www.eclipse.org/modeling/gmp/ 下载适合的SDK


安装EMF

--links方式安装

--http://www.eclipse.org/modeling/emf/downloads/?project=emf 下载适合的SDK


安装GEF

--links方式安装

--http://www.eclipse.org/gef/downloads/index.php 下载适合的SDK


安装Green UML

--links方式安装

--http://sourceforge.net/projects/green/files/green/ 注意要下适合的版本!


2.Android Sources Plugins--android源码的插件

http://code.google.com/p/adt-addons/

通过eclipse自身安装

Android Sources

This plugin helps you to add source to android libraries in Eclipse.

In ADT >=8.0.0 you can add Android sources to Android container for all your project with installing the Android source feature using http://adt-addons.googlecode.com/svn/trunk/source/com.android.ide.eclipse.source.update/ update site After installing the Android source feature all your existing projects as well as new created projects which is targeted for Android 4.0.1, 2.3.4, 2.3, 2.2, 2.1, 2.0.1, 1.6 and 1.5 will have attached the source jar.

The plugin includes sources for the following API levels:

    • 14 - Android 4.0.1
    • 10 - Android 2.3.4
    • 9 - Android 2.3
    • 8 - Android 2.2
    • 7 - Android 2.1
    • 6 - Android 2.0.1
    • 4 - Android 1.6
    • 3 - Android 1.5

The plugin is about 240 MB size.


API Analysis plugin

API Analysis plugin try to solve the issue described at http://code.google.com/p/android/issues/detail?id=13905 - ADT: Show warnings when using high-level API and a lower minSdkVersion than the targetSdkVersion.

It work on the following way:

- there is a compilation participant that compile an Android project yet another, but use android.jar from the minSdkVersion SDK instead of from target SDK. If errors exist they are converted to warning as : "API Level "minSdkVersion" compatibility problem (<original error>)". The user can select to ignore these errors, show warning (default) or show error.

The compilation participant won't be executed in the following case:

    • a project isn't Android project
    • there isn't minSdkVersion declaration in the android manifest
    • minSdkVersion >= target version
    • there isn't minSdkVersion target within Android SDK
    • there are errors in the project. It isn't trivial to separate compatibility problems from other errors. IMO, this check is important when the application work correctly on target platform. However, it's possible change this behavior
    • property page is set to Ignore

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值