Object type
ObjectType
¶
Bases: GroupType
Source code in aria/ops/definition/object_type.py
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 |
|
__init__(key, label=None)
¶
Create a new object type definition
Parameters:
Name | Type | Description | Default |
---|---|---|---|
key
|
str
|
The key of the object type |
required |
label
|
Optional[str]
|
Label that is displayed in the VMware Aria Operations UI. Defaults to the key. |
None
|
Source code in aria/ops/definition/object_type.py
add_identifier(identifier)
¶
Add an identifier to this object type. All 'identifying' identifiers are used to determine object uniqueness. If no 'identifying' identifiers exist, they object name will be used for uniqueness.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
identifier
|
Parameter
|
The identifier to add to the object type definition. |
required |
Source code in aria/ops/definition/object_type.py
add_identifiers(identifiers)
¶
Parameters:
Name | Type | Description | Default |
---|---|---|---|
identifiers
|
list[Parameter]
|
A list of identifiers to add to this object type |
required |
define_enum_identifier(key, values, label=None, required=True, is_part_of_uniqueness=True, default=None)
¶
Create a new enum identifier and apply it to this object type definition. All identifiers marked as 'part of uniqueness' are used to determine object identification. If none exist, the object name will be used for identification.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
key
|
str
|
Used to identify the parameter. |
required |
values
|
list[Union[str, tuple[str, str]]]
|
An array containing all enum values. If 'default' is specified and not part of this array, it |
required |
label
|
[Optinal[str]
|
Label that is displayed in the VMware Aria Operations UI. Defaults to the key. |
None
|
required
|
bool
|
True if this parameter is required. Defaults to True. |
True
|
is_part_of_uniqueness
|
bool
|
True if the parameter should be used for object identification. Defaults to True. |
True
|
default
|
Optional[str]
|
The default value of the parameter. |
None
|
Returns:
Type | Description |
---|---|
ObjectType
|
The created Enum Identifier. |
Source code in aria/ops/definition/object_type.py
define_int_identifier(key, label=None, required=True, is_part_of_uniqueness=True, default=None)
¶
Create a new int identifier and apply it to this object type definition. All identifiers marked 'part of uniqueness' are used to determine object identification. If none exist, the object name will be used for identification. Args: key (str): Used to identify the parameter. label (Optional[str]): Label that is displayed in the VMware Aria Operations UI. Defaults to the key. required (bool): True if this parameter is required. Defaults to True. is_part_of_uniqueness (bool): True if the parameter should be used for object identification. Defaults to True. default ([Optional[int]): The default value of the parameter.
Returns:
Type | Description |
---|---|
ObjectType
|
The created Int Identifier. |
Source code in aria/ops/definition/object_type.py
define_string_identifier(key, label=None, required=True, is_part_of_uniqueness=True, default=None)
¶
Create a new string identifier and apply it to this object type definition. All identifiers marked as 'part of uniqueness' are used to determine object identification. If none exist, the object name will be used for identification.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
key
|
str
|
Used to identify the parameter. |
required |
label
|
Optinal[str]
|
Label that is displayed in the VMware Aria Operations UI. Defaults to the key. |
None
|
required
|
bool
|
True if this parameter is required. Defaults to True. |
True
|
is_part_of_uniqueness
|
bool
|
True if the parameter should be used for object identification. Defaults to True. |
True
|
default
|
Optional[str]
|
The default value of the parameter. |
None
|
Returns:
Type | Description |
---|---|
ObjectType
|
The created String Identifier. |