Using OASIS with Your Data and ServicesOASIS has been designed to serve as a presentation and data fusion tool that can be used in conjuntion with existing data services. If you have images, source lists, etc. that you keep on-line (or even just local files), these can be displayed using OASIS just by adding an extra HTML link on any web page that references them. If you have data services that produce such files dynamically, these can be handled the same way. Finally, with minor adjustments to your initial service forms, you can use attributes of the current image, etc. being displayed by OASIS (e.g. current image center and size) as initialization parameters for your services.
Basic LinksBy far the most common OASIS link is for the purposes of displaying a data file. For example, suppose you have an image orion.fits that you wish to display. Currently, you would create a link to it on some web page which would tell your Browser to retrieve the file:<a href="http://server.dummy.edu/images/orion.fits">Orion image</a> If the browser has been told which application can handle this file, it will fire up a copy. For an OASIS link, we use an extra level of indirection where the reference is handed off to OASIS (which is started automatically by the Browser if necessary) and OASIS retreives the data and adds it to the current display. In this way, a whole data collection (image, catalog overlays, contours, etc.) can be fused in a single client instance of OASIS even if the data all come from different locations. The above can be converted to an OASIS link simply by sending the existing URL to the OASIS proxy service: <a href="http://irsa.ipac.caltech.edu/cgi-bin/OasisLink/nph-oasislink? ref=http://server.dummy.edu/images/orion.fits">Orion image</a> To be safe, the ref parameter should be url-encoded. Multiple data references and references to services rather than static files can also be sent (see a working example). The file:// construct can also be used if you want to work with local data. OASIS links work by generating an extra (small) Browser page which contains an OASIS applet reference (for OASIS links to work, JavaScript must be active on your Browser). After a brief delay (longer if OASIS hasn't been loaded), the "calling" window returns to your page, the new applet page (a little browser window in the upper left of your screen) contacts or starts OASIS, and OASIS is given the data reference(s). OASIS forwards all such references to its Request Management toolkit and they appear as parallel threads in the File Transfer Manager GUI window (requests made through OASIS will be shown here as well). As data arrives it is stored in a cache (cleared every session) and added to the current display. Since different files (and services; see below) take different amounts of time, there is no guarantee in which order the data will arrive.
Putting the Applet Button on Your Own PageThe proxy Browser window that is created dynamically in the above scenario contains a simple (if somewhat lengthy) standard plug-in applet reference. Such references can be hardcoded onto any page (see the example). This has the advantages that you do not then need to go through the OasisLink proxy generator, have JavaScript active, and have extra browser windows appear on your screen. It has the disadvantages that you have to understand and accomodate the applet information construct and load Oasis when your page comes up (as opposed to it only coming up if a link is activated). In addition, the Browser/plug-in linkage can do some odd things if you place multiple applet references on the same page (most notably downloading multiple copies of the JAR files if OASIS has not already been installed).
Interacting with Web FormsOASIS can also be used in conjunction with web pages containing HTML forms. Any form can be used; the only constraint being that the form must have an ID (standard but not required for HTML <form> tags). As in the previous section, an OASIS "button" is included on the page (see the example), only this time you give a base URL in the formurl parameter and OASIS interacts with the Browser to collect the form parameters and complete the URL (much as the Browser does when you press an HTML submit button. You can have multiple forms on the same page, each with its own "OASIS submit" button (that's what the formid is for).In addition to this, OASIS checks the form inputs on startup looking for specific names (such as the oasisImCenter and oasisImRadius fields in the example. This list (easily extensible if there is any demand) currently contains:
|