Interface PolicyAssignment.DefinitionStages.WithScope
- All Known Subinterfaces:
PolicyAssignment.Definition,PolicyAssignment.DefinitionStages.Blank
- Enclosing interface:
- PolicyAssignment.DefinitionStages
public static interface PolicyAssignment.DefinitionStages.WithScope
A policy assignment specifying the scope of the policy.
-
Method Summary
Modifier and TypeMethodDescriptionforResource(GenericResource genericResource) Specifies the scope of the policy assignment to be a resource.forResourceGroup(ResourceGroup resourceGroup) Specifies the scope of the policy assignment to be a resource group.Specifies the scope of the policy assignment.
-
Method Details
-
forScope
Specifies the scope of the policy assignment.- Parameters:
scope- the scope of the policy assignment- Returns:
- the next stage of policy assignment
-
forResourceGroup
PolicyAssignment.DefinitionStages.WithPolicyDefinition forResourceGroup(ResourceGroup resourceGroup) Specifies the scope of the policy assignment to be a resource group.- Parameters:
resourceGroup- the resource group to assign the policy- Returns:
- the next stage of policy assignment
-
forResource
Specifies the scope of the policy assignment to be a resource.- Parameters:
genericResource- the resource to assign the policy- Returns:
- the next stage of policy assignment
-