Centralize the help features in eclipse

Source: Internet
Author: User

Developers have long thought that building modular systems can easily update a part of the system without affecting other parts of the system. Modularity also makes it easy to extend the original system in a new way. This is the motivation to build Eclipse as a set of Plug-ins, which allows other developers to replace or enhance existing modules.

The help in Eclipse, like other environments, is built using a plug-in architecture. This article discusses how to use this useful architecture to externalized Help content. This article assumes that you already have the application knowledge of Java™, Eclipse, and Web topics. It does not require you to understand how help is organized in Eclipse, as well as all the knowledge of how the plug-in works. The purpose of this article is to show you the Help method and reason for hosting the Eclipse environment on a centralized server (corporate intranet or the Internet) and how to access it from the environment.

Why centralize?

The help in Eclipse is not a monolithic integration entity, but a series of plug-ins that are merged together to provide a holistic concept. But even then, there is no real answer to the question: "Why do you want to centrally manage the ' help ' in Eclipse?" If you download the Java version of Eclipse, you can do Java development and get all the help you need locally. This is also true for the entire development team. Each of them can have their own local "help" copy, and you can use these replicas very well until one day an additional plugin appears.

The arrival of the plugin

In a real project, that day will come when you realize that you and the other members of the development team will need one or two plug-in services (or you will need more plug-ins because they are financially affordable). For any extraordinary team development effort, from the build process to the Third-party JAR files being used, make sure that everyone's environment is the same. This is just the best practice for a project: Make sure everyone in your group is building the same thing. In fact, the role of a large number of third-party tools is simply to deal with this practice: Ant, Java make tools, CruiseControl to support continuous integration, and a number of other tools. Experienced Java developers recognize that it's better to make sure that the development environment and processes are reusable throughout the team. Why is "help" different?

When you install Plug-ins in Eclipse, the more experienced people can also install their own help, which seems to be able to incorporate rights into an existing help infrastructure because of the different ways in which you organize help. This is why an externally accessible help repository can work. Just as you want to keep the rest of the development process consistent, does your help need the same consistency? Help contains existing Eclipse help, and also includes help for merging through other plug-ins.

To ensure better use of the Help system, you should add your own content to this system by adding project and team-specific notifications to the standard help entries. You can download plug-ins that make your work easier, but you must ensure that everyone in your team uses it in the same way and that you have access to the same notifications about plug-ins. If you put all the information in the same location, you reduce the likelihood that information will be out of sync. This is also the best practice written in the book "Pragmatic Programmer", the author of which is Dave Thomas and Andy Hunt. They elaborated the principle of "Don't repeat Yourself" (Don t Repeat yourself, DRY): If you keep the same information in more than one place, it will lose synchronization and you will no longer trust any particular instance of it. If you follow the "Do not repeat yourself" principle, you will understand that a single copy is an authoritative copy. This also applies to "Help."

Help organization in Eclipse

Before you begin to externalized help in Eclipse, you must understand how to organize help by environment. To do this, you need to further understand the help organization in Eclipse.

The easiest way to view the internal structure of help is to build a plug-in using the aid extension point. Because Eclipse comes with the plug-in development environment (Plug-in Development Environment,pde), it is easy to build a new plug-in. First, create a new plug-in project using one of the following methods: File>new project, then select File>new Plug-in Project ..., or combine library methods with Control-n. If you choose either of these two common project creation options, the New Project dialog box, shown in Figure 1, will appear on the screen.

Figure 1. Create a new plug-in project from a common project library

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.