The GEOSS Discovery And Access Broker APIs
Authors: Fabrizio Papeschi, Mattia Santoro, Stefano Nativi
API version: 1.4.3-beta

Common_UINode

Extends UINode
Module: UI

This class extends UINode in order to provide a common graphical representation of the nodes as depicted in the below snapshots.
The following CSS is required:


 <!-- API CSS -->
 <link rel="stylesheet" type="text/css" href="http://api.eurogeoss-broker.eu/docs/assets/css/giapi.css" />
The <section> element on the left contains the following subsections: The <aside> element contains a NodeMapWidget that is appended to the <aside> by the options.onAsideReady callback


The image above shows a Common_UINode with the additional report information hide


The image above shows a Common_UINode with the additional report information visible

See also the common-ui-node class in the API CSS file

Constructor

Common_UINode

(
  • [options]
)

Parameters:

  • [options] Object optional
    • [sectionDom] Function optional

      returns the DOM of the <section> element

    • [asideDom] Function optional

      returns the DOM of the <aside> element

    • [onSectionReady] Function optional

      callback function called when <section> element is ready

    • [onAsideReady] Function optional

      callback function called when <aside> element is ready Appends the NodeMapWidget to the <aside> element

    • [dabNode] DAB optional

      Reference to the DAB object; if not set, the "browse collection" button is not provided

    • [onDiscoverResponse] Function optional

      a reference to the onResponse discover callback; this function is called when the "browse collection" button is clicked. If not set, the "browse collection" button is not provided

    • [pageSize=10] Integer optional

      Set the default page size used for to "browse collection"

Methods

GIAPI.Common_UINode.authorRow

(
  • report
)
static

Creates a row of a table with the report.author information

Parameters:

GIAPI.Common_UINode.whenDiv

(
  • time
)
static

Creates a <div> with the given date value which can be clicked to show the calendar

Parameters:

GIAPI.Common_UINode.whenRow

(
  • report
)
static

Creates a row of a table with the report.when information

Parameters:

isRenderable

(
  • node
)

Inherited from UINode:

Return true if the given node is renderable by this UINode instance, false otherwise.
This implementation returns always true. For more info see this section.

Parameters:

Returns:

returns true

render

(
  • node
  • rowNumber
  • rowId
  • colNumber
  • colId
)

Inherited from UINode:

Renders this UINode with the given node.
This implementation creates a component constituted by a <section> and a <aside> elements according to the options.sectionDom and options.asideDom.
When an element is appended to the DOM, the correspondent event function (options.sectionDom or options.asideDom) is called.
In most part of the cases, there is no need to override this method since the implementation of the options.sectionDom and options.asideDom functions is enough.
For more info see this section.

Parameters:

Properties

[GIAPI.Common_UINode.mapMode=]

String static

optional

[GIAPI.Common_UINode.mapType=]

String static

optional

[GIAPI.Common_UINode.mapTypeId=]

String static

optional