Map modes provide symbolic names used to categorize item and property views by their function. The following map modes are supplied with ATG Content Administration:

The mapMode item descriptor is defined as follows in ViewMapping.xml:

<item-descriptor name="mapMode" display-property="name" query-cache-size="10">
  <table name="vmap_mode" type="primary" id-column-name="id">
    <property name="id" data-type="string"/>
    <property name="name"/>
    <property name="description"/>
    <property name="fallbackMode" column-name="fallback_id" item-type="mapMode"/>
  </table>
</item-descriptor>

Map modes can include a fallback mode, which identifies the mode that should be used if a default property view is not found in the primary mode. This behavior can be used to minimize the number of default property views that an application requires. Fallback modes are searched recursively until either a mode with an empty fallback mode or a mode that has already been encountered is reached.

You can add new map modes if required. The following example assumes you have a business requirement to display asset properties so that they fit in a limited amount of space. It shows the basic steps for setting up a new map mode to fulfill this requirement and also demonstrates how to set the fallback mode (in this case, view).

  1. Create the item for the new mode (called condensedView in this example), setting its fallback mode to view. For more information, see Creating View Mapping Repository Items.

  2. Add the following getItemMapping tag parameters to the appropriate JSP:

    <biz:getItemMapping var="imap"
       mode="condensedView" item="${item}"/>

    For more information, see Using the getItemMapping Tag.

  3. Create propertyView items that truncate potentially large data values, and set their mode to condensedView.

Note that the getItemMapping tag can also be used to specify (or override) the fallback mode:

<biz:getItemMapping var="imap"
  mode="condensedView"
  fallbackMode="view"
  item="${item}"/>
 
loading table of contents...