Adding or modifying properties
You can add properties to both custom and built-in classes. You can also add local properties to BLPackages and system packages stored in the Depot folder and component templates stored in the Component Templates folder.
When you add a property to a built-in property class, the property is automatically associated with all existing instances of those types of objects. For example, if you add a new property to the Jobs class, the property is:
- Automatically associated with all jobs.
- Inherited by all subordinate built-in subclasses.
When you create a property in the Property Dictionary, the property is available globally throughout TrueSight Server Automation. All roles have access to the property. You can use a parameter to reference the new property in any situation where TrueSight Server Automation supports parameters. When defining BLPackages, component templates, and system packages, you can also create local properties. Properties created in those contexts are not available globally.
Before you begin
Property class properties reference another property class. To apply a custom property class to an object, you must create a property class property that refers to that custom property class. Then, assign the property class property to a built-in property class or create a local property for a BLPackage or component template.
To assign a value for a property class property, you must select an instance of the referenced property class. For more information, see Creating or modifying an instance of a property class.
When you create an instance of a custom property class, many dependencies are established for the properties included in the custom property class. Therefore, you may encounter the following limitations when an instance of a custom class already exists:
- When adding a required property to a custom property class, the property must have a default value. It cannot have a null value.
- An existing property cannot be made into a required property unless you also provide a default value for the property.
- A default value for a required property cannot be deleted.
- Options for an enumerated list cannot be removed. You can only add options to properties that use an enumerated list.
To add or modify a property
- Do any of the following:
- Choose Configuration > Property Dictionary View. Using the Property Class Navigation pane, select a property class or subclass for which you want to add or modify a property. In the property list at right, select the Properties tab.
- Using the Property Dictionary, add a new custom property class (see Adding a custom property class). In the property list at right, select the Properties tab.
- Create a BLPackage, component template, or system package that requires a local property. Open the BLPackage, component template, or system package for editing. Click the Local Properties tab.
- Import an object that references a missing property. When the Import wizard asks you to map a property, add a new property to the Property Dictionary.
- Do one of the following:
- To create a new property, click Add New Property .
- To modify an existing property, select the property and click Edit Property . A property dialog box opens. Depending on your context, the name of this dialog box may vary.
For Name, enter the name of the property. For Description, you can optionally provide descriptive text. The name can be a maximum of 255 characters.
If the name of a property contains more than 30 characters, update the BDSSA_DW system_property table to set the value of EnableLongPropertyName as true.
For Type, select one of the following options:
From the drop-down list at right, select one of the possible values. These values describe the type of data that is possible for a simple property. If you select String enumeration or Integer enumeration, do the following:
- Click Browse to the right of Possible values. The Edit Enumeration dialog box box opens.
- Click Add New Value . The Enumeration Editor dialog box box opens.
- For Name, enter a text string that clearly identifies the potential property value. This string is the name that users see when choosing a value for this property. For Value, enter a value. For example, if you are adding a list of integers, you might assign a name of
Highto the value
Mediumto the value
Lowto the value
- Click OK.
- To add another value, repeat the process.
Simple, and then select Complex
From the drop-down list at right, select the type of data that can be provided for this property.
Click Browse at right. The Property Class Selection dialog box box opens. Use this dialog box box to select a custom or built-in property class or subclass. Click OK.
For an extended discussion of using property classes and property class property types, see Custom property class description.
- To specify a default value for the property, check Use this default value. For Default value, enter a default. The method you use for entering a default value depends on the property type you select in the previous step. For example, if the property type is Boolean, you can select True or False from a drop-down list.
- If the property type is Encrypted String, you must enter a value and then confirm your typing by entering it a second time.
If the property type is Long Text, click Browse to the right of Default value, which displays the Edit Long Text dialog box. Enter a long block of text, such as a script. The text block can be a maximum of 2000 characters.
When using the Property Dictionary to add a property to a property class or subclass, you must always define a default value for the property. That default value can be null (that is, an empty value). Because of this requirement, the Use this default value option is always checked when you are creating a property. If you are modifying a property inherited from a parent class, you can choose not to use a default value by clearing Use this default value.
- Specify additional characteristics for the property by checking any of the following:
- Editable — Users can alter the value of this property.
- Required — A value must be provided for this property. If you check this, you must provide a default value, and the default value cannot be null (that is, an empty value).
- Used in reports — This property can be included in reports generated by BMC Decision Support for Server Automation or TrueSight Smart Reporting for Server Automation. This flag is set to true for most properties provided in a standard installation of TrueSight Server Automation. By default it is set to false for all new properties you create.
- Click OK. The property is added to the list on the Properties tab.