StructureMap

Parent Previous Next

StructureMap


The StructureMap node is used to encapsulate the entire Structure Map and contains the typeMatch attribute, which matches all of a solution's root objects types to their respected structure map.


Table of Contents

  Structure

o   ChildObjects

o   ChildObjectsSubStructure

o   Object

o   RecursiveChildObjects

  Rules

o   Rule


Syntax

This structure map matches to all object types that fit the Regular Expression string "Microsoft\.SqlServer\.Management\.Smo\.Server" and creates an empty structure with no nodes as well as implicitly maps all templates to the template "GlobalDefault":


<StructureMap typeMatch="Microsoft\.SqlServer\.Management\.Smo\.Server">

<Structure>

</Structure>

<Rules>

<Rule templateKey="GlobalDefault" />

</Rules>

</StructureMap>



Required Attributes

typeMatch - Used by DOC xPress during document generation to match the Structure Map to a regular expression based on each of the root object types present within the solution layout.


Important Note:

The typeMatch attribute is required for all Structure Maps with the exception of one: the default structure map. There must be one and only one structure map that does not specify a typeMatch, in a default installation of the DOC xPress templates, that structure map is named "StructureMap.Default.xml".


Required Child Nodes

Structure - Used by the Structure Map to detail the layout (table of contents) for the current Structure Map as well as the


Rules - Used by the Structure Map to detail implicit matches between object and/or name matches for templates within the current Structure Map. A structure map must have at least one rule, which typically points to a default template that is used if there are no explicit templateKeys and no other rule matches.


Important Note:

Rules are evaluated in the order that they are specified, so if you have multiple rules that may match the same object, the first match will always be used.