All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.route53resolver.model.ResolverQueryLogConfigAssociation Maven / Gradle / Ivy

/*
 * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */
package com.amazonaws.services.route53resolver.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* In the response to an AssociateResolverQueryLogConfig, DisassociateResolverQueryLogConfig, GetResolverQueryLogConfigAssociation, or ListResolverQueryLogConfigAssociations, request, a complex type that contains settings for a specified * association between an Amazon VPC and a query logging configuration. *

* * @see AWS API Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class ResolverQueryLogConfigAssociation implements Serializable, Cloneable, StructuredPojo { /** *

* The ID of the query logging association. *

*/ private String id; /** *

* The ID of the query logging configuration that a VPC is associated with. *

*/ private String resolverQueryLogConfigId; /** *

* The ID of the Amazon VPC that is associated with the query logging configuration. *

*/ private String resourceId; /** *

* The status of the specified query logging association. Valid values include the following: *

*
    *
  • *

    * CREATING: Resolver is creating an association between an Amazon VPC and a query logging * configuration. *

    *
  • *
  • *

    * CREATED: The association between an Amazon VPC and a query logging configuration was successfully * created. Resolver is logging queries that originate in the specified VPC. *

    *
  • *
  • *

    * DELETING: Resolver is deleting this query logging association. *

    *
  • *
  • *

    * FAILED: Resolver either couldn't create or couldn't delete the query logging association. *

    *
  • *
*/ private String status; /** *

* If the value of Status is FAILED, the value of Error indicates the cause: *

*
    *
  • *

    * DESTINATION_NOT_FOUND: The specified destination (for example, an Amazon S3 bucket) was deleted. *

    *
  • *
  • *

    * ACCESS_DENIED: Permissions don't allow sending logs to the destination. *

    *
  • *
*

* If the value of Status is a value other than FAILED, Error is null. *

*/ private String error; /** *

* Contains additional information about the error. If the value or Error is null, the value of * ErrorMessage also is null. *

*/ private String errorMessage; /** *

* The date and time that the VPC was associated with the query logging configuration, in Unix time format and * Coordinated Universal Time (UTC). *

*/ private String creationTime; /** *

* The ID of the query logging association. *

* * @param id * The ID of the query logging association. */ public void setId(String id) { this.id = id; } /** *

* The ID of the query logging association. *

* * @return The ID of the query logging association. */ public String getId() { return this.id; } /** *

* The ID of the query logging association. *

* * @param id * The ID of the query logging association. * @return Returns a reference to this object so that method calls can be chained together. */ public ResolverQueryLogConfigAssociation withId(String id) { setId(id); return this; } /** *

* The ID of the query logging configuration that a VPC is associated with. *

* * @param resolverQueryLogConfigId * The ID of the query logging configuration that a VPC is associated with. */ public void setResolverQueryLogConfigId(String resolverQueryLogConfigId) { this.resolverQueryLogConfigId = resolverQueryLogConfigId; } /** *

* The ID of the query logging configuration that a VPC is associated with. *

* * @return The ID of the query logging configuration that a VPC is associated with. */ public String getResolverQueryLogConfigId() { return this.resolverQueryLogConfigId; } /** *

* The ID of the query logging configuration that a VPC is associated with. *

* * @param resolverQueryLogConfigId * The ID of the query logging configuration that a VPC is associated with. * @return Returns a reference to this object so that method calls can be chained together. */ public ResolverQueryLogConfigAssociation withResolverQueryLogConfigId(String resolverQueryLogConfigId) { setResolverQueryLogConfigId(resolverQueryLogConfigId); return this; } /** *

* The ID of the Amazon VPC that is associated with the query logging configuration. *

* * @param resourceId * The ID of the Amazon VPC that is associated with the query logging configuration. */ public void setResourceId(String resourceId) { this.resourceId = resourceId; } /** *

* The ID of the Amazon VPC that is associated with the query logging configuration. *

* * @return The ID of the Amazon VPC that is associated with the query logging configuration. */ public String getResourceId() { return this.resourceId; } /** *

* The ID of the Amazon VPC that is associated with the query logging configuration. *

* * @param resourceId * The ID of the Amazon VPC that is associated with the query logging configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public ResolverQueryLogConfigAssociation withResourceId(String resourceId) { setResourceId(resourceId); return this; } /** *

* The status of the specified query logging association. Valid values include the following: *

*
    *
  • *

    * CREATING: Resolver is creating an association between an Amazon VPC and a query logging * configuration. *

    *
  • *
  • *

    * CREATED: The association between an Amazon VPC and a query logging configuration was successfully * created. Resolver is logging queries that originate in the specified VPC. *

    *
  • *
  • *

    * DELETING: Resolver is deleting this query logging association. *

    *
  • *
  • *

    * FAILED: Resolver either couldn't create or couldn't delete the query logging association. *

    *
  • *
* * @param status * The status of the specified query logging association. Valid values include the following:

*
    *
  • *

    * CREATING: Resolver is creating an association between an Amazon VPC and a query logging * configuration. *

    *
  • *
  • *

    * CREATED: The association between an Amazon VPC and a query logging configuration was * successfully created. Resolver is logging queries that originate in the specified VPC. *

    *
  • *
  • *

    * DELETING: Resolver is deleting this query logging association. *

    *
  • *
  • *

    * FAILED: Resolver either couldn't create or couldn't delete the query logging association. *

    *
  • * @see ResolverQueryLogConfigAssociationStatus */ public void setStatus(String status) { this.status = status; } /** *

    * The status of the specified query logging association. Valid values include the following: *

    *
      *
    • *

      * CREATING: Resolver is creating an association between an Amazon VPC and a query logging * configuration. *

      *
    • *
    • *

      * CREATED: The association between an Amazon VPC and a query logging configuration was successfully * created. Resolver is logging queries that originate in the specified VPC. *

      *
    • *
    • *

      * DELETING: Resolver is deleting this query logging association. *

      *
    • *
    • *

      * FAILED: Resolver either couldn't create or couldn't delete the query logging association. *

      *
    • *
    * * @return The status of the specified query logging association. Valid values include the following:

    *
      *
    • *

      * CREATING: Resolver is creating an association between an Amazon VPC and a query logging * configuration. *

      *
    • *
    • *

      * CREATED: The association between an Amazon VPC and a query logging configuration was * successfully created. Resolver is logging queries that originate in the specified VPC. *

      *
    • *
    • *

      * DELETING: Resolver is deleting this query logging association. *

      *
    • *
    • *

      * FAILED: Resolver either couldn't create or couldn't delete the query logging association. *

      *
    • * @see ResolverQueryLogConfigAssociationStatus */ public String getStatus() { return this.status; } /** *

      * The status of the specified query logging association. Valid values include the following: *

      *
        *
      • *

        * CREATING: Resolver is creating an association between an Amazon VPC and a query logging * configuration. *

        *
      • *
      • *

        * CREATED: The association between an Amazon VPC and a query logging configuration was successfully * created. Resolver is logging queries that originate in the specified VPC. *

        *
      • *
      • *

        * DELETING: Resolver is deleting this query logging association. *

        *
      • *
      • *

        * FAILED: Resolver either couldn't create or couldn't delete the query logging association. *

        *
      • *
      * * @param status * The status of the specified query logging association. Valid values include the following:

      *
        *
      • *

        * CREATING: Resolver is creating an association between an Amazon VPC and a query logging * configuration. *

        *
      • *
      • *

        * CREATED: The association between an Amazon VPC and a query logging configuration was * successfully created. Resolver is logging queries that originate in the specified VPC. *

        *
      • *
      • *

        * DELETING: Resolver is deleting this query logging association. *

        *
      • *
      • *

        * FAILED: Resolver either couldn't create or couldn't delete the query logging association. *

        *
      • * @return Returns a reference to this object so that method calls can be chained together. * @see ResolverQueryLogConfigAssociationStatus */ public ResolverQueryLogConfigAssociation withStatus(String status) { setStatus(status); return this; } /** *

        * The status of the specified query logging association. Valid values include the following: *

        *
          *
        • *

          * CREATING: Resolver is creating an association between an Amazon VPC and a query logging * configuration. *

          *
        • *
        • *

          * CREATED: The association between an Amazon VPC and a query logging configuration was successfully * created. Resolver is logging queries that originate in the specified VPC. *

          *
        • *
        • *

          * DELETING: Resolver is deleting this query logging association. *

          *
        • *
        • *

          * FAILED: Resolver either couldn't create or couldn't delete the query logging association. *

          *
        • *
        * * @param status * The status of the specified query logging association. Valid values include the following:

        *
          *
        • *

          * CREATING: Resolver is creating an association between an Amazon VPC and a query logging * configuration. *

          *
        • *
        • *

          * CREATED: The association between an Amazon VPC and a query logging configuration was * successfully created. Resolver is logging queries that originate in the specified VPC. *

          *
        • *
        • *

          * DELETING: Resolver is deleting this query logging association. *

          *
        • *
        • *

          * FAILED: Resolver either couldn't create or couldn't delete the query logging association. *

          *
        • * @return Returns a reference to this object so that method calls can be chained together. * @see ResolverQueryLogConfigAssociationStatus */ public ResolverQueryLogConfigAssociation withStatus(ResolverQueryLogConfigAssociationStatus status) { this.status = status.toString(); return this; } /** *

          * If the value of Status is FAILED, the value of Error indicates the cause: *

          *
            *
          • *

            * DESTINATION_NOT_FOUND: The specified destination (for example, an Amazon S3 bucket) was deleted. *

            *
          • *
          • *

            * ACCESS_DENIED: Permissions don't allow sending logs to the destination. *

            *
          • *
          *

          * If the value of Status is a value other than FAILED, Error is null. *

          * * @param error * If the value of Status is FAILED, the value of Error indicates the * cause:

          *
            *
          • *

            * DESTINATION_NOT_FOUND: The specified destination (for example, an Amazon S3 bucket) was * deleted. *

            *
          • *
          • *

            * ACCESS_DENIED: Permissions don't allow sending logs to the destination. *

            *
          • *
          *

          * If the value of Status is a value other than FAILED, Error is null. * @see ResolverQueryLogConfigAssociationError */ public void setError(String error) { this.error = error; } /** *

          * If the value of Status is FAILED, the value of Error indicates the cause: *

          *
            *
          • *

            * DESTINATION_NOT_FOUND: The specified destination (for example, an Amazon S3 bucket) was deleted. *

            *
          • *
          • *

            * ACCESS_DENIED: Permissions don't allow sending logs to the destination. *

            *
          • *
          *

          * If the value of Status is a value other than FAILED, Error is null. *

          * * @return If the value of Status is FAILED, the value of Error indicates the * cause:

          *
            *
          • *

            * DESTINATION_NOT_FOUND: The specified destination (for example, an Amazon S3 bucket) was * deleted. *

            *
          • *
          • *

            * ACCESS_DENIED: Permissions don't allow sending logs to the destination. *

            *
          • *
          *

          * If the value of Status is a value other than FAILED, Error is * null. * @see ResolverQueryLogConfigAssociationError */ public String getError() { return this.error; } /** *

          * If the value of Status is FAILED, the value of Error indicates the cause: *

          *
            *
          • *

            * DESTINATION_NOT_FOUND: The specified destination (for example, an Amazon S3 bucket) was deleted. *

            *
          • *
          • *

            * ACCESS_DENIED: Permissions don't allow sending logs to the destination. *

            *
          • *
          *

          * If the value of Status is a value other than FAILED, Error is null. *

          * * @param error * If the value of Status is FAILED, the value of Error indicates the * cause:

          *
            *
          • *

            * DESTINATION_NOT_FOUND: The specified destination (for example, an Amazon S3 bucket) was * deleted. *

            *
          • *
          • *

            * ACCESS_DENIED: Permissions don't allow sending logs to the destination. *

            *
          • *
          *

          * If the value of Status is a value other than FAILED, Error is null. * @return Returns a reference to this object so that method calls can be chained together. * @see ResolverQueryLogConfigAssociationError */ public ResolverQueryLogConfigAssociation withError(String error) { setError(error); return this; } /** *

          * If the value of Status is FAILED, the value of Error indicates the cause: *

          *
            *
          • *

            * DESTINATION_NOT_FOUND: The specified destination (for example, an Amazon S3 bucket) was deleted. *

            *
          • *
          • *

            * ACCESS_DENIED: Permissions don't allow sending logs to the destination. *

            *
          • *
          *

          * If the value of Status is a value other than FAILED, Error is null. *

          * * @param error * If the value of Status is FAILED, the value of Error indicates the * cause:

          *
            *
          • *

            * DESTINATION_NOT_FOUND: The specified destination (for example, an Amazon S3 bucket) was * deleted. *

            *
          • *
          • *

            * ACCESS_DENIED: Permissions don't allow sending logs to the destination. *

            *
          • *
          *

          * If the value of Status is a value other than FAILED, Error is null. * @return Returns a reference to this object so that method calls can be chained together. * @see ResolverQueryLogConfigAssociationError */ public ResolverQueryLogConfigAssociation withError(ResolverQueryLogConfigAssociationError error) { this.error = error.toString(); return this; } /** *

          * Contains additional information about the error. If the value or Error is null, the value of * ErrorMessage also is null. *

          * * @param errorMessage * Contains additional information about the error. If the value or Error is null, the value of * ErrorMessage also is null. */ public void setErrorMessage(String errorMessage) { this.errorMessage = errorMessage; } /** *

          * Contains additional information about the error. If the value or Error is null, the value of * ErrorMessage also is null. *

          * * @return Contains additional information about the error. If the value or Error is null, the value of * ErrorMessage also is null. */ public String getErrorMessage() { return this.errorMessage; } /** *

          * Contains additional information about the error. If the value or Error is null, the value of * ErrorMessage also is null. *

          * * @param errorMessage * Contains additional information about the error. If the value or Error is null, the value of * ErrorMessage also is null. * @return Returns a reference to this object so that method calls can be chained together. */ public ResolverQueryLogConfigAssociation withErrorMessage(String errorMessage) { setErrorMessage(errorMessage); return this; } /** *

          * The date and time that the VPC was associated with the query logging configuration, in Unix time format and * Coordinated Universal Time (UTC). *

          * * @param creationTime * The date and time that the VPC was associated with the query logging configuration, in Unix time format * and Coordinated Universal Time (UTC). */ public void setCreationTime(String creationTime) { this.creationTime = creationTime; } /** *

          * The date and time that the VPC was associated with the query logging configuration, in Unix time format and * Coordinated Universal Time (UTC). *

          * * @return The date and time that the VPC was associated with the query logging configuration, in Unix time format * and Coordinated Universal Time (UTC). */ public String getCreationTime() { return this.creationTime; } /** *

          * The date and time that the VPC was associated with the query logging configuration, in Unix time format and * Coordinated Universal Time (UTC). *

          * * @param creationTime * The date and time that the VPC was associated with the query logging configuration, in Unix time format * and Coordinated Universal Time (UTC). * @return Returns a reference to this object so that method calls can be chained together. */ public ResolverQueryLogConfigAssociation withCreationTime(String creationTime) { setCreationTime(creationTime); return this; } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getId() != null) sb.append("Id: ").append(getId()).append(","); if (getResolverQueryLogConfigId() != null) sb.append("ResolverQueryLogConfigId: ").append(getResolverQueryLogConfigId()).append(","); if (getResourceId() != null) sb.append("ResourceId: ").append(getResourceId()).append(","); if (getStatus() != null) sb.append("Status: ").append(getStatus()).append(","); if (getError() != null) sb.append("Error: ").append(getError()).append(","); if (getErrorMessage() != null) sb.append("ErrorMessage: ").append(getErrorMessage()).append(","); if (getCreationTime() != null) sb.append("CreationTime: ").append(getCreationTime()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof ResolverQueryLogConfigAssociation == false) return false; ResolverQueryLogConfigAssociation other = (ResolverQueryLogConfigAssociation) obj; if (other.getId() == null ^ this.getId() == null) return false; if (other.getId() != null && other.getId().equals(this.getId()) == false) return false; if (other.getResolverQueryLogConfigId() == null ^ this.getResolverQueryLogConfigId() == null) return false; if (other.getResolverQueryLogConfigId() != null && other.getResolverQueryLogConfigId().equals(this.getResolverQueryLogConfigId()) == false) return false; if (other.getResourceId() == null ^ this.getResourceId() == null) return false; if (other.getResourceId() != null && other.getResourceId().equals(this.getResourceId()) == false) return false; if (other.getStatus() == null ^ this.getStatus() == null) return false; if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == false) return false; if (other.getError() == null ^ this.getError() == null) return false; if (other.getError() != null && other.getError().equals(this.getError()) == false) return false; if (other.getErrorMessage() == null ^ this.getErrorMessage() == null) return false; if (other.getErrorMessage() != null && other.getErrorMessage().equals(this.getErrorMessage()) == false) return false; if (other.getCreationTime() == null ^ this.getCreationTime() == null) return false; if (other.getCreationTime() != null && other.getCreationTime().equals(this.getCreationTime()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getId() == null) ? 0 : getId().hashCode()); hashCode = prime * hashCode + ((getResolverQueryLogConfigId() == null) ? 0 : getResolverQueryLogConfigId().hashCode()); hashCode = prime * hashCode + ((getResourceId() == null) ? 0 : getResourceId().hashCode()); hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); hashCode = prime * hashCode + ((getError() == null) ? 0 : getError().hashCode()); hashCode = prime * hashCode + ((getErrorMessage() == null) ? 0 : getErrorMessage().hashCode()); hashCode = prime * hashCode + ((getCreationTime() == null) ? 0 : getCreationTime().hashCode()); return hashCode; } @Override public ResolverQueryLogConfigAssociation clone() { try { return (ResolverQueryLogConfigAssociation) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.route53resolver.model.transform.ResolverQueryLogConfigAssociationMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy