Using the API documentation

From MIPAV
Jump to: navigation, search

Documentation for the application programming interface (API) is located on the MIPAV web site <http://mipav.cit.nih.gov/>. You can use the documentation directly on the web site. However, if your internet access is limited or slow, you can download, install, and use either a zipped version of the documentation on a Windows workstation or a tar version on a UNIX workstation.

To access the API documentation via the internet

1 Go to the MIPAV web site:< http://mipav.cit.nih.gov/>.
2 Click Development in the links on the left side of the page. The Development page appears. See Figure 2.
3 Here, use the following links: MIPAV APIand MIPAV XML based Formats.


Figure 2. The Development page on the MIPAV web site offers a lot of helpful links

MIPAV DevelopmentPage.jpg

To download and install the API documentation on a Windows workstation,

1 Under Documentation for download, select a zip-formatted version. Save the file to a directory of your choice.
2 Go to the directory, double-click api.zip, and extract the files. Extraction creates a directory named "api" under the directory you chose to place the files.
3 Open the api directory, and double-click index.html.

To download and install the API documentation on a UNIX workstation,

1 Under Documentation for download, select a tar.gz-formatted version. Save the file to a directory of your choice.
2 Go to the directory, double-click api.tar.gz, and extract the files. Extraction creates a catalogue named "api" under the directory you chose to place the files.
3 Open theapi directory, and double-click index.html. The API documentation appears in your browser.

Viewing MIPAV API documentation online

On the Development page, click the Application Programming Interface JavaDoc link <http://mipav.cit.nih.gov/documentation/api/index.html>. The API documentation page appears displaying the following three frames:

Top left frame -Shows all of the Java packages for the MIPAV application. When you select the All Classes link at the top of this frame, all of the classes in MIPAV appear in alphabetical order in the bottom left frame. If you select a particular package, the bottom left frame displays only the classes that pertain to the selected package.
Bottom left frame' -Lists either all of the classes in the MIPAV application or all of the classes in a selected package.
Right frame -Displays information based on the command that you select in the menu at the top of the frame:
Overview -Lists all of the packages in the MIPAV application
Package -Lists and summarizes all of the classes and interfaces in the package
Class or Interface -Lists descriptions, summary tables, and detailed member descriptions
Tree -Displays a hierarchy of the class or package
Index -Provides an alphabetical list of all classes, interfaces, constructors, methods, and fields
Help-Provides help for the API documentation
Several links appear beneath the menu.

Prev and Next -These links take you to the next or previous class, interface, package, or related page.
Frames and No Frames links -These links show and hide the HTML frames. All pages are available with or without frames. See Figure 3.

Figure 3. The Overview page

MIPAV APIdoc OverviewPage.jpg


Overview page

The Overview page is the page that initially appears when you gain access to the API documentation. This page displays a list of all of the packages in MIPAV. The Overview menu becomes available after you move to another page. To return to the Overview page from the any other page, click Overview. The Overview page appears and displays a list of all of the packages in MIPAV.

Package page

When you select one of the packages listed on the Overview page, the Package page appears. This page provides a summary of each interface (if any), class, and exception (if any) in the package. When you click an interface or class, the Interface page or the Class page appears. Clicking an exception displays the Exception page. See Figure 4.

Interface or Class pages

When you select an interface or class on the Package page, either the Interface page or the Class page appears. Each interface, nested interface, class, and nested class has its own separate page. Each of these pages has three sections consisting of an interface or class description, summary tables, and detailed member descriptions:
Class inheritance diagram
Direct known subclasses
All known subinterfaces or subclasses
All known implementing classes
Interface or class declaration
Interface or class description
Nested class summary
Field summary
Constructor summary
Method summary
Field detail
Constructor detail
Method detail

Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer. See also Figure 4.

Note: Each serialized or externalized class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. To access this information, go to any serialized class and clicking Serialized Form in the See also section of the class description.

Exception page

The Exception page appears when an exception on the Package page is selected. This page includes a constructor summary and constructor detail.

Tree (Class Hierarchy) page

When you click Tree on the menu, a Tree, or class hierarchy, page appears. This page displays either the class hierarchy for a particular package, or, if you select All Packages, the class hierarchy for all packages. See [MIPAV_Plugins.html#1487499 Figure 308].
If you were viewing the Overview page and then clicked Tree, the class hierarchy for all packages appears on the Tree page.
If you were viewing a Package, Interface, Class, or Exception page and then clicked Tree, the hierarchy for only that package, which includes the class, interface, and exception hierarchies, appears on the Tree page.

Each hierarchy page contains a list of classes, interfaces, and exceptions (if any). The classes are organized by inheritance structure starting with java.lang.Object.

Deprecated API page

The Deprecated API page appears when you click Deprecated on the menu. This page lists all of the methods in the API that have been deprecated. A deprecated method is not recommended for use, generally due to improvements, and a replacement API is usually given.
Warning: Deprecated APIs may be removed in future implementations.

Index

The Index page provides an alphabetic list of all classes, interfaces, constructors, methods, and fields with definitions of each. Clicking an entry displays the usage in the product.

Help page

The Help page provides help for using the API documentation.

Figure 4. The Package, Case and Tree pages of MIPAV API

MIPAV API Pages.jpg

To display,

All interfaces, classes, and exceptions in a package
1 Go to <http://mipav.cit.nih.gov/documentation/api/>. The Overview page appears.
Frame on the right -When you click one of the packages listed on this page, the Package page appears in the frame. The Package page displays a list of all interfaces, classes, and exceptions (if any) in the package.
Top frame on the left -The top frame on the left also lists all of the packages. When you select a package, the bottom frame on the left displays a list of interfaces, classes, and exceptions (if any) in the package.
The methods associated with an interface or with a class
1 Go to <http://mipav.cit.nih.gov/documentation/api/>. The Overview page appears.
2 Do either of the following:

  • Click one of the packages listed in the frame on the right or in the top frame on the left. The Package page appears in the right frame.
  • Click one of the packages in the top frame on the left. A list of interfaces, classes, and exceptions appear in the bottom frame on the left.

3 Do one of the following:

  • Click an interface. The Interface page appears in the right frame.
  • Click a class. The Class page appears in the right frame.

4 Scroll down the page, or click METHODS beneath the menu. The Method Summary table appears.
5 Click a method. The Method Detail section of the page, which lists a description of the method and its parameters, throws, and returns, appears.


Developing plug-in programs