eiffelroom

blogStart using Eiffel Information System (EIS)

In EiffelStudio 6.2, Eiffel Information System (EIS) will be introduced. The goal of EIS is to provide a unified mechanism for linking development objects — classes and features, or even targets and groups — of Eiffel systems with external information. This term refers to information other than Eiffel program texts. Usually the tools maintaining external information are separate tools, such as a browser; we call them external tools.

The main apparent addition is the Information tool. But don't be tricked. The basic mechanisms that EIS makes available to users, at least Windows users, include two categories: outgoing (from Eiffel to external tools), incoming (the reverse). The tool belong to the former one.

What can people do via EIS?

EIS Incoming


EIS incoming mechanism, as the name implies, enables users to reference components of an Eiffel system in external tools. For the moment, only available on Windows. The whole thing implemented is protocol link of "eiffel".

For example, one can use the following links to refer to {STRING_8}.is_equal in a system.

  1. eiffel://class=STRING_8&feature=is_equal
  2. eiffel://cluster=elks&class=STRING_8&feature=is_equal
  3. eiffel://target=base&cluster=elks&class=STRING_8&feature=is_equal
  4. eiffel://system=ec.D398E904-E3C8-4F8A-B9E7-6FE493CEA02F&target=base&cluster=elks&class=STRING_8&feature=is_equal

As you see, the later one turns out to be more precise. They all works if the project `ec' with UUID D398E904-E3C8-4F8A-B9E7-6FE493CEA02F has been opened. Once you put this in a browser and enter, or click a link in MS word document, the opening EiffelStudio automatically locates {STRING_8}.is_equal in an open editor.
What if no EiffelStudio has been opened?
For 1, 2 and 3, a new EiffelStudio will be launched, since no project(system) has been specified, users need to choose one by themselves. When the project is successfully loaded, {STRING_8}.is_equal will be opened.
For 4, EiffelStudio introduce a new preference eis_path. EiffelStudio will search projects under the path, finally if project `ec' is found, {STRING_8}.is_equal will be opened.

EIS Outgoing


This part of EIS is used for annotating Eiffel classes, features or even target and clusters to include references to external information. The tool mentioned (Information tool) belongs to this part.

Information tool

The basic function of the tool is to manage all annotations in current system. Users can add, modify, remove or navigate such annotations via the tool. All annotations are arranged either by location or tags being navigated through the tree. One can see that in the tool, choosing a class shows all annotations from the class and those from "inherited" clusters/targets.

The following is what the tool looks like now:
Information tool

Annotation

Annotations if any either reside in actual code in the form of note/indexing or .ecf files in the form of note elements. Those annotations put in code are used to denote class/feature specific information. Those put in .ecf are actually binded to the target/cluster. If one add a piece of annotation into a target or a cluster - underlying info has been added into .ecf - he simply makes the annotation visible to all classes in Information tool. This is useful especially when a library developer want to share library-wide information to clients. The following are the examples of the actual written annotations.
  • code:

indexing
    EIS: "name=myDoc", "src=http://mysite.com/myDoc.pdf", "protocol=pdf", "nameddest=Chapter2", "tag=tagA, tagB"
or
note
    EIS: "name=myDoc", "src=http://mysite.com/myDoc.pdf", "protocol=pdf", "nameddest=Chapter2", "tag=tagA, tagB"
  • .ecf:

<note protocol="pdf" name="myDoc" src="http://mysite.com/myDoc.pdf" ise_support="eis" tag="tagA, tagB" nameddest="Chapter2"/>

Protocol

Everything in Source is treated as an URL if no protocol is specified or unknown protocol is specified. Protocols supported now:
  • Raw URL: Nothing more is interesting other than navigating to the URL
  • PDF: PDF protocol supports three attributes now. "type" "page" and "nameddest".
    • type: "file" is used to open PDF files in PDF reader. Otherwise in a browser.
    • page: Specify the page number to navigate to.
    • nameddest: Specify the named destination to navigate to.

Variable

In the value of Source(Shown in Information tool) variables can be used.
Types of variables , value is taken by priority from top to bottom if the same.
  • IDE user defined variables. (Unavailable) These variables are applied over all projects. The main use is to override following types of variables.
  • IDE built in variables. These variables are built-in and go with the release. Such variables are mostly used by ISE to share users helpful references related to ISE.
  • Target variables. This kind of variables go with the .ecf file. They are mostly used by a library releaser or people who are working on the same project can share information with each other.
  • Environment variables.
  • Context related built in variables. They are feature_name, class_name, group_name and target_name.

One can use F1 in the editor to see if current position of the class has any usable annotations.

about - contact