Compartment Shape (Domain-Specific Language Designer)

Compartment shapes are among the types of shapes that you can use to specify how a domain class appears in a generated designer. Compartment shapes add categorical sections to a domain class. You can expand and collapse these sections, which are called compartments. Each compartment is itself represented by a domain class, and you establish each compartment with compartment maps by using the DSL Details window. You can find an example of a compartment shape in the Class Diagram sample. For more information, see Class Diagram Sample.

You can modify the properties of a compartment shape by clicking it in the Diagram Elements swimlane and modifying its properties in the Properties window. For more information, see How to: Add a Compartment Shape to a Domain-Specific Language Definition and How to: Add a Compartment Shape (DSL Explorer).

Compartment shapes have the properties that are listed in the following table:

Property

Description

Default

Default Expand Collapse State

If Expanded, the compartments are shown on creation. If Collapsed, they are not.

Expanded

Fill Color

Fill color of this shape.

White

Fill Gradient Mode

Fill gradient mode of this shape.

Horizontal

Geometry

Outline geometry of this shape.

Rectangle

Has Default Connection Points

If True, the shape will use top, bottom, left and right connection points in the generated designer.

False

Is Single Compartment Header Visible

If False and the shape has a single compartment, the header of the compartment is not visible.

True

Outline Color

Outline color of this shape.

Black

Outline Dash Style

The outline dash style of this geometry shape.

Solid

Outline Thickness

The outline thickness of this geometry shape

0.03125

Text Color

The color used for text decorators associated with this diagram element.

Black

Access Modifier

Determines if the access modifier for the domain class is public or internal.

Public

Custom Attributes

Used to attribute the code generated from this element.

Note   Use the browse button to add an attribute.

For more information, see How to: Edit Attributes on a Diagram Element.

Generates Double Derived

If True, will generate both a base class with all functionality and a partial class to support customization through overrides.

False

Has Custom Constructor

If True, indicates that a custom constructor will be provided in code.

False

Inheritance Modifier

Determines if the inheritance modifier of the .Net class generated from the domain class is none, abstract or sealed.

None

Base Compartment Shape

Base compartment shape of this compartment shape.

(none)

Name

The name of this element.

Current name

Namespace

The namespace affiliated with this domain class.

Current namespace

Tool Tip Type

If Fixed, then the fixed tooltip text is used as the tooltip, if variable the tooltip is defined in custom code.

Notes

Informal notes associated with this element.

Initial Height

Initial height of this shape, in inches. Note   For compartment shapes, this is the height of the header section only, and can not be resized.

1

Initial Width

Initial width of this shape, in inches.

1.5

Exposed Fill Color As Property

If True, a domain property has been added to the shape to allow the fill color to be exposed in the properties window of the generated designer.

False

Exposed Fill Gradient Mode

If True, a domain property has been added to the shape to allow the fill gradient mode to be exposed in the properties window of the generated designer.

False

Exposed Outline Color As Property

If True, a domain property has been added to the shape to allow the outline color to be exposed in the properties window of the generated designer.

False

Exposed Outline Dash Style As Property

If True, a domain property has been added to the shape to allow the outline dash style to be exposed in the properties window of the generated designer.

False

Exposed Outline Thickness As Property

If True, then a domain property has been added to the shape to allow the outline thickness to be exposed in the properties window of the generated designer.

False

Exposes Text Color

If True, then a domain property has been added to the connector to allow the color to be exposed in the properties window of the generated designer.

False

Description

Used to document code and in the UI of the generated designer.

Display Name

The name that will be displayed in the generated designer for this element.

Fixed Tool Tip Text

The text used for a fixed tooltip.

Help Keyword

The optional keyword used to index F1 help for this element.

Image

Path to the image file to be used for this image shape.

See Also

Concepts

Element Reference for Domain-Specific Languages

Domain-Specific Language Designer Terminology Overview

Domain-Specific Language Tools Glossary