// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.logic.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;

/** The AS2 agreement error settings. */
@Fluent
public final class AS2ErrorSettings {
    /*
     * The value indicating whether to suspend duplicate message.
     */
    @JsonProperty(value = "suspendDuplicateMessage", required = true)
    private boolean suspendDuplicateMessage;

    /*
     * The value indicating whether to resend message If MDN is not received.
     */
    @JsonProperty(value = "resendIfMDNNotReceived", required = true)
    private boolean resendIfMdnNotReceived;

    /** Creates an instance of AS2ErrorSettings class. */
    public AS2ErrorSettings() {
    }

    /**
     * Get the suspendDuplicateMessage property: The value indicating whether to suspend duplicate message.
     *
     * @return the suspendDuplicateMessage value.
     */
    public boolean suspendDuplicateMessage() {
        return this.suspendDuplicateMessage;
    }

    /**
     * Set the suspendDuplicateMessage property: The value indicating whether to suspend duplicate message.
     *
     * @param suspendDuplicateMessage the suspendDuplicateMessage value to set.
     * @return the AS2ErrorSettings object itself.
     */
    public AS2ErrorSettings withSuspendDuplicateMessage(boolean suspendDuplicateMessage) {
        this.suspendDuplicateMessage = suspendDuplicateMessage;
        return this;
    }

    /**
     * Get the resendIfMdnNotReceived property: The value indicating whether to resend message If MDN is not received.
     *
     * @return the resendIfMdnNotReceived value.
     */
    public boolean resendIfMdnNotReceived() {
        return this.resendIfMdnNotReceived;
    }

    /**
     * Set the resendIfMdnNotReceived property: The value indicating whether to resend message If MDN is not received.
     *
     * @param resendIfMdnNotReceived the resendIfMdnNotReceived value to set.
     * @return the AS2ErrorSettings object itself.
     */
    public AS2ErrorSettings withResendIfMdnNotReceived(boolean resendIfMdnNotReceived) {
        this.resendIfMdnNotReceived = resendIfMdnNotReceived;
        return this;
    }

    /**
     * Validates the instance.
     *
     * @throws IllegalArgumentException thrown if the instance is not valid.
     */
    public void validate() {
    }
}
