Eclipse Platform Protocol

Source: Internet
Author: User

Platfrom Platform Protocol
Platfrom: config, platform: Base, etc.
It can be used not only in the code, but also in the configuration file.
Eg:

// Eclipse Platform Protocol
URL url = new URL ("Platform: config/abc.txt"); // relative to resources in the configuration directory of RCP
// URL url = new URL ("Platform: base/abc.txt"); //, relative to the resources in the RCP root directory

System. Out. println (filelocator. tofileurl (URL). GetFile ());;

URL url = new URL ("Platform: config/themes/" + "default" + "/"
+ Valuestr );
Url = filelocator. tofileurl (URL );

Use in plugin. xml
Eg:
<Extension
Id = "product1"
Point = "org. Eclipse. Core. runtime. Products">
<Product
Application = "cn.com. XYZ. workbench. Application"
Name = "front-end system">
<Property
Name = "aboutimage"
Value = "icon/client.gif">
</Property>
<Property
Name = "appname"
Value = "front-end system">
</Property>
<Property
Name = "preferencecustomization"
Value = "Platform: config/XYZ. properties">
</Property>
</Product>
</Extension>


<Extension
Id = "product"
Point = "org. Eclipse. Core. runtime. Products">
<Product
Application = "cn.com. XYZ. workbench. Application"
Name = "Integrated front-end system">
<Property
Name = "aboutimage"
Value = "Platform:/plugin/cn.com. XYZ. workbench/icon/client.gif">
</Property>
<Property
Name = "appname"
Value = "front-end system">
</Property>
</Product>
</Extension>


Use config. ini
Osgi. splashpath = platform:/base/plugins/cn.com. sinoufc. workbench
Eclipse. Product = cn.com. sinoufc. workbench. product1
Osgi. Bundles. defaultstartlevel = 4
Osgi. bundles = org. Eclipse. Equinox. Common @ 2: Start, org. Eclipse. Update. aggregator @ 3: Start, org. Eclipse. Core. runtime @ start

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.