p2

Is it possible to make an eclipse p2 provisioning mechanism running *locally*?

前提是你 提交于 2019-12-03 06:42:23
问题 Eclipse 3.4[.x] - also known as Ganymede - comes with this new mechanism of provisioning called p2 . "Provisioning" is the process allowing to discover and update on demand some parts of an application, as explained in general in this article on the Sun Web site. Eclipse has an extended wiki section in which p2 details are presented. Specifically, it says in this wiki page that p2 will look for new components However after reading it. I suppose (but you may confirm that point by your own

【SQL练习题】排序

匿名 (未验证) 提交于 2019-12-03 00:32:02
原表如下: 建表脚本: CREATE TABLE districtproducts ( district varchar(255), name varchar(255), price int(255) ); INSERT INTO districtproducts VALUES ('东北', '橘子', 100); INSERT INTO districtproducts VALUES ('东北', '苹果', 50); INSERT INTO districtproducts VALUES ('东北', '葡萄', 50); INSERT INTO districtproducts VALUES ('东北', '柠檬', 30); INSERT INTO districtproducts VALUES ('关东', '柠檬', 100); INSERT INTO districtproducts VALUES ('关东', '菠萝', 100); INSERT INTO districtproducts VALUES ('关东', '苹果', 100); INSERT INTO districtproducts VALUES ('关东', '葡萄', 70); INSERT INTO districtproducts VALUES ('关西', '柠檬', 70); INSERT

面向对象简单示例

房东的猫 提交于 2019-12-02 23:33:43
class person: ''' class由属性和方法(行为)两部分组成,属性即对象的特征,方法(行为)即由属性构成的函数。 为了用self表示所有属性,需要先定义self.属性1=属性1、self.属性2=属性2...... 然后再给所有函数传递self,即传递所有属性作为参数,在函数体里使用到的参数即self.属性n __init__()是一种特殊的方法,被称为类的构造函数或初始化方法,每次创建类的实例时都会调用该方法。 ''' def __init__(self,name,year,money): self.name=name self.year=year self.money=money print "对象实例化" def print1(self): print (self.name+'123') def print2(self): print self.year ''' 对象实例化,要有具体的属性值。 实例化后,可以使用:对象.属性和对象.方法。 ''' p1=person('Peter',0,1000) p2=person('Kelly',0,1200) print p1.name print p2.name p1.print1() p2.print1() ''' 当这个对象不再需要时,可以将其垃圾回收。 但是回收不是"立即"的, 由解释器在适当的时机

Is it possible to make an eclipse p2 provisioning mechanism running *locally*?

妖精的绣舞 提交于 2019-12-02 20:20:59
Eclipse 3.4[.x] - also known as Ganymede - comes with this new mechanism of provisioning called p2 . "Provisioning" is the process allowing to discover and update on demand some parts of an application, as explained in general in this article on the Sun Web site . Eclipse has an extended wiki section in which p2 details are presented. Specifically, it says in this wiki page that p2 will look for new components However after reading it. I suppose (but you may confirm that point by your own experience), that p2 can function file "file://" protocol, which would allow it to provision with local

Mac distribution of Eclipse RCP application built with Tycho on Windows doesn't start

北慕城南 提交于 2019-12-01 17:53:50
I have built an Eclipse RCP application (Indigo) with Tycho. The build is run on a Win 7, 64-bit machine. The parent POM includes: <plugin> <groupId>org.eclipse.tycho</groupId> <artifactId>target-platform-configuration</artifactId> <version>${tycho-version}</version> <configuration> <resolver>p2</resolver> <environment> <os>linux</os> <ws>gtk</ws> <arch>x86_64</arch> </environment> <environment> <os>win32</os> <ws>win32</ws> <arch>x86_64</arch> </environment> <environment> <os>macosx</os> <ws>cocoa</ws> <arch>x86_64</arch> </environment> ... The product configuration looks like this (with a

Mac distribution of Eclipse RCP application built with Tycho on Windows doesn't start

廉价感情. 提交于 2019-12-01 17:12:40
问题 I have built an Eclipse RCP application (Indigo) with Tycho. The build is run on a Win 7, 64-bit machine. The parent POM includes: <plugin> <groupId>org.eclipse.tycho</groupId> <artifactId>target-platform-configuration</artifactId> <version>${tycho-version}</version> <configuration> <resolver>p2</resolver> <environment> <os>linux</os> <ws>gtk</ws> <arch>x86_64</arch> </environment> <environment> <os>win32</os> <ws>win32</ws> <arch>x86_64</arch> </environment> <environment> <os>macosx</os> <ws

c# 判断点是否在多边形内

梦想与她 提交于 2019-12-01 15:28:06
/// <summary> /// 判断点是否在多边形内 /// </summary> /// <param name="checkPoint">需要判断的点</param> /// <param name="polygonPoints">组成多边形点的集合</param> /// <returns></returns> public static bool IsInPolygon2(PointLatLng checkPoint, List<PointLatLng> polygonPoints) { int counter = 0; int i; double xinters; PointLatLng p1, p2; int pointCount = polygonPoints.Count; p1 = polygonPoints[0]; for (i = 1; i <= pointCount; i++) { p2 = polygonPoints[i % pointCount]; if (checkPoint.Lng > Math.Min(p1.Lng, p2.Lng)//校验点的Y大于线段端点的最小Y && checkPoint.Lng <= Math.Max(p1.Lng, p2.Lng))//校验点的Y小于线段端点的最大Y { if (checkPoint.Lat <=

牛客-富豪凯匹配串(bitset)

此生再无相见时 提交于 2019-12-01 07:06:26
题目传送门 sol1: 用bitset来维护,其实感觉挺暴力的,不怎么会用bitset,借着这道题学习一下。 bitset暴力维护 #include "bits/stdc++.h" #define debug puts("what the fuck"); using namespace std; const int MAXN = 1010; char s[MAXN]; bitset<1010> bs[2][MAXN]; int main() { int n, m, q; scanf("%d%d", &n, &m); for (int i = 1; i <= n; i++) { scanf("%s", s + 1); for (int j = 1; s[j]; j++) bs[s[j] ^ '0'][j][i] = 1; } scanf("%d", &q); for (int i = 1; i <= q; i++) { scanf("%s", s + 1); bitset<1010> res; res.set(); for (int j = 1; s[j]; j++) { if (s[j] == '_') continue; res &= bs[s[j] ^ '0'][j]; } printf("%d\n", res.count()); } return 0; } sol2:

Command line to find units in a p2 repository using p2 query language

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-01 00:00:20
p2 has a query language that allows to run queries on the content of a p2 repository. However all examples in the documentation assume that the query language is used from within Java, e.g. IQuery<IInstallableUnit> q = QueryUtil.createMatchQuery("this.id == $0", id); metadataRepository.query(q); How can I execute a query from the command line (without writing my own Java application)? The p2 director application has an option to list or query the content of the given p2 repositories. With -list you'd get all units, and with -list Q:<p2 QL collection query> you can query for a subset. The

Can Eclipse 3.5 discover all bundles in the plugins dir?

ぃ、小莉子 提交于 2019-11-30 19:29:42
Simple usecase : assemble an Eclipse product using simple scripts, just dumping bundles into the plugins dir . This used to work with 3.3 - with 3.5 it's broken: my application doesn't start as the app plugin is not found. Question : what's the easiest way to fix that? This seems to be the only pain in the whole upgrade process for me. Attempts : I guess this is a no-no for P2: it maintains the bundles.info file instead, which is probably very smart.. a bit too smart for me. Some ideas I had: can I just skip P2 altogether and get back to plain old, simple -dirty- discovery mechanism? can I set