Reference documentation and code samples for the Cloud Asset V1 API class Google::Cloud::Asset::V1::AnalyzerOrgPolicy.
This organization policy message is a modified version of the one defined in
the Organization Policy system. This message contains several fields defined
in the original organization policy with some new fields for analysis
purpose.
Inherits
Object
Extended By
Google::Protobuf::MessageExts::ClassMethods
Includes
Google::Protobuf::MessageExts
Methods
#applied_resource
defapplied_resource()->::String
Returns
(::String) — The full resource name of
an organization/folder/project resource where this organization policy
applies to.
For any user defined org policies, this field has the same value as
the [attached_resource] field. Only for default policy, this field has
the different value.
#applied_resource=
defapplied_resource=(value)->::String
Parameter
value (::String) — The full resource name of
an organization/folder/project resource where this organization policy
applies to.
For any user defined org policies, this field has the same value as
the [attached_resource] field. Only for default policy, this field has
the different value.
Returns
(::String) — The full resource name of
an organization/folder/project resource where this organization policy
applies to.
For any user defined org policies, this field has the same value as
the [attached_resource] field. Only for default policy, this field has
the different value.
#attached_resource
defattached_resource()->::String
Returns
(::String) — The full resource name of
an organization/folder/project resource where this organization policy is
set.
Notice that some type of constraints are defined with default policy. This
field will be empty for them.
#attached_resource=
defattached_resource=(value)->::String
Parameter
value (::String) — The full resource name of
an organization/folder/project resource where this organization policy is
set.
Notice that some type of constraints are defined with default policy. This
field will be empty for them.
Returns
(::String) — The full resource name of
an organization/folder/project resource where this organization policy is
set.
Notice that some type of constraints are defined with default policy. This
field will be empty for them.
#inherit_from_parent
definherit_from_parent()->::Boolean
Returns
(::Boolean) — If inherit_from_parent is true, Rules set higher up in the
hierarchy (up to the closest root) are inherited and present in the
effective policy. If it is false, then no rules are inherited, and this
policy becomes the effective root for evaluation.
#inherit_from_parent=
definherit_from_parent=(value)->::Boolean
Parameter
value (::Boolean) — If inherit_from_parent is true, Rules set higher up in the
hierarchy (up to the closest root) are inherited and present in the
effective policy. If it is false, then no rules are inherited, and this
policy becomes the effective root for evaluation.
Returns
(::Boolean) — If inherit_from_parent is true, Rules set higher up in the
hierarchy (up to the closest root) are inherited and present in the
effective policy. If it is false, then no rules are inherited, and this
policy becomes the effective root for evaluation.
#reset
defreset()->::Boolean
Returns
(::Boolean) — Ignores policies set above this resource and restores the default behavior
of the constraint at this resource.
This field can be set in policies for either list or boolean
constraints. If set, rules must be empty and inherit_from_parent
must be set to false.
#reset=
defreset=(value)->::Boolean
Parameter
value (::Boolean) — Ignores policies set above this resource and restores the default behavior
of the constraint at this resource.
This field can be set in policies for either list or boolean
constraints. If set, rules must be empty and inherit_from_parent
must be set to false.
Returns
(::Boolean) — Ignores policies set above this resource and restores the default behavior
of the constraint at this resource.
This field can be set in policies for either list or boolean
constraints. If set, rules must be empty and inherit_from_parent
must be set to false.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-09 UTC."],[],[],null,["# Cloud Asset V1 API - Class Google::Cloud::Asset::V1::AnalyzerOrgPolicy (v1.4.1)\n\nVersion latestkeyboard_arrow_down\n\n- [1.4.1 (latest)](/ruby/docs/reference/google-cloud-asset-v1/latest/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [1.4.0](/ruby/docs/reference/google-cloud-asset-v1/1.4.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [1.3.1](/ruby/docs/reference/google-cloud-asset-v1/1.3.1/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [1.2.0](/ruby/docs/reference/google-cloud-asset-v1/1.2.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [1.1.0](/ruby/docs/reference/google-cloud-asset-v1/1.1.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [1.0.2](/ruby/docs/reference/google-cloud-asset-v1/1.0.2/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.32.0](/ruby/docs/reference/google-cloud-asset-v1/0.32.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.31.0](/ruby/docs/reference/google-cloud-asset-v1/0.31.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.30.0](/ruby/docs/reference/google-cloud-asset-v1/0.30.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.29.3](/ruby/docs/reference/google-cloud-asset-v1/0.29.3/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.28.1](/ruby/docs/reference/google-cloud-asset-v1/0.28.1/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.27.0](/ruby/docs/reference/google-cloud-asset-v1/0.27.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.26.1](/ruby/docs/reference/google-cloud-asset-v1/0.26.1/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.25.0](/ruby/docs/reference/google-cloud-asset-v1/0.25.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.24.0](/ruby/docs/reference/google-cloud-asset-v1/0.24.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.23.0](/ruby/docs/reference/google-cloud-asset-v1/0.23.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.22.0](/ruby/docs/reference/google-cloud-asset-v1/0.22.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.21.1](/ruby/docs/reference/google-cloud-asset-v1/0.21.1/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.20.1](/ruby/docs/reference/google-cloud-asset-v1/0.20.1/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.19.0](/ruby/docs/reference/google-cloud-asset-v1/0.19.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.18.0](/ruby/docs/reference/google-cloud-asset-v1/0.18.0/Google-Cloud-Asset-V1-AnalyzerOrgPolicy)\n- [0.17.3](/ruby/docs/reference/google-cloud-asset-v1/0.17.3/Google-Cloud-Asset-V1-AnalyzerOrgPolicy) \nReference documentation and code samples for the Cloud Asset V1 API class Google::Cloud::Asset::V1::AnalyzerOrgPolicy.\n\nThis organization policy message is a modified version of the one defined in\nthe Organization Policy system. This message contains several fields defined\nin the original organization policy with some new fields for analysis\npurpose. \n\nInherits\n--------\n\n- Object \n\nExtended By\n-----------\n\n- Google::Protobuf::MessageExts::ClassMethods \n\nIncludes\n--------\n\n- Google::Protobuf::MessageExts\n\nMethods\n-------\n\n### #applied_resource\n\n def applied_resource() -\u003e ::String\n\n**Returns**\n\n- (::String) --- The [full resource name](https://cloud.google.com/asset-inventory/docs/resource-name-format) of an organization/folder/project resource where this organization policy applies to.\n\n\n For any user defined org policies, this field has the same value as\n the \\[attached_resource\\] field. Only for default policy, this field has\n the different value.\n\n### #applied_resource=\n\n def applied_resource=(value) -\u003e ::String\n\n**Parameter**\n\n- **value** (::String) --- The [full resource name](https://cloud.google.com/asset-inventory/docs/resource-name-format) of an organization/folder/project resource where this organization policy applies to.\n\n\n For any user defined org policies, this field has the same value as\n the \\[attached_resource\\] field. Only for default policy, this field has\nthe different value. \n**Returns**\n\n- (::String) --- The [full resource name](https://cloud.google.com/asset-inventory/docs/resource-name-format) of an organization/folder/project resource where this organization policy applies to.\n\n\n For any user defined org policies, this field has the same value as\n the \\[attached_resource\\] field. Only for default policy, this field has\n the different value.\n\n### #attached_resource\n\n def attached_resource() -\u003e ::String\n\n**Returns**\n\n- (::String) --- The [full resource name](https://cloud.google.com/asset-inventory/docs/resource-name-format) of an organization/folder/project resource where this organization policy is set.\n\n\n Notice that some type of constraints are defined with default policy. This\n field will be empty for them.\n\n### #attached_resource=\n\n def attached_resource=(value) -\u003e ::String\n\n**Parameter**\n\n- **value** (::String) --- The [full resource name](https://cloud.google.com/asset-inventory/docs/resource-name-format) of an organization/folder/project resource where this organization policy is set.\n\n\n Notice that some type of constraints are defined with default policy. This\nfield will be empty for them. \n**Returns**\n\n- (::String) --- The [full resource name](https://cloud.google.com/asset-inventory/docs/resource-name-format) of an organization/folder/project resource where this organization policy is set.\n\n\n Notice that some type of constraints are defined with default policy. This\n field will be empty for them.\n\n### #inherit_from_parent\n\n def inherit_from_parent() -\u003e ::Boolean\n\n**Returns**\n\n- (::Boolean) --- If `inherit_from_parent` is true, Rules set higher up in the hierarchy (up to the closest root) are inherited and present in the effective policy. If it is false, then no rules are inherited, and this policy becomes the effective root for evaluation.\n\n### #inherit_from_parent=\n\n def inherit_from_parent=(value) -\u003e ::Boolean\n\n**Parameter**\n\n- **value** (::Boolean) --- If `inherit_from_parent` is true, Rules set higher up in the hierarchy (up to the closest root) are inherited and present in the effective policy. If it is false, then no rules are inherited, and this policy becomes the effective root for evaluation. \n**Returns**\n\n- (::Boolean) --- If `inherit_from_parent` is true, Rules set higher up in the hierarchy (up to the closest root) are inherited and present in the effective policy. If it is false, then no rules are inherited, and this policy becomes the effective root for evaluation.\n\n### #reset\n\n def reset() -\u003e ::Boolean\n\n**Returns**\n\n- (::Boolean) --- Ignores policies set above this resource and restores the default behavior of the constraint at this resource. This field can be set in policies for either list or boolean constraints. If set, `rules` must be empty and `inherit_from_parent` must be set to false.\n\n### #reset=\n\n def reset=(value) -\u003e ::Boolean\n\n**Parameter**\n\n- **value** (::Boolean) --- Ignores policies set above this resource and restores the default behavior of the constraint at this resource. This field can be set in policies for either list or boolean constraints. If set, `rules` must be empty and `inherit_from_parent` must be set to false. \n**Returns**\n\n- (::Boolean) --- Ignores policies set above this resource and restores the default behavior of the constraint at this resource. This field can be set in policies for either list or boolean constraints. If set, `rules` must be empty and `inherit_from_parent` must be set to false.\n\n### #rules\n\n def rules() -\u003e ::Array\u003c::Google::Cloud::Asset::V1::AnalyzerOrgPolicy::Rule\u003e\n\n**Returns**\n\n- (::Array\\\u003c[::Google::Cloud::Asset::V1::AnalyzerOrgPolicy::Rule](./Google-Cloud-Asset-V1-AnalyzerOrgPolicy-Rule)\\\u003e) --- List of rules for this organization policy.\n\n### #rules=\n\n def rules=(value) -\u003e ::Array\u003c::Google::Cloud::Asset::V1::AnalyzerOrgPolicy::Rule\u003e\n\n**Parameter**\n\n- **value** (::Array\\\u003c[::Google::Cloud::Asset::V1::AnalyzerOrgPolicy::Rule](./Google-Cloud-Asset-V1-AnalyzerOrgPolicy-Rule)\\\u003e) --- List of rules for this organization policy. \n**Returns**\n\n- (::Array\\\u003c[::Google::Cloud::Asset::V1::AnalyzerOrgPolicy::Rule](./Google-Cloud-Asset-V1-AnalyzerOrgPolicy-Rule)\\\u003e) --- List of rules for this organization policy."]]