PatchReplaceInstruction¶
- class oci.capacity_management.models.PatchReplaceInstruction(**kwargs)¶
Bases:
PatchInstructionAn operation that “puts” a value, replacing every item of the selection with it, or creating it if the selection is empty. NOT_FOUND exceptions are handled by creating the implied containing structure (but note that this may put the target in an invalid state, which can be prevented by use of precondition operations). To avoid referential errors if an item’s descendant is also in the selection, items of the selection are processed in order of decreasing depth.
Attributes:
A constant which can be used with the operation property of a PatchInstruction.
A constant which can be used with the operation property of a PatchInstruction.
A constant which can be used with the operation property of a PatchInstruction.
A constant which can be used with the operation property of a PatchInstruction.
A constant which can be used with the operation property of a PatchInstruction.
A constant which can be used with the operation property of a PatchInstruction.
A constant which can be used with the operation property of a PatchInstruction.
[Required] Gets the operation of this PatchInstruction.
[Required] Gets the selection of this PatchInstruction.
[Required] Gets the value of this PatchReplaceInstruction.
Methods:
__init__(**kwargs)Initializes a new PatchReplaceInstruction object with values from keyword arguments.
get_subtype(object_dictionary)Given the hash representation of a subtype of this class, use the info in the hash to return the class of the subtype.
- OPERATION_INSERT = 'INSERT'¶
A constant which can be used with the operation property of a PatchInstruction. This constant has a value of “INSERT”
- OPERATION_MERGE = 'MERGE'¶
A constant which can be used with the operation property of a PatchInstruction. This constant has a value of “MERGE”
- OPERATION_MOVE = 'MOVE'¶
A constant which can be used with the operation property of a PatchInstruction. This constant has a value of “MOVE”
- OPERATION_PROHIBIT = 'PROHIBIT'¶
A constant which can be used with the operation property of a PatchInstruction. This constant has a value of “PROHIBIT”
- OPERATION_REMOVE = 'REMOVE'¶
A constant which can be used with the operation property of a PatchInstruction. This constant has a value of “REMOVE”
- OPERATION_REPLACE = 'REPLACE'¶
A constant which can be used with the operation property of a PatchInstruction. This constant has a value of “REPLACE”
- OPERATION_REQUIRE = 'REQUIRE'¶
A constant which can be used with the operation property of a PatchInstruction. This constant has a value of “REQUIRE”
- __init__(**kwargs)¶
Initializes a new PatchReplaceInstruction object with values from keyword arguments. The default value of the
operationattribute of this class isREPLACEand it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class):- Parameters
operation (str) – The value to assign to the operation property of this PatchReplaceInstruction. Allowed values for this property are: “REQUIRE”, “PROHIBIT”, “REPLACE”, “INSERT”, “REMOVE”, “MOVE”, “MERGE”
selection (str) – The value to assign to the selection property of this PatchReplaceInstruction.
value (object) – The value to assign to the value property of this PatchReplaceInstruction.
- static get_subtype(object_dictionary)¶
Given the hash representation of a subtype of this class, use the info in the hash to return the class of the subtype.
- property operation¶
[Required] Gets the operation of this PatchInstruction. Allowed values for this property are: “REQUIRE”, “PROHIBIT”, “REPLACE”, “INSERT”, “REMOVE”, “MOVE”, “MERGE”
- Returns
The operation of this PatchInstruction.
- Return type
str
- property selection¶
[Required] Gets the selection of this PatchInstruction. The set of values to which the operation applies as a JMESPath expression for evaluation against the context resource. An operation fails if the selection yields an exception, except as otherwise specified. Note that comparisons involving non-primitive values (objects or arrays) are not supported and will always evaluate to false.
- Returns
The selection of this PatchInstruction.
- Return type
str
- property value¶
[Required] Gets the value of this PatchReplaceInstruction. A value to be added into the target.
- Returns
The value of this PatchReplaceInstruction.
- Return type
object