How to use name_or_tags method in avocado

Best Python code snippet using avocado_python

name_pattern_rule.py

Source:name_pattern_rule.py Github

copy

Full Screen

1# coding: utf-82# Copyright (c) 2016, 2020, Oracle and/or its affiliates. All rights reserved.3# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.4from .projection_rule import ProjectionRule5from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F4016from oci.decorators import init_model_state_from_kwargs7@init_model_state_from_kwargs8class NamePatternRule(ProjectionRule):9 """10 This rule projects fields by a name pattern, for example it may start with STR_ or end with _DATE. This is defined using a regular expression.11 """12 #: A constant which can be used with the matching_strategy property of a NamePatternRule.13 #: This constant has a value of "NAME_OR_TAGS"14 MATCHING_STRATEGY_NAME_OR_TAGS = "NAME_OR_TAGS"15 #: A constant which can be used with the matching_strategy property of a NamePatternRule.16 #: This constant has a value of "TAGS_ONLY"17 MATCHING_STRATEGY_TAGS_ONLY = "TAGS_ONLY"18 #: A constant which can be used with the matching_strategy property of a NamePatternRule.19 #: This constant has a value of "NAME_ONLY"20 MATCHING_STRATEGY_NAME_ONLY = "NAME_ONLY"21 #: A constant which can be used with the rule_type property of a NamePatternRule.22 #: This constant has a value of "INCLUDE"23 RULE_TYPE_INCLUDE = "INCLUDE"24 #: A constant which can be used with the rule_type property of a NamePatternRule.25 #: This constant has a value of "EXCLUDE"26 RULE_TYPE_EXCLUDE = "EXCLUDE"27 def __init__(self, **kwargs):28 """29 Initializes a new NamePatternRule object with values from keyword arguments. The default value of the :py:attr:`~oci.data_integration.models.NamePatternRule.model_type` attribute30 of this class is ``NAME_PATTERN_RULE`` and it should not be changed.31 The following keyword arguments are supported (corresponding to the getters/setters of this class):32 :param model_type:33 The value to assign to the model_type property of this NamePatternRule.34 Allowed values for this property are: "NAME_PATTERN_RULE", "TYPE_LIST_RULE", "NAME_LIST_RULE", "TYPED_NAME_PATTERN_RULE", "RENAME_RULE", 'UNKNOWN_ENUM_VALUE'.35 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.36 :type model_type: str37 :param key:38 The value to assign to the key property of this NamePatternRule.39 :type key: str40 :param model_version:41 The value to assign to the model_version property of this NamePatternRule.42 :type model_version: str43 :param parent_ref:44 The value to assign to the parent_ref property of this NamePatternRule.45 :type parent_ref: ParentReference46 :param is_java_regex_syntax:47 The value to assign to the is_java_regex_syntax property of this NamePatternRule.48 :type is_java_regex_syntax: bool49 :param config_values:50 The value to assign to the config_values property of this NamePatternRule.51 :type config_values: ConfigValues52 :param object_status:53 The value to assign to the object_status property of this NamePatternRule.54 :type object_status: int55 :param description:56 The value to assign to the description property of this NamePatternRule.57 :type description: str58 :param is_skip_remaining_rules_on_match:59 The value to assign to the is_skip_remaining_rules_on_match property of this NamePatternRule.60 :type is_skip_remaining_rules_on_match: bool61 :param scope:62 The value to assign to the scope property of this NamePatternRule.63 :type scope: object64 :param is_cascade:65 The value to assign to the is_cascade property of this NamePatternRule.66 :type is_cascade: bool67 :param matching_strategy:68 The value to assign to the matching_strategy property of this NamePatternRule.69 Allowed values for this property are: "NAME_OR_TAGS", "TAGS_ONLY", "NAME_ONLY", 'UNKNOWN_ENUM_VALUE'.70 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.71 :type matching_strategy: str72 :param is_case_sensitive:73 The value to assign to the is_case_sensitive property of this NamePatternRule.74 :type is_case_sensitive: bool75 :param rule_type:76 The value to assign to the rule_type property of this NamePatternRule.77 Allowed values for this property are: "INCLUDE", "EXCLUDE", 'UNKNOWN_ENUM_VALUE'.78 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.79 :type rule_type: str80 :param pattern:81 The value to assign to the pattern property of this NamePatternRule.82 :type pattern: str83 """84 self.swagger_types = {85 'model_type': 'str',86 'key': 'str',87 'model_version': 'str',88 'parent_ref': 'ParentReference',89 'is_java_regex_syntax': 'bool',90 'config_values': 'ConfigValues',91 'object_status': 'int',92 'description': 'str',93 'is_skip_remaining_rules_on_match': 'bool',94 'scope': 'object',95 'is_cascade': 'bool',96 'matching_strategy': 'str',97 'is_case_sensitive': 'bool',98 'rule_type': 'str',99 'pattern': 'str'100 }101 self.attribute_map = {102 'model_type': 'modelType',103 'key': 'key',104 'model_version': 'modelVersion',105 'parent_ref': 'parentRef',106 'is_java_regex_syntax': 'isJavaRegexSyntax',107 'config_values': 'configValues',108 'object_status': 'objectStatus',109 'description': 'description',110 'is_skip_remaining_rules_on_match': 'isSkipRemainingRulesOnMatch',111 'scope': 'scope',112 'is_cascade': 'isCascade',113 'matching_strategy': 'matchingStrategy',114 'is_case_sensitive': 'isCaseSensitive',115 'rule_type': 'ruleType',116 'pattern': 'pattern'117 }118 self._model_type = None119 self._key = None120 self._model_version = None121 self._parent_ref = None122 self._is_java_regex_syntax = None123 self._config_values = None124 self._object_status = None125 self._description = None126 self._is_skip_remaining_rules_on_match = None127 self._scope = None128 self._is_cascade = None129 self._matching_strategy = None130 self._is_case_sensitive = None131 self._rule_type = None132 self._pattern = None133 self._model_type = 'NAME_PATTERN_RULE'134 @property135 def is_skip_remaining_rules_on_match(self):136 """137 Gets the is_skip_remaining_rules_on_match of this NamePatternRule.138 Specifies whether to skip remaining rules when a match is found.139 :return: The is_skip_remaining_rules_on_match of this NamePatternRule.140 :rtype: bool141 """142 return self._is_skip_remaining_rules_on_match143 @is_skip_remaining_rules_on_match.setter144 def is_skip_remaining_rules_on_match(self, is_skip_remaining_rules_on_match):145 """146 Sets the is_skip_remaining_rules_on_match of this NamePatternRule.147 Specifies whether to skip remaining rules when a match is found.148 :param is_skip_remaining_rules_on_match: The is_skip_remaining_rules_on_match of this NamePatternRule.149 :type: bool150 """151 self._is_skip_remaining_rules_on_match = is_skip_remaining_rules_on_match152 @property153 def scope(self):154 """155 Gets the scope of this NamePatternRule.156 Reference to a typed object. This can be either a key value to an object within the document, a shall referenced to a `TypedObject`, or a full `TypedObject` definition.157 :return: The scope of this NamePatternRule.158 :rtype: object159 """160 return self._scope161 @scope.setter162 def scope(self, scope):163 """164 Sets the scope of this NamePatternRule.165 Reference to a typed object. This can be either a key value to an object within the document, a shall referenced to a `TypedObject`, or a full `TypedObject` definition.166 :param scope: The scope of this NamePatternRule.167 :type: object168 """169 self._scope = scope170 @property171 def is_cascade(self):172 """173 Gets the is_cascade of this NamePatternRule.174 Specifies whether to cascade or not.175 :return: The is_cascade of this NamePatternRule.176 :rtype: bool177 """178 return self._is_cascade179 @is_cascade.setter180 def is_cascade(self, is_cascade):181 """182 Sets the is_cascade of this NamePatternRule.183 Specifies whether to cascade or not.184 :param is_cascade: The is_cascade of this NamePatternRule.185 :type: bool186 """187 self._is_cascade = is_cascade188 @property189 def matching_strategy(self):190 """191 Gets the matching_strategy of this NamePatternRule.192 The pattern matching strategy.193 Allowed values for this property are: "NAME_OR_TAGS", "TAGS_ONLY", "NAME_ONLY", 'UNKNOWN_ENUM_VALUE'.194 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.195 :return: The matching_strategy of this NamePatternRule.196 :rtype: str197 """198 return self._matching_strategy199 @matching_strategy.setter200 def matching_strategy(self, matching_strategy):201 """202 Sets the matching_strategy of this NamePatternRule.203 The pattern matching strategy.204 :param matching_strategy: The matching_strategy of this NamePatternRule.205 :type: str206 """207 allowed_values = ["NAME_OR_TAGS", "TAGS_ONLY", "NAME_ONLY"]208 if not value_allowed_none_or_none_sentinel(matching_strategy, allowed_values):209 matching_strategy = 'UNKNOWN_ENUM_VALUE'210 self._matching_strategy = matching_strategy211 @property212 def is_case_sensitive(self):213 """214 Gets the is_case_sensitive of this NamePatternRule.215 Specifies if the rule is case sensitive.216 :return: The is_case_sensitive of this NamePatternRule.217 :rtype: bool218 """219 return self._is_case_sensitive220 @is_case_sensitive.setter221 def is_case_sensitive(self, is_case_sensitive):222 """223 Sets the is_case_sensitive of this NamePatternRule.224 Specifies if the rule is case sensitive.225 :param is_case_sensitive: The is_case_sensitive of this NamePatternRule.226 :type: bool227 """228 self._is_case_sensitive = is_case_sensitive229 @property230 def rule_type(self):231 """232 Gets the rule_type of this NamePatternRule.233 The rule type.234 Allowed values for this property are: "INCLUDE", "EXCLUDE", 'UNKNOWN_ENUM_VALUE'.235 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.236 :return: The rule_type of this NamePatternRule.237 :rtype: str238 """239 return self._rule_type240 @rule_type.setter241 def rule_type(self, rule_type):242 """243 Sets the rule_type of this NamePatternRule.244 The rule type.245 :param rule_type: The rule_type of this NamePatternRule.246 :type: str247 """248 allowed_values = ["INCLUDE", "EXCLUDE"]249 if not value_allowed_none_or_none_sentinel(rule_type, allowed_values):250 rule_type = 'UNKNOWN_ENUM_VALUE'251 self._rule_type = rule_type252 @property253 def pattern(self):254 """255 Gets the pattern of this NamePatternRule.256 The rule pattern.257 :return: The pattern of this NamePatternRule.258 :rtype: str259 """260 return self._pattern261 @pattern.setter262 def pattern(self, pattern):263 """264 Sets the pattern of this NamePatternRule.265 The rule pattern.266 :param pattern: The pattern of this NamePatternRule.267 :type: str268 """269 self._pattern = pattern270 def __repr__(self):271 return formatted_flat_dict(self)272 def __eq__(self, other):273 if other is None:274 return False275 return self.__dict__ == other.__dict__276 def __ne__(self, other):...

Full Screen

Full Screen

type_list_rule.py

Source:type_list_rule.py Github

copy

Full Screen

1# coding: utf-82# Copyright (c) 2016, 2020, Oracle and/or its affiliates. All rights reserved.3# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.4from .projection_rule import ProjectionRule5from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F4016from oci.decorators import init_model_state_from_kwargs7@init_model_state_from_kwargs8class TypeListRule(ProjectionRule):9 """10 The type list rule that defines how fields are projected.11 """12 #: A constant which can be used with the matching_strategy property of a TypeListRule.13 #: This constant has a value of "NAME_OR_TAGS"14 MATCHING_STRATEGY_NAME_OR_TAGS = "NAME_OR_TAGS"15 #: A constant which can be used with the matching_strategy property of a TypeListRule.16 #: This constant has a value of "TAGS_ONLY"17 MATCHING_STRATEGY_TAGS_ONLY = "TAGS_ONLY"18 #: A constant which can be used with the matching_strategy property of a TypeListRule.19 #: This constant has a value of "NAME_ONLY"20 MATCHING_STRATEGY_NAME_ONLY = "NAME_ONLY"21 #: A constant which can be used with the rule_type property of a TypeListRule.22 #: This constant has a value of "INCLUDE"23 RULE_TYPE_INCLUDE = "INCLUDE"24 #: A constant which can be used with the rule_type property of a TypeListRule.25 #: This constant has a value of "EXCLUDE"26 RULE_TYPE_EXCLUDE = "EXCLUDE"27 def __init__(self, **kwargs):28 """29 Initializes a new TypeListRule object with values from keyword arguments. The default value of the :py:attr:`~oci.data_integration.models.TypeListRule.model_type` attribute30 of this class is ``TYPE_LIST_RULE`` and it should not be changed.31 The following keyword arguments are supported (corresponding to the getters/setters of this class):32 :param model_type:33 The value to assign to the model_type property of this TypeListRule.34 Allowed values for this property are: "NAME_PATTERN_RULE", "TYPE_LIST_RULE", "NAME_LIST_RULE", "TYPED_NAME_PATTERN_RULE", "RENAME_RULE", 'UNKNOWN_ENUM_VALUE'.35 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.36 :type model_type: str37 :param key:38 The value to assign to the key property of this TypeListRule.39 :type key: str40 :param model_version:41 The value to assign to the model_version property of this TypeListRule.42 :type model_version: str43 :param parent_ref:44 The value to assign to the parent_ref property of this TypeListRule.45 :type parent_ref: ParentReference46 :param is_java_regex_syntax:47 The value to assign to the is_java_regex_syntax property of this TypeListRule.48 :type is_java_regex_syntax: bool49 :param config_values:50 The value to assign to the config_values property of this TypeListRule.51 :type config_values: ConfigValues52 :param object_status:53 The value to assign to the object_status property of this TypeListRule.54 :type object_status: int55 :param description:56 The value to assign to the description property of this TypeListRule.57 :type description: str58 :param is_skip_remaining_rules_on_match:59 The value to assign to the is_skip_remaining_rules_on_match property of this TypeListRule.60 :type is_skip_remaining_rules_on_match: bool61 :param scope:62 The value to assign to the scope property of this TypeListRule.63 :type scope: object64 :param is_cascade:65 The value to assign to the is_cascade property of this TypeListRule.66 :type is_cascade: bool67 :param matching_strategy:68 The value to assign to the matching_strategy property of this TypeListRule.69 Allowed values for this property are: "NAME_OR_TAGS", "TAGS_ONLY", "NAME_ONLY", 'UNKNOWN_ENUM_VALUE'.70 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.71 :type matching_strategy: str72 :param is_case_sensitive:73 The value to assign to the is_case_sensitive property of this TypeListRule.74 :type is_case_sensitive: bool75 :param rule_type:76 The value to assign to the rule_type property of this TypeListRule.77 Allowed values for this property are: "INCLUDE", "EXCLUDE", 'UNKNOWN_ENUM_VALUE'.78 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.79 :type rule_type: str80 :param types:81 The value to assign to the types property of this TypeListRule.82 :type types: list[object]83 """84 self.swagger_types = {85 'model_type': 'str',86 'key': 'str',87 'model_version': 'str',88 'parent_ref': 'ParentReference',89 'is_java_regex_syntax': 'bool',90 'config_values': 'ConfigValues',91 'object_status': 'int',92 'description': 'str',93 'is_skip_remaining_rules_on_match': 'bool',94 'scope': 'object',95 'is_cascade': 'bool',96 'matching_strategy': 'str',97 'is_case_sensitive': 'bool',98 'rule_type': 'str',99 'types': 'list[object]'100 }101 self.attribute_map = {102 'model_type': 'modelType',103 'key': 'key',104 'model_version': 'modelVersion',105 'parent_ref': 'parentRef',106 'is_java_regex_syntax': 'isJavaRegexSyntax',107 'config_values': 'configValues',108 'object_status': 'objectStatus',109 'description': 'description',110 'is_skip_remaining_rules_on_match': 'isSkipRemainingRulesOnMatch',111 'scope': 'scope',112 'is_cascade': 'isCascade',113 'matching_strategy': 'matchingStrategy',114 'is_case_sensitive': 'isCaseSensitive',115 'rule_type': 'ruleType',116 'types': 'types'117 }118 self._model_type = None119 self._key = None120 self._model_version = None121 self._parent_ref = None122 self._is_java_regex_syntax = None123 self._config_values = None124 self._object_status = None125 self._description = None126 self._is_skip_remaining_rules_on_match = None127 self._scope = None128 self._is_cascade = None129 self._matching_strategy = None130 self._is_case_sensitive = None131 self._rule_type = None132 self._types = None133 self._model_type = 'TYPE_LIST_RULE'134 @property135 def is_skip_remaining_rules_on_match(self):136 """137 Gets the is_skip_remaining_rules_on_match of this TypeListRule.138 Specifies whether to skip remaining rules when a match is found.139 :return: The is_skip_remaining_rules_on_match of this TypeListRule.140 :rtype: bool141 """142 return self._is_skip_remaining_rules_on_match143 @is_skip_remaining_rules_on_match.setter144 def is_skip_remaining_rules_on_match(self, is_skip_remaining_rules_on_match):145 """146 Sets the is_skip_remaining_rules_on_match of this TypeListRule.147 Specifies whether to skip remaining rules when a match is found.148 :param is_skip_remaining_rules_on_match: The is_skip_remaining_rules_on_match of this TypeListRule.149 :type: bool150 """151 self._is_skip_remaining_rules_on_match = is_skip_remaining_rules_on_match152 @property153 def scope(self):154 """155 Gets the scope of this TypeListRule.156 Reference to a typed object. This can be either a key value to an object within the document, a shall referenced to a `TypedObject`, or a full `TypedObject` definition.157 :return: The scope of this TypeListRule.158 :rtype: object159 """160 return self._scope161 @scope.setter162 def scope(self, scope):163 """164 Sets the scope of this TypeListRule.165 Reference to a typed object. This can be either a key value to an object within the document, a shall referenced to a `TypedObject`, or a full `TypedObject` definition.166 :param scope: The scope of this TypeListRule.167 :type: object168 """169 self._scope = scope170 @property171 def is_cascade(self):172 """173 Gets the is_cascade of this TypeListRule.174 Specifies whether to cascade or not.175 :return: The is_cascade of this TypeListRule.176 :rtype: bool177 """178 return self._is_cascade179 @is_cascade.setter180 def is_cascade(self, is_cascade):181 """182 Sets the is_cascade of this TypeListRule.183 Specifies whether to cascade or not.184 :param is_cascade: The is_cascade of this TypeListRule.185 :type: bool186 """187 self._is_cascade = is_cascade188 @property189 def matching_strategy(self):190 """191 Gets the matching_strategy of this TypeListRule.192 The pattern matching strategy.193 Allowed values for this property are: "NAME_OR_TAGS", "TAGS_ONLY", "NAME_ONLY", 'UNKNOWN_ENUM_VALUE'.194 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.195 :return: The matching_strategy of this TypeListRule.196 :rtype: str197 """198 return self._matching_strategy199 @matching_strategy.setter200 def matching_strategy(self, matching_strategy):201 """202 Sets the matching_strategy of this TypeListRule.203 The pattern matching strategy.204 :param matching_strategy: The matching_strategy of this TypeListRule.205 :type: str206 """207 allowed_values = ["NAME_OR_TAGS", "TAGS_ONLY", "NAME_ONLY"]208 if not value_allowed_none_or_none_sentinel(matching_strategy, allowed_values):209 matching_strategy = 'UNKNOWN_ENUM_VALUE'210 self._matching_strategy = matching_strategy211 @property212 def is_case_sensitive(self):213 """214 Gets the is_case_sensitive of this TypeListRule.215 Specifies if the rule is case sensitive.216 :return: The is_case_sensitive of this TypeListRule.217 :rtype: bool218 """219 return self._is_case_sensitive220 @is_case_sensitive.setter221 def is_case_sensitive(self, is_case_sensitive):222 """223 Sets the is_case_sensitive of this TypeListRule.224 Specifies if the rule is case sensitive.225 :param is_case_sensitive: The is_case_sensitive of this TypeListRule.226 :type: bool227 """228 self._is_case_sensitive = is_case_sensitive229 @property230 def rule_type(self):231 """232 Gets the rule_type of this TypeListRule.233 The rule type.234 Allowed values for this property are: "INCLUDE", "EXCLUDE", 'UNKNOWN_ENUM_VALUE'.235 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.236 :return: The rule_type of this TypeListRule.237 :rtype: str238 """239 return self._rule_type240 @rule_type.setter241 def rule_type(self, rule_type):242 """243 Sets the rule_type of this TypeListRule.244 The rule type.245 :param rule_type: The rule_type of this TypeListRule.246 :type: str247 """248 allowed_values = ["INCLUDE", "EXCLUDE"]249 if not value_allowed_none_or_none_sentinel(rule_type, allowed_values):250 rule_type = 'UNKNOWN_ENUM_VALUE'251 self._rule_type = rule_type252 @property253 def types(self):254 """255 Gets the types of this TypeListRule.256 An arry of types.257 :return: The types of this TypeListRule.258 :rtype: list[object]259 """260 return self._types261 @types.setter262 def types(self, types):263 """264 Sets the types of this TypeListRule.265 An arry of types.266 :param types: The types of this TypeListRule.267 :type: list[object]268 """269 self._types = types270 def __repr__(self):271 return formatted_flat_dict(self)272 def __eq__(self, other):273 if other is None:274 return False275 return self.__dict__ == other.__dict__276 def __ne__(self, other):...

Full Screen

Full Screen

Automation Testing Tutorials

Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.

LambdaTest Learning Hubs:

YouTube

You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.

Run avocado automation tests on LambdaTest cloud grid

Perform automation testing on 3000+ real desktop and mobile devices online.

Try LambdaTest Now !!

Get 100 minutes of automation test minutes FREE!!

Next-Gen App & Browser Testing Cloud

Was this article helpful?

Helpful

NotHelpful