![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
plugin开发
文章平均质量分 68
驽马一架
兴之所至
展开
-
blog220217.Eclipse JFace之Viewer
blog220217.Eclipse JFace之Viewer缘起Viewer的主要类Viewer classContentViewer classIContentProvider和ILabelProviderStructuredViewer, AbstractListViewer, AbstractTableViewer和AbstractTreeViewer classViewer的listeners本文以eclipse 4.20为参考.缘起Jface viewer是对SWT widget的封装.原创 2022-02-18 08:30:12 · 436 阅读 · 0 评论 -
blog220203.Eclipse runtime之Job
blog220203.Eclipse runtime之Job缘起JobJobManagerIScheduleRulingIProgressMonitorIRunnableContext与IRunnableWithProgressIProgressServicejob的progressMonitor本文以eclipse 4.20为参考.缘起org.eclipse.core.runtime.jobs.Job代表的是runnable work. Job构造后, 申请进入调度以执行, 由jobManager负原创 2022-02-07 16:35:22 · 278 阅读 · 0 评论 -
blog220126.Eclipse workbench之service
blog220126.Eclipse workbench之service缘起ServiceLocator与e4Context的关系注册service获取serviceextP="org.eclipse.ui.services"本文以eclipse 4.20为参考.缘起org.eclipse.ui.workbench提供了自己的service机制, 本文称作workbench service, 简称service.注意区别于osgi service和e4context service.workben原创 2022-01-26 09:32:44 · 158 阅读 · 0 评论 -
blog220123.Eclipse ui之command, handler, menu, 和binding的extPoints
blog220123.Eclipse ui之command, handler, menu, 和binding的extPointsCommands, extP="org.eclipse.ui.commands"Handlers, extP="org.eclipse.ui.handlers",Bindings, extP="org.eclipse.ui.bindings"Menus, extP="org.eclipse.ui.menus"本文以eclipse 4.20为参考.使用extension poin原创 2022-01-23 12:16:04 · 499 阅读 · 0 评论 -
blog220122.Eclipse bundle之MANIFEST headers
blog220122.Eclipse bundle之MANIFEST headersManifest-Version: 1.0Bundle-ManifestVersion: 2Bundle-Name: FirewallBundle-SymbolicName: org.eclipse.ui.examples.contributions; singleton:=trueBundle-Version: 3.5.0.qualifierBundle-Activator: com.example.ActivatorRe原创 2022-01-22 10:32:37 · 258 阅读 · 0 评论 -
blog220120.Eclipse osgi之service
blog220120.Eclipse osgi之service缘起主要接口和类BundleBundleContextServiceRegistrationServiceReferenceServiceObjectsService的两种注册方式编程方式DS方式annotation方式Client使用Service的3种方式直接使用BundleContext和ServiceListener使用ServiceTracker使用ServiceCaller本文以eclipse 4.20为参考.缘起OSGi中的s原创 2022-01-20 11:49:03 · 376 阅读 · 0 评论 -
blog220119.Eclipse之minimal OSGi runtime配置
blog220119.Eclipse之minimal OSGi runtime配置Env: eclipse 4.20Included plugins:org.eclipse.osgiorg.eclipse.osgi.utilorg.eclipse.osgi.servicesorg.eclipse.equinox.consoleorg.apache.felix.gogo.shellorg.apache.felix.gogo.runtimeorg.apache.felix.gogo.comm原创 2022-01-19 20:25:41 · 310 阅读 · 0 评论 -
blog220103. Eclipse text之document的分块partitioning
blog220103. Eclipse text之document的分块partitioningIDocument的分块partitioning分割者partitioner扩展点extensionPoint "org.eclipse.core.filebuffers.documentSetup"token扫描器 tokenScannerDocument创建的大致流程IDocument的分块partitioningIDocument支持将整个文档分割成不重叠的子块partition. 块partition原创 2022-01-03 19:21:28 · 126 阅读 · 0 评论 -
blog211231. Eclipse framework之workbench框架
blog211231. Eclipse framework之workbench框架workbench框架的组成workbench框架的主要接口赘述workbench框架的组成Eclipse framework中的workbench框架由多个实体组成.workbench, 代表的是eclipse的整个环境.workbenchWindow, workbench由一个或多个workbenchWindow组成, 通常是一个. workbenchWindow对应的是topLevel window.work原创 2021-12-31 23:26:44 · 387 阅读 · 0 评论 -
blog211218. Eclipse text之StyledText, TextViewer和SourceViewer概述
blog211218. Eclipse text之StyledText, TextViewer和SourceViewer概述StyledTextTextViewerSourceViewerStyledText, TextViewer和SourceViewer是Eclipse text实现文本编辑功能的基础类. 熟悉这三个类是了解eclipse text机理的第一步.StyledText是SWT ui widget, TextViewer是对StyledText的封装, SourceViewer是进一步的原创 2021-12-18 18:25:17 · 314 阅读 · 0 评论 -
blog211215. Eclipse text之文档IDocument和投影文档projectionDocument
blog211215. Eclipse text之文档IDocument和投影文档projectionDocument文档IDocument投影文档projectionDocumentEclipse text用将文本抽象为IDocument接口. 而TextViewer中引入了visibleDocument的实现, 需要投影文档的支持文档IDocumentIDocument接口将文档抽象为以下功能,一个连续文本text, 可以使用offset和length读写其中片段.可以接入documentL原创 2021-12-15 20:04:45 · 135 阅读 · 0 评论 -
blog211210. JFace之Window
blog211210. JFace之WindowWindowApplicationWindowWindow相关的class和interfaceWindowJFace的Window是对Shell的封装, 便利使用. 封装的内容包括,shell. 可以用getShell()得到.default exception handlerfont change listener初始定位和大小的设置. 默认的定位是屏幕居中, 尺寸是缺省值.layout的设置, 默认是gridLayout可选的event原创 2021-12-10 15:49:21 · 219 阅读 · 0 评论 -
blog211121. SWT之Display, 消息循环, asyncExec,和syncExec
blog211121. SWT之Display, 消息循环, asyncExec,和syncExecDisplay消息循环asyncExec()和syncExec()SWT使用单一UI thread的UI事件实现模型. UI操作只能在UI thread中调用, 这包括绝大多数的widget及其派生类的方法.创建Display的线程就是UI thread, 这通常就是主线程.Display是SWT与OS打交道的中介. 提供了对os的消息队列的收发, 以及对一些显示相关信息的获取.DisplayDis原创 2021-11-21 12:36:23 · 477 阅读 · 0 评论 -
blog211119. SWT之DnD
blog211119. SWT之DnDDnD过程DragSourceListenerDropTargetListener典型代码DnD过程Drag and Drop操作用可视化的完成两个widget之间data的传递. 发起方称作drag source, 接收方称作drop target.一个典型的DnD操作包括,在drag source widget上点压鼠标左键,拖拽鼠标, 即不放开鼠标键的同时, 向drag target移动,移动到drop target widget上释放鼠标键.1原创 2021-11-19 08:35:54 · 142 阅读 · 0 评论 -
blog211003. Eclipse之调整窗口布局的拖拽DnD
blog211003. Eclipse之调整窗口布局的拖拽DnD调整操作的种类调整的灵活性本文以eclipse 4.20为参考.Eclipse中为了高效使用屏幕, 允许灵活的摆放多个窗口同时展示. 其基本的思路是多个part(view或editor)放到partStack(trimBar)中, 一个partStack占据一个partSashContainer窗口, partSashContainer窗口允许水平分割或垂直分割进行嵌套.这样的架构提供了灵活调整窗口布局的能力.调整操作的种类窗口布局的原创 2021-10-03 09:03:46 · 426 阅读 · 0 评论 -
2021-09-04, Eclipse之EclipseContext的lazy compute, 延迟计算
blog210904. Eclipse之EclipseContext的lazy compute, 延迟计算Lazy computeIContextFunctionLazy compute的实现本文以eclipse 4.20为参考.Lazy computeEclipseContext实现了IEclipseContext接口. 其主要的作用是将application与container隔离开来.其基本使用方法是container将值set写入EclipseContext, application读取ge原创 2021-09-04 18:50:43 · 157 阅读 · 0 评论 -
2021-8-6. Eclipse framework之ServiceCaller
Eclipse framework之ServiceCallerServiceCaller的使用ServiceCaller的实现本文以eclipse 4.20为参考.ServiceCaller是不同于ServiceTracker的另一个方便使用service的类.ServiceCaller的使用ServiceCaller的使用较简单,*.生成serviceCaller, 构造中指定callerClass, serviceClass, 和filter.*.需要取得serviceObj时, 直接调用原创 2021-08-06 21:10:05 · 142 阅读 · 0 评论 -
2021-8-4. Eclipse framework之service tracker
Eclipse framework之service tracker指定要跟踪的serviceReference关于tracked objectopen和close本文以eclipse 4.20为参考.serviceTracker相较于serviceListener更方便使用, 从功能上说, 它实际上是 serviceListener + filter.指定要跟踪的serviceReferenceserviceTracker的构造有3种形式, 可以根据需要选择.关注特定serviceReferen原创 2021-08-04 16:24:56 · 93 阅读 · 0 评论 -
2021-07-23. osgi core的关键interface和class
osgi core的关键interface和class本文以osgi core release 8为参考.osgi core提供的interface和class构成了osgi的基本框架.下图是关键interface和class的情形.<osgi_core.png>一图胜千言, 尽在意会间.一花一世界 2021/7/23...原创 2021-07-23 19:00:44 · 110 阅读 · 0 评论 -
2021-07-14. org.eclipse.core包簇的分布
org.eclipse.core包簇的分布以org.eclipse.core为前缀的package与bundle和project的对应关系如表. 第一列中的包名省略org.eclipse.core前缀.特别注意org.eclipse.cor.runtime package对应了3个bundle.package namebundle idprojectcommands commands.*org.eclipse.core.commandseclipse.platform.ui原创 2021-07-14 21:15:47 · 154 阅读 · 0 评论 -
2021-07-13 JFace中的长时操作(long-running operation)
JFace中的长时操作long-running operation 为了UI的良好响应, 长时操作一般放到非UI线程的其它线程中执行.eclipse中UI通常提供一个progress indicator来指示当前完成进度, 并且提供一个cancel按钮可以取消长时操作.JFace中引入了接口IRunnableContext和IRunnableWithProgress来配合完成这个任务.IRunnableContext通常由发起long-running operation的widget实现, 例如Pr原创 2021-07-13 21:33:26 · 153 阅读 · 0 评论 -
2021-07-12. 什么是SWT.VIRTUAL
什么是SWT.VIRTUAL在创建table和tree时, 通常是一次生成全部将数据可. 但对于大数据的情形, 这并不是高效的做法. 例如含10000数据项的table, 其一次最多仅能展示30项, 显然仅需在显示前能够提供这30项数据就可以了. 这就是所谓lazy mode. 这个10000数据项就是一个虚拟(virtual)的表. SWT.VIRTUAL就是用于指示table或tree采用这种形式工作.当table和tree指定为SWT.VIRTUAL时, 有一个参数不得不单独指定, 这就是虚拟表的原创 2021-07-12 16:19:13 · 159 阅读 · 0 评论 -
2021-07-11 配置可执行jar的manifest.mf
可执行jar的manifest.mf可执行的jar包直接使用javar -jar XXX.jar即可直接运行, 无需再特别指明main class.其配置是再MANIFEST.MF中指定Main-Class.一个例子Manifest-Version: 1.0Class-Path: dependency1.jar 用于指定依赖库, 路径基点是XXX.jar所在的路径 dependency1.jar 续行以空格起头 dependencyD原创 2021-07-11 13:08:55 · 632 阅读 · 0 评论 -
Eclipse 4.20中的minimal OSGi console shell(命令行界面)
Eclipse 4.20中的minimal OSGi console shell命令行界面step1. 创建目录和文件如下step2. 运行 org.eclipse.osgi旧版本的eclips直接运行org.eclipse.osgi_*.jar即可启动console. 但新版有变, 需要额外配置几个用到的jar方可.step1. 创建目录和文件如下minimalConsole/configuration/config.iniorg.apache.felix.gogo.command_原创 2021-06-26 22:29:28 · 214 阅读 · 0 评论