15 - Create a New Descriptor
Problem
The design of a MetaEd model requires a new Ed-Fi Descriptor.
Solution
Create a new Descriptor in the MetaEd source files. Reference your new Descriptor everywhere necessary. Build MetaEd.
After building MetaEd, almost all technical artifacts related to the new Descriptor will be generated, with one exception. Each new Descriptor requires that the individual Descriptor values be defined manually in XML. After completing the necessary steps to create a new Descriptor in MetaEd, details on how to define the Descriptor values can be found here: XML Schema - Ed-Fi Descriptors.
Discussion
An Ed-Fi Descriptor is a customizable list of values mapped for each implementation.
A naming convention for Descriptor entities is to not include the "Descriptor" suffix. This term will be added by MetaEd to the generated entities as needed. When creating a new Descriptor that is not a part of the core Ed-Fi model and is not based on the Ed-Fi Data Standard v2.x, the "with map type" section in the Descriptor template (including the "documentation" and "item" code underneath it) must be deleted.
Consider the following declaration:
Now consider a usage of the new Descriptor:
Here, a reference to the Descriptor named Discipline has been added to DisciplineAction. The "descriptor" keyword is used for that purpose. In this case, DisciplineAction is modeled to have Discipline as a required collection.
Map Types are not supported in the Ed-Fi Data Standard v3.x. The following documentation applies to the Ed-Fi Data Standard v2.x.
Descriptors that are part of the core Ed-Fi model and are based on the Ed-Fi Data Standard v2.x declare a map type in the MetaEd file and list items in that map type. Map type items must be previously defined within the core Ed-Fi model.
Consider the following declaration:
Now consider a usage of the new Descriptor:
Here, a reference to the Descriptor GradeLevel has been added to School. As with
the previous example, the descriptor
keyword is used for that purpose and in
this case, School is modeled to have GradeLevel as a required collection.