Technical documentation - Scope Manager

The scope manager is used to define the scope for data in selected functions as search and download. E.g. if an user stands in a catalogue and wishes to search that catalogoue, the scope manager defines what is considered as that catalogue. The configuration exist in profile.config and is named PresentationScope.

Overview

Scope can be defined for a presentation and the scope determines what related information should be consider part of the presentation, e.g to define what other presentations and kits considered to belong to a product (catalogue).

How to define a scope

To define scopes, first add a <PresentationScopeManager> element in the root of the profile.config. In that element add another element giving the type of the PresentationScopeManager. Default it is the same name as the parent element.

Inside the manager element, add a <Scope> element for each scope. For each scope a list of <Trigger> elements can be added that is used to match a given presentation against. If the presentation matches all the triggers, the scope if valid for the presentation. If no triggers are present for a scope, all presentations are valid for that scope. A presentation can though only have one scope, so the first scope (top-down) that is valid for the presentation is selected as the presentations scope.

A <Scope> element can have following attributes and elements:

Attribute

Usage

Attribute

Usage

enabled

Set to false to disable scope handling for all matching presentations.

max-depth

Sets the depth to crawl a presentation. This attribute is a short-hand to create a <Settings> element. An implicit <Settings> element is created with default settings but the MaxLevel that is set to 'max-depth'

Element

Usage

Settings

This element defines how to crawl and collect refrenced information for a presentation. The <Settings> element can have the below elements

MaxLevel

Set a number fo control maximum depth to crawl related information. (Default 2)

CrawlPresentationBulletins

Set to true if bulletins on presentations should be collected. (Default false)

CrawlPresentationReferences

Set to true if references on presentations should be crawled and collected. (Default false)

CrawlHotSpots

Set to true if references on a illustrations hot spot should be crawled and collected. (Default false)

CrawlPartModuleIllustrations

Set to true if illustrations on part modules should be crawled and collected. (Default true)

CrawlPartModuleRowReferences

Set to true if row references on part modules should be crawled and collected. (Default false)

CrawlPartModuleRowPresentations

Set to true if row presentation on part modules should be crawled and collected. (Default true)

CrawlCatalogueNodeBulletins

Set to true if bulletins on catalogue nodes should be collected. (Default false)

CrawlCatalogueNodeReferences

Set to true if presentation on catalogue nodes should be crawled and collected. (Default true)

 

Max level usage

If the MaxLevel is set to 0 only information directly on a presentation will be collected:

  • Direct references (if enabled)

  • Direct bulletins (if enabled)

  • If the presentation is a catalogue, its nodes references (if enabled)

  • If the presentation is a catalogue, its nodes bulletins (if enabled)

  • If the presentation is a part module, its rows references (if enabled)

  • If the presentation is a part module, its rows presentation (if enabled)

  • If the presentation is a part module, its nodes bulletins (if enabled)

  • If the presentation is a part module, its illustrations (if enabled)

  • If the presentation is a illustration, its hotspots references (if enabled)

If the MaxLevel is set to 1 it will also crawl all level 0 collected presentations (not bulletins) and collect as described in previous level.

And so on.

Example

Crawling a catalogue with max level 2 will give us all presentations on the catalogue nodes. If a collected presentation (level 0) is a part module we will also get that part modules presentations (level 1) AND that presentation references information (level 2).

Below two scopes are defined. The first scope definition will match all presentations having the label 'start'. Those presentations will now have a disabled scope rendering any scope handling of for that presentation. All other presentations of type Catalogue (not matching the first scope) will match the next, giving the a scope with depth 2.

 

<!-- Define to search in current catalogue --> <PresentationScopeManager> <PresentationScopeManager> <!-- Turn off scope on index page. Ensure index catalogue has label as below --> <Scope enabled="false"> <Trigger label="start"/> </Scope> <!-- Consider scope to end after two references --> <Scope max-depth="2"> <Trigger base-type="Catalogue"/> </Scope> </PresentationScopeManager> </PresentationScopeManager>

 

In version 5.0 and later documents may be downloaded in a download function. The download function will use the scope manager to determine what documents will be included in the download.