home | prev | next

Structuring Data: Composing Templates and Types for Data

Templates and Types

In the CDCS family of systems, the concepts of templates and types lie at the very epicenter of all other major concepts and operations.

Templates and types are essential for the creation, generation, parsing, understanding, validation, transformation, import, export, sharing, searching, and reuse of data in the system.

A very central function of the CDCS platform is to facilitate the movement of data into and out of the system using XML schemas (type-based templates) to generate, parse, and validate data.

The system facilitates the conversion of data originating in many unstructured data formats into data formats easily customized and structured for each user’s context.

A user may construct composite data structures by defining templates as top-level containers for one-or-more data types.

Those data types may be:

  1. XML built-in data-types,
  2. user-defined data types, or
  3. some combination thereof.

In the context of the curator system, user-defined data-types are simply referred to as types.

Both templates and types are, ultimately, XML schemas.

Role of Templates and Types in the Overall System Workflow

The workflow of the system is organized to facilitate the creation, use, management, and version tracking of data that is based on formally-defined schemas (templates).

Schemas (templates) must be created before data may enter the system.

To create a template or type is to create a reusable XML schema which is a collection of elements of specific types which may be related to still other specific types with particular cardinalities (i.e., one-to-one relationship cardinality, one-to-many, and so forth).

The curator system’s composer application provides a basis for creating and editing type-based templates using a web-based GUI.

Only administrators are allowed to directly upload templates/types via the web GUI.

Internal creation and editing of templates and types via the composer may be performed by any user.

Version Numbers Associated with Templates and Types

When a type or template is first created, it is associated with a simple integer version number.

Only One Version Active At a Time

Since the system uses types and/or templates in several different ways, for any given type or template, only one version of a given type or template may be considered as “active” in the system at a given time.

If several versions of a type or template exist in the system, an administrator must designate which one should be considered active (and may shift that designation from one version to another within the set of versions of a given type/template name available in the system).

Use Cases for the One Active Version Rule
Evolving Community-Developed Schemas

Having such versioning capabilities makes it possible for users of a curator system to evolve particular type/template schemas over time, while still keeping track of the types/templates that preceded each one.

Administrative Management of Types and Templates Over Time

The system also allows administrators to edit collections of types/templates, even supporting deletion of types/templates from the system, if necessary.

Beyond user-defined collections, which are created and accessible by Non-Administrative Users, the system also provides Administrative Users with a global collection containing all templates and types that exist on the given system.

Linking Types to UI Modules and Transformers

Sometimes a user may wish to associate a particular template or type with:

  1. UI module: a given data-input/processing (UI modules for types); or
  2. data format transformer: a means for rendering, shaping, and/or transforming that information (Exporters and XSLT Transformations for templates).