Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion sdk/policyinsights/mgmt-v2019_10_01/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<groupId>com.microsoft.azure</groupId>
<artifactId>azure-arm-parent</artifactId>
<version>1.1.0</version>
<relativePath>../../parents/azure-arm-parent</relativePath>
<relativePath>../../../pom.management.xml</relativePath>
</parent>
<artifactId>azure-mgmt-policyinsights</artifactId>
<version>1.0.0-beta</version>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,306 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.policyinsights.v2019_10_01;

import com.microsoft.azure.arm.model.HasInner;
import com.microsoft.azure.management.policyinsights.v2019_10_01.implementation.AttestationInner;
import com.microsoft.azure.arm.model.Indexable;
import com.microsoft.azure.arm.model.Creatable;
import com.microsoft.azure.arm.model.Updatable;
import com.microsoft.azure.arm.model.Appliable;
import com.microsoft.azure.arm.resources.models.HasManager;
import com.microsoft.azure.management.policyinsights.v2019_10_01.implementation.PolicyInsightsManager;
import org.joda.time.DateTime;
import java.util.List;

/**
* Type representing Attestation.
*/
public interface Attestation extends HasInner<AttestationInner>, Indexable, Updatable<Attestation.Update>, HasManager<PolicyInsightsManager> {
/**
* @return the comments value.
*/
String comments();

/**
* @return the complianceState value.
*/
ComplianceState complianceState();

/**
* @return the evidence value.
*/
List<AttestationEvidence> evidence();

/**
* @return the expiresOn value.
*/
DateTime expiresOn();

/**
* @return the id value.
*/
String id();

/**
* @return the lastComplianceStateChangeAt value.
*/
DateTime lastComplianceStateChangeAt();

/**
* @return the name value.
*/
String name();

/**
* @return the owner value.
*/
String owner();

/**
* @return the policyAssignmentId value.
*/
String policyAssignmentId();

/**
* @return the policyDefinitionReferenceId value.
*/
String policyDefinitionReferenceId();

/**
* @return the provisioningState value.
*/
String provisioningState();

/**
* @return the systemData value.
*/
SystemData systemData();

/**
* @return the type value.
*/
String type();

/**
* The entirety of the Attestation definition.
*/
interface Definition extends DefinitionStages.Blank, DefinitionStages.WithSubscriptionId, DefinitionStages.WithResourceGroupName, DefinitionStages.WithPolicyAssignmentId, DefinitionStages.WithCreate {
}

/**
* Grouping of Attestation definition stages.
*/
interface DefinitionStages {
/**
* The first stage of a Attestation definition.
*/
interface Blank extends WithSubscriptionId {
}

/**
* The stage of the attestation definition allowing to specify SubscriptionId.
*/
interface WithSubscriptionId {
/**
* Specifies subscriptionId.
* @param subscriptionId The ID of the target subscription
* @return the next definition stage
*/
WithResourceGroupName withSubscriptionId(String subscriptionId);
}

/**
* The stage of the attestation definition allowing to specify ResourceGroupName.
*/
interface WithResourceGroupName {
/**
* Specifies resourceGroupName.
* @param resourceGroupName The name of the resource group. The name is case insensitive
* @return the next definition stage
*/
WithPolicyAssignmentId withResourceGroupName(String resourceGroupName);
}

/**
* The stage of the attestation definition allowing to specify PolicyAssignmentId.
*/
interface WithPolicyAssignmentId {
/**
* Specifies policyAssignmentId.
* @param policyAssignmentId The resource ID of the policy assignment that the attestation is setting the state for
* @return the next definition stage
*/
WithCreate withPolicyAssignmentId(String policyAssignmentId);
}

/**
* The stage of the attestation definition allowing to specify Comments.
*/
interface WithComments {
/**
* Specifies comments.
* @param comments Comments describing why this attestation was created
* @return the next definition stage
*/
WithCreate withComments(String comments);
}

/**
* The stage of the attestation definition allowing to specify ComplianceState.
*/
interface WithComplianceState {
/**
* Specifies complianceState.
* @param complianceState The compliance state that should be set on the resource. Possible values include: 'Compliant', 'NonCompliant', 'Unknown'
* @return the next definition stage
*/
WithCreate withComplianceState(ComplianceState complianceState);
}

/**
* The stage of the attestation definition allowing to specify Evidence.
*/
interface WithEvidence {
/**
* Specifies evidence.
* @param evidence The evidence supporting the compliance state set in this attestation
* @return the next definition stage
*/
WithCreate withEvidence(List<AttestationEvidence> evidence);
}

/**
* The stage of the attestation definition allowing to specify ExpiresOn.
*/
interface WithExpiresOn {
/**
* Specifies expiresOn.
* @param expiresOn The time the compliance state should expire
* @return the next definition stage
*/
WithCreate withExpiresOn(DateTime expiresOn);
}

/**
* The stage of the attestation definition allowing to specify Owner.
*/
interface WithOwner {
/**
* Specifies owner.
* @param owner The person responsible for setting the state of the resource. This value is typically an Azure Active Directory object ID
* @return the next definition stage
*/
WithCreate withOwner(String owner);
}

/**
* The stage of the attestation definition allowing to specify PolicyDefinitionReferenceId.
*/
interface WithPolicyDefinitionReferenceId {
/**
* Specifies policyDefinitionReferenceId.
* @param policyDefinitionReferenceId The policy definition reference ID from a policy set definition that the attestation is setting the state for. If the policy assignment assigns a policy set definition the attestation can choose a definition within the set definition with this property or omit this and set the state for the entire set definition
* @return the next definition stage
*/
WithCreate withPolicyDefinitionReferenceId(String policyDefinitionReferenceId);
}

/**
* The stage of the definition which contains all the minimum required inputs for
* the resource to be created (via {@link WithCreate#create()}), but also allows
* for any other optional settings to be specified.
*/
interface WithCreate extends Creatable<Attestation>, DefinitionStages.WithComments, DefinitionStages.WithComplianceState, DefinitionStages.WithEvidence, DefinitionStages.WithExpiresOn, DefinitionStages.WithOwner, DefinitionStages.WithPolicyDefinitionReferenceId {
}
}
/**
* The template for a Attestation update operation, containing all the settings that can be modified.
*/
interface Update extends Appliable<Attestation>, UpdateStages.WithComments, UpdateStages.WithComplianceState, UpdateStages.WithEvidence, UpdateStages.WithExpiresOn, UpdateStages.WithOwner, UpdateStages.WithPolicyDefinitionReferenceId {
}

/**
* Grouping of Attestation update stages.
*/
interface UpdateStages {
/**
* The stage of the attestation update allowing to specify Comments.
*/
interface WithComments {
/**
* Specifies comments.
* @param comments Comments describing why this attestation was created
* @return the next update stage
*/
Update withComments(String comments);
}

/**
* The stage of the attestation update allowing to specify ComplianceState.
*/
interface WithComplianceState {
/**
* Specifies complianceState.
* @param complianceState The compliance state that should be set on the resource. Possible values include: 'Compliant', 'NonCompliant', 'Unknown'
* @return the next update stage
*/
Update withComplianceState(ComplianceState complianceState);
}

/**
* The stage of the attestation update allowing to specify Evidence.
*/
interface WithEvidence {
/**
* Specifies evidence.
* @param evidence The evidence supporting the compliance state set in this attestation
* @return the next update stage
*/
Update withEvidence(List<AttestationEvidence> evidence);
}

/**
* The stage of the attestation update allowing to specify ExpiresOn.
*/
interface WithExpiresOn {
/**
* Specifies expiresOn.
* @param expiresOn The time the compliance state should expire
* @return the next update stage
*/
Update withExpiresOn(DateTime expiresOn);
}

/**
* The stage of the attestation update allowing to specify Owner.
*/
interface WithOwner {
/**
* Specifies owner.
* @param owner The person responsible for setting the state of the resource. This value is typically an Azure Active Directory object ID
* @return the next update stage
*/
Update withOwner(String owner);
}

/**
* The stage of the attestation update allowing to specify PolicyDefinitionReferenceId.
*/
interface WithPolicyDefinitionReferenceId {
/**
* Specifies policyDefinitionReferenceId.
* @param policyDefinitionReferenceId The policy definition reference ID from a policy set definition that the attestation is setting the state for. If the policy assignment assigns a policy set definition the attestation can choose a definition within the set definition with this property or omit this and set the state for the entire set definition
* @return the next update stage
*/
Update withPolicyDefinitionReferenceId(String policyDefinitionReferenceId);
}

}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.policyinsights.v2019_10_01;

import com.fasterxml.jackson.annotation.JsonProperty;

/**
* A piece of evidence supporting the compliance state set in the attestation.
*/
public class AttestationEvidence {
/**
* The description for this piece of evidence.
*/
@JsonProperty(value = "description")
private String description;

/**
* The URI location of the evidence.
*/
@JsonProperty(value = "sourceUri")
private String sourceUri;

/**
* Get the description for this piece of evidence.
*
* @return the description value
*/
public String description() {
return this.description;
}

/**
* Set the description for this piece of evidence.
*
* @param description the description value to set
* @return the AttestationEvidence object itself.
*/
public AttestationEvidence withDescription(String description) {
this.description = description;
return this;
}

/**
* Get the URI location of the evidence.
*
* @return the sourceUri value
*/
public String sourceUri() {
return this.sourceUri;
}

/**
* Set the URI location of the evidence.
*
* @param sourceUri the sourceUri value to set
* @return the AttestationEvidence object itself.
*/
public AttestationEvidence withSourceUri(String sourceUri) {
this.sourceUri = sourceUri;
return this;
}

}
Loading