PatchRequireInstruction¶
-
class
oci.psql.models.PatchRequireInstruction(**kwargs)¶ Bases:
oci.psql.models.patch_instruction.PatchInstructionA precondition operation that requires a selection to be non-empty, and optionally to include an item with a specified value (useful for asserting that a value exists before attempting to update it, avoiding accidental creation). It fails if the selection is empty, or if value is provided and no item of the selection matches it.
Attributes
OPERATION_INSERTstr(object=’’) -> str OPERATION_MERGEstr(object=’’) -> str OPERATION_MOVEstr(object=’’) -> str OPERATION_PROHIBITstr(object=’’) -> str OPERATION_REMOVEstr(object=’’) -> str OPERATION_REPLACEstr(object=’’) -> str OPERATION_REQUIREstr(object=’’) -> str operation[Required] Gets the operation of this PatchInstruction. selection[Required] Gets the selection of this PatchInstruction. valueGets the value of this PatchRequireInstruction. Methods
__init__(**kwargs)Initializes a new PatchRequireInstruction 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'¶
-
OPERATION_MERGE= 'MERGE'¶
-
OPERATION_MOVE= 'MOVE'¶
-
OPERATION_PROHIBIT= 'PROHIBIT'¶
-
OPERATION_REMOVE= 'REMOVE'¶
-
OPERATION_REPLACE= 'REPLACE'¶
-
OPERATION_REQUIRE= 'REQUIRE'¶
-
__init__(**kwargs)¶ Initializes a new PatchRequireInstruction object with values from keyword arguments. The default value of the
operationattribute of this class isREQUIREand 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 PatchRequireInstruction. 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 PatchRequireInstruction.
- value (object) – The value to assign to the value property of this PatchRequireInstruction.
-
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.
-
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
-
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
-
value¶ Gets the value of this PatchRequireInstruction. A value to be compared against each item of the selection. If this value is an object, then it matches any item that would be unaffected by applying this value as a merge operation. Otherwise, it matches any item to which it is equal according to the rules of JSON Schema.
Returns: The value of this PatchRequireInstruction. Return type: object
-