Multi schema classes specification
TypeScript type: MultiSchemaClassesSpecification.
This specification lists ECClasses which should be targeted when creating content or hierarchy nodes.
Attributes
| Name | Required? | Type | Default | 
|---|---|---|---|
| schemaName | Yes | string | |
| classNames | Yes | string[] | |
| arePolymorphic | No | boolean | false | 
Attribute: schemaName
Specifies the schema which contains the target classes.
| Type | string | 
| Is Required | Yes | 
Attribute: classNames
An array of target ECClass names.
| Type | string[] | 
| Is Required | Yes | 
Attribute: arePolymorphic
Defines whether the derived ECClasses should be included in the result.
| Type | boolean | 
| Is Required | No | 
| Default Value | false | 
Example
// This ruleset produces content for instances of `bis.PhysicalModel` and `bis.SpatialCategory` classes.
// Descendants of these classes will be considered incompatible with the specified class filter because
// `arePolymorphic` attribute is set to`false`.
const ruleset: Ruleset = {
  id: "example",
  rules: [{
    ruleType: "Content",
    specifications: [{
      specType: "ContentInstancesOfSpecificClasses",
      classes: {
        schemaName: "BisCore",
        classNames: ["PhysicalModel", "SpatialCategory"],
        arePolymorphic: false,
      },
    }],
  }],
};

Last Updated: 24 January, 2023