HistoryViewLinks to this page 2013 January 8 | 11:03 am

Usage Scenario: Obtain and show UI preview of a AMR

A web UI or REST client wishes to show a preview of the resource to a user without obtaining the entire resource and formatting the properties itself. The UI preview allows a simple client to display a quick view of a resource managed by some other service provider without knowing anything about how to properly display its properties.

This scenario is in accordance with the Core 2.0 specification of UI Preview.

Display UI Preview

  1. A web UI has a list of resources that are managed by one or more OSLC service providers. The web page includes HTML styles and Javascript code that displays a popup window over a resource link when the mouse hovers over it.
  2. The javascript client reacts to a mouse over event. The client makes a GET request on the resource URI requesting a media type of application/x-oslc-compact+xml.
  3. The service provider responds with an RDF compact resource. This resource includes information about one or two possible previews (small and large).
  4. The web client decides to display the small preview by default.
  5. The web client creates a new popup window over the link. Using the the small preview URL it GETs it requesting a HTML media type.
  6. The response is placed in a new window.