Sample Composite Repository Definition File
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE scenario-manager-configuration
PUBLIC "-//Art Technology Group, Inc.//DTD Scenario Manager//EN"
'http://www.atg.com/dtds/composite-repository/composite-repository_1.0.dtd'>
<!-- composite repository definition -->
<composite-repository-template>
<!-- Header similar to GSA DTD -->
<header>
<!-- name of this document -->
<name>A sample Composite Repository template</name>
<!-- author of this document -->
<author>Graham Mather</author>
<!-- version of this document -->
<version>$Change: 226591 $$DateTime: 2002/01/22 15:50:56 $$Author: gm $
</version>
</header>
<!-- composite item descriptor definition -->
<!-- name: name of the composite item descriptor -->
<!-- default: is this the composite repository's default item descriptor? -->
<!-- display-property: the property used when display items of this type -->
<!-- display-name-resource: resource which defines the display name -->
<item-descriptor name="compositeUser" default="true"
display-property="fooProperty"
display-name-resource="itemDescriptorUser">
<!-- resource bundle from whence this item descriptor's resources come -->
<attribute name="resourceBundle"
value="atg.userprofiling.CompositeProfileTemplateResources"
data-type="string"/>
<!-- icon for items of this type -->
<attribute name="icon" value="userIcon" data-type="string"/>
<!-- "basics" category sort priority -->
<attribute name="categoryBasicsPriority" value="10" data-type="int"/>
<!-- primary view definition -->
<!-- name: the name of the primary view, as it appears internally to the
composite repository. The primary view and all composite views must have
unique internal view names -->
<!-- repository-nucleus-name: the nucleus path of the repository in which
the primary view resides -->
<!-- repository-item-descriptor-name: the name of the view in the given
repository which acts as the primary item descriptor for this composite item
descriptor -->
<!-- all-properties-propagate: if true, composite repository attempts to
make all properties in the primary item descriptor available in the
composite item descriptor. Default is false -->
<!-- all-properties-queryable: if true, all properties in the view are
queryable unless otherwise specified. If false, all properties are not
queryable unless otherwise specified. default is true -->
<primary-item-descriptor name="user"
repository-nucleus-name="/atg/userprofiling/ProfileAdapterRepository"
repository-item-descriptor-name="user"
all-properties-propagate="true"
all-properties-queryable="true">
<!--
Can also contain explicit property mappings and explicit property exclusions
-->
<property mapped-property-name="lastName" exclude="true"/>
<property mapped-property-name="email" exclude="true"/>
</primary-item-descriptor>
<!-- contributing view definition -->
<!-- name: the name of this contributing view, as it appears to the composite
repository -->
<!-- repository-nucleus-name: the nucleus path of the repository in which the
primary view resides -->
<!-- repository-item-descriptor-name: the name of the view in the given
repository which acts as the primary item descriptor for this composite item
descriptor -->
<!-- all-properties-propagate: if true, composite repository attempts to make
all properties in the primary item descriptor available in the composite item
descriptor. Default is false -->
<!-- all-properties-queryable: if true, all properties in the view are
queryable unless otherwise specified. If false, all properties are not
queryable unless otherwise specified. default is true -->
<contributing-item-descriptor name="UserProfile-LDAP"
repository-nucleus-name="/atg/adapter/ldap/LDAPRepository"
repository-item-descriptor-name="user"
all-properties-propagate="true"
all-properties-queryable="true">
<!-- explicit property mapping
sometimes it's advantageous to explicitly map a property in a composite view
to a particular property in either the primary or a contributing view.
For example, perhaps two contributing views have properties with the same
name. This gets around the "no contributing views with same property names"
rule.
-->
<!-- name: name of this composite property -->
<!-- mappedPropertyName: the property to which this property maps -->
<!-- queryable: property queryable flag -->
<!-- required: property required flag-->
<!-- expert: property expert flag -->
<!-- hidden: property hidden flag -->
<!-- readable: property readable flag -->
<!-- writable: property writable flag -->
<!-- category-resource: resource for category name -->
<!-- display-name-resource: resource for display name -->
<property name="ldapFirstName" mapped-property-name="firstName"
queryable="false" required="false" expert="false"
hidden="false" readable="true" writable="true"
category-resource="categoryBasics"
display-name-resource="ldapFirstName">
<!-- bundle for this property's resources -->
<attribute name="resourceBundle"
value="atg.userprofiling.CompositeProfileTemplateResources"
data-type="string"/>
<!-- flag for ui being able to write this property -->
<attribute name="uiwritable" value="true" data-type="boolean"/>
<!-- maximum length for this property -->
<attribute name="maxLength" value="32" data-type="int"/>
<!-- does this property's value have to be unique? -->
<attribute name="unique" value="true" data-type="boolean"/>
<!-- sort priority -->
<attribute name="propertySortPriority" value="10" data-type="int"/>
</property>
<!-- explicit property exclusion
Sometimes users will not want to expose absolutely every property from
the underlying primary and contributing views in the composite view. An
explicit property removal allows the user to make the composite view
contain only those contributing properties that are desired.
-->
<property mapped-property-name="login" exclude="true"/>
<property mapped-property-name="password" exclude="true"/>
<property mapped-property-name="id" exclude="true"/>
<!--
2) a composite view's property names are determined thusly:
a) If all-properties-propagate is true, all properties from the primary and
contributing views are combined into the composite view, retaining their
property names, property types, and any metadata they may have defined.
b) All property exclusions are performed. This means that any properties
to be excluded are removed from the composite view.
c) All property mappings are performed. This means that a primary or
contributing property that is to be mapped gets renamed in the composite
view.
d) If there are any two properties in the composite view that have the same
name, error. The composite repository requires that all composite property
names map explicitly to only one primary or contributing property.
-->
<!-- the primary view link describes how items in the contributing view are
linked to items in the primary view. For each primary-contributing
relationship, the user picks a unique id attribute for the primary and the
contributing view. The attribute can be either the repository id of the
item or a uniquely-valued property of the item (e.g. login). A primary item
is linked to a contributing item if its unique id attribute value matches
the unique id attribute value of the contributing item. There must be at
least one primary view link, but there is primary view link limit. -->
<!-- example: this primary view link defines a relationship where an item in
the primary view is linked to an item in this contributing view if the
contributing item has a repository id which is the same as the primary
item's id.
-->
<!--
<primary-item-descriptor-link>
<link-via-id/>
</primary-item-descriptor-link>
-->
<!-- OR:
This primary view link defines a relationship where a primary view item is
linked to an item in this contributing view if the value of the primary
item's "login" property matches the value of the contributing item's
"userLoginName" property.
-->
<primary-item-descriptor-link>
<link-via-property primary="login" contributing="login"/>
</primary-item-descriptor-link>
<!-- OR:
This primary view link defines a relationship where a primary view item is
linked to an item in this contributing view if the value of the primary
item's "firstName" property matches the value of the contributing item's
"userFirstName" property AND the value of the primary item's "lastName"
property matches the value of the contributing item's "userLastName"
property. This is useful in the case where no one property in the primary
view or the contributing view is uniquely valued. The relationships are
ANDed together
<primary-item-descriptor-link>
<link-via-property primary="firstName" contributing="userFirstName"/>
<link-via-property primary="lastName" contributing="userLastName"/>
</primary-item-descriptor-link>
-->
</contributing-item-descriptor>
</item-descriptor>
</composite-repository-template>