Here I'm showing
one simple example: How to create a new Extension Point in Eclipse Plug-in and
also implement it in another Plug-in project.
According to viewer's
request, I'm taking that simple example of Adding functionality.
I created two
plug-ins:
1. X_ExtPoint
2. Y_Implement
X_ExtPoint Plug-in is for providing the Extension
Point whose ID is com.addition In second plug-in Y_Implement, extend the existing extension point (com.addition) and implement it. This
extension point provides three attributes:
a. Number_1
b. Number_2
c. class
c. class
Here, class
attribute is not mandatory. If you provide the java class, then output will be
shown according to the java class implementation, otherwise the output will be
the total of the two numbers which are provided in attribute fields.
To get the output, Run these two plug-in project as Eclipse Application and click on "Execute" action button on either Menu-bar or Toolbar.
To get the output, Run these two plug-in project as Eclipse Application and click on "Execute" action button on either Menu-bar or Toolbar.
Attachment: To Download this project click here and have a look on this.
Hi,
ReplyDeleteI'm added this page on the basis of on demand request. If anybody have any question regarding Extension Point, please put your questions as a comment.
I'll get back to you soon then.
Thanks.
Hi please post tutorial for creating extension in our own plugin. So that other plugin use it.
ReplyDeletePlease download the project mentioned in "Attachment" section and see the "X_ExtPoint" plugin project. What you mentioned here, I already done this in "X_ExtPoint" plugin project. If you still have any query please get back to me again. Thanks.
Delete