/* * 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.transfer.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.AmazonWebServiceRequest; /** * * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class UpdateConnectorRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *
* The unique identifier for the connector. *
*/ private String connectorId; /** ** The URL of the partner's AS2 or SFTP endpoint. *
*/ private String url; /** ** A structure that contains the parameters for an AS2 connector object. *
*/ private As2ConnectorConfig as2Config; /** *
* With AS2, you can send files by calling StartFileTransfer
and specifying the file paths in the
* request parameter, SendFilePaths
. We use the file’s parent directory (for example, for
* --send-file-paths /bucket/dir/file.txt
, parent directory is /bucket/dir/
) to
* temporarily store a processed AS2 message file, store the MDN when we receive them from the partner, and write a
* final JSON file containing relevant metadata of the transmission. So, the AccessRole
needs to
* provide read and write access to the parent directory of the file location used in the
* StartFileTransfer
request. Additionally, you need to provide read and write access to the parent
* directory of the files that you intend to send with StartFileTransfer
.
*
* If you are using Basic authentication for your AS2 connector, the access role requires the
* secretsmanager:GetSecretValue
permission for the secret. If the secret is encrypted using a
* customer-managed key instead of the Amazon Web Services managed key in Secrets Manager, then the role also needs
* the kms:Decrypt
permission for that key.
*
* The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role that allows a connector to turn * on CloudWatch logging for Amazon S3 events. When set, you can view connector activity in your CloudWatch logs. *
*/ private String loggingRole; /** ** A structure that contains the parameters for an SFTP connector object. *
*/ private SftpConnectorConfig sftpConfig; /** ** The unique identifier for the connector. *
* * @param connectorId * The unique identifier for the connector. */ public void setConnectorId(String connectorId) { this.connectorId = connectorId; } /** ** The unique identifier for the connector. *
* * @return The unique identifier for the connector. */ public String getConnectorId() { return this.connectorId; } /** ** The unique identifier for the connector. *
* * @param connectorId * The unique identifier for the connector. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateConnectorRequest withConnectorId(String connectorId) { setConnectorId(connectorId); return this; } /** ** The URL of the partner's AS2 or SFTP endpoint. *
* * @param url * The URL of the partner's AS2 or SFTP endpoint. */ public void setUrl(String url) { this.url = url; } /** ** The URL of the partner's AS2 or SFTP endpoint. *
* * @return The URL of the partner's AS2 or SFTP endpoint. */ public String getUrl() { return this.url; } /** ** The URL of the partner's AS2 or SFTP endpoint. *
* * @param url * The URL of the partner's AS2 or SFTP endpoint. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateConnectorRequest withUrl(String url) { setUrl(url); return this; } /** ** A structure that contains the parameters for an AS2 connector object. *
* * @param as2Config * A structure that contains the parameters for an AS2 connector object. */ public void setAs2Config(As2ConnectorConfig as2Config) { this.as2Config = as2Config; } /** ** A structure that contains the parameters for an AS2 connector object. *
* * @return A structure that contains the parameters for an AS2 connector object. */ public As2ConnectorConfig getAs2Config() { return this.as2Config; } /** ** A structure that contains the parameters for an AS2 connector object. *
* * @param as2Config * A structure that contains the parameters for an AS2 connector object. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateConnectorRequest withAs2Config(As2ConnectorConfig as2Config) { setAs2Config(as2Config); return this; } /** *
* With AS2, you can send files by calling StartFileTransfer
and specifying the file paths in the
* request parameter, SendFilePaths
. We use the file’s parent directory (for example, for
* --send-file-paths /bucket/dir/file.txt
, parent directory is /bucket/dir/
) to
* temporarily store a processed AS2 message file, store the MDN when we receive them from the partner, and write a
* final JSON file containing relevant metadata of the transmission. So, the AccessRole
needs to
* provide read and write access to the parent directory of the file location used in the
* StartFileTransfer
request. Additionally, you need to provide read and write access to the parent
* directory of the files that you intend to send with StartFileTransfer
.
*
* If you are using Basic authentication for your AS2 connector, the access role requires the
* secretsmanager:GetSecretValue
permission for the secret. If the secret is encrypted using a
* customer-managed key instead of the Amazon Web Services managed key in Secrets Manager, then the role also needs
* the kms:Decrypt
permission for that key.
*
StartFileTransfer
and specifying the file paths in
* the request parameter, SendFilePaths
. We use the file’s parent directory (for example, for
* --send-file-paths /bucket/dir/file.txt
, parent directory is /bucket/dir/
) to
* temporarily store a processed AS2 message file, store the MDN when we receive them from the partner, and
* write a final JSON file containing relevant metadata of the transmission. So, the AccessRole
* needs to provide read and write access to the parent directory of the file location used in the
* StartFileTransfer
request. Additionally, you need to provide read and write access to the
* parent directory of the files that you intend to send with StartFileTransfer
.
*
* If you are using Basic authentication for your AS2 connector, the access role requires the
* secretsmanager:GetSecretValue
permission for the secret. If the secret is encrypted using a
* customer-managed key instead of the Amazon Web Services managed key in Secrets Manager, then the role also
* needs the kms:Decrypt
permission for that key.
*/
public void setAccessRole(String accessRole) {
this.accessRole = accessRole;
}
/**
*
* With AS2, you can send files by calling StartFileTransfer
and specifying the file paths in the
* request parameter, SendFilePaths
. We use the file’s parent directory (for example, for
* --send-file-paths /bucket/dir/file.txt
, parent directory is /bucket/dir/
) to
* temporarily store a processed AS2 message file, store the MDN when we receive them from the partner, and write a
* final JSON file containing relevant metadata of the transmission. So, the AccessRole
needs to
* provide read and write access to the parent directory of the file location used in the
* StartFileTransfer
request. Additionally, you need to provide read and write access to the parent
* directory of the files that you intend to send with StartFileTransfer
.
*
* If you are using Basic authentication for your AS2 connector, the access role requires the
* secretsmanager:GetSecretValue
permission for the secret. If the secret is encrypted using a
* customer-managed key instead of the Amazon Web Services managed key in Secrets Manager, then the role also needs
* the kms:Decrypt
permission for that key.
*
StartFileTransfer
and specifying the file paths in
* the request parameter, SendFilePaths
. We use the file’s parent directory (for example, for
* --send-file-paths /bucket/dir/file.txt
, parent directory is /bucket/dir/
) to
* temporarily store a processed AS2 message file, store the MDN when we receive them from the partner, and
* write a final JSON file containing relevant metadata of the transmission. So, the AccessRole
* needs to provide read and write access to the parent directory of the file location used in the
* StartFileTransfer
request. Additionally, you need to provide read and write access to the
* parent directory of the files that you intend to send with StartFileTransfer
.
*
* If you are using Basic authentication for your AS2 connector, the access role requires the
* secretsmanager:GetSecretValue
permission for the secret. If the secret is encrypted using a
* customer-managed key instead of the Amazon Web Services managed key in Secrets Manager, then the role
* also needs the kms:Decrypt
permission for that key.
*/
public String getAccessRole() {
return this.accessRole;
}
/**
*
* With AS2, you can send files by calling StartFileTransfer
and specifying the file paths in the
* request parameter, SendFilePaths
. We use the file’s parent directory (for example, for
* --send-file-paths /bucket/dir/file.txt
, parent directory is /bucket/dir/
) to
* temporarily store a processed AS2 message file, store the MDN when we receive them from the partner, and write a
* final JSON file containing relevant metadata of the transmission. So, the AccessRole
needs to
* provide read and write access to the parent directory of the file location used in the
* StartFileTransfer
request. Additionally, you need to provide read and write access to the parent
* directory of the files that you intend to send with StartFileTransfer
.
*
* If you are using Basic authentication for your AS2 connector, the access role requires the
* secretsmanager:GetSecretValue
permission for the secret. If the secret is encrypted using a
* customer-managed key instead of the Amazon Web Services managed key in Secrets Manager, then the role also needs
* the kms:Decrypt
permission for that key.
*
StartFileTransfer
and specifying the file paths in
* the request parameter, SendFilePaths
. We use the file’s parent directory (for example, for
* --send-file-paths /bucket/dir/file.txt
, parent directory is /bucket/dir/
) to
* temporarily store a processed AS2 message file, store the MDN when we receive them from the partner, and
* write a final JSON file containing relevant metadata of the transmission. So, the AccessRole
* needs to provide read and write access to the parent directory of the file location used in the
* StartFileTransfer
request. Additionally, you need to provide read and write access to the
* parent directory of the files that you intend to send with StartFileTransfer
.
*
* If you are using Basic authentication for your AS2 connector, the access role requires the
* secretsmanager:GetSecretValue
permission for the secret. If the secret is encrypted using a
* customer-managed key instead of the Amazon Web Services managed key in Secrets Manager, then the role also
* needs the kms:Decrypt
permission for that key.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateConnectorRequest withAccessRole(String accessRole) {
setAccessRole(accessRole);
return this;
}
/**
*
* The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role that allows a connector to turn * on CloudWatch logging for Amazon S3 events. When set, you can view connector activity in your CloudWatch logs. *
* * @param loggingRole * The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role that allows a connector to * turn on CloudWatch logging for Amazon S3 events. When set, you can view connector activity in your * CloudWatch logs. */ public void setLoggingRole(String loggingRole) { this.loggingRole = loggingRole; } /** ** The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role that allows a connector to turn * on CloudWatch logging for Amazon S3 events. When set, you can view connector activity in your CloudWatch logs. *
* * @return The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role that allows a connector * to turn on CloudWatch logging for Amazon S3 events. When set, you can view connector activity in your * CloudWatch logs. */ public String getLoggingRole() { return this.loggingRole; } /** ** The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role that allows a connector to turn * on CloudWatch logging for Amazon S3 events. When set, you can view connector activity in your CloudWatch logs. *
* * @param loggingRole * The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role that allows a connector to * turn on CloudWatch logging for Amazon S3 events. When set, you can view connector activity in your * CloudWatch logs. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateConnectorRequest withLoggingRole(String loggingRole) { setLoggingRole(loggingRole); return this; } /** ** A structure that contains the parameters for an SFTP connector object. *
* * @param sftpConfig * A structure that contains the parameters for an SFTP connector object. */ public void setSftpConfig(SftpConnectorConfig sftpConfig) { this.sftpConfig = sftpConfig; } /** ** A structure that contains the parameters for an SFTP connector object. *
* * @return A structure that contains the parameters for an SFTP connector object. */ public SftpConnectorConfig getSftpConfig() { return this.sftpConfig; } /** ** A structure that contains the parameters for an SFTP connector object. *
* * @param sftpConfig * A structure that contains the parameters for an SFTP connector object. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateConnectorRequest withSftpConfig(SftpConnectorConfig sftpConfig) { setSftpConfig(sftpConfig); 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 (getConnectorId() != null) sb.append("ConnectorId: ").append(getConnectorId()).append(","); if (getUrl() != null) sb.append("Url: ").append(getUrl()).append(","); if (getAs2Config() != null) sb.append("As2Config: ").append(getAs2Config()).append(","); if (getAccessRole() != null) sb.append("AccessRole: ").append(getAccessRole()).append(","); if (getLoggingRole() != null) sb.append("LoggingRole: ").append(getLoggingRole()).append(","); if (getSftpConfig() != null) sb.append("SftpConfig: ").append(getSftpConfig()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof UpdateConnectorRequest == false) return false; UpdateConnectorRequest other = (UpdateConnectorRequest) obj; if (other.getConnectorId() == null ^ this.getConnectorId() == null) return false; if (other.getConnectorId() != null && other.getConnectorId().equals(this.getConnectorId()) == false) return false; if (other.getUrl() == null ^ this.getUrl() == null) return false; if (other.getUrl() != null && other.getUrl().equals(this.getUrl()) == false) return false; if (other.getAs2Config() == null ^ this.getAs2Config() == null) return false; if (other.getAs2Config() != null && other.getAs2Config().equals(this.getAs2Config()) == false) return false; if (other.getAccessRole() == null ^ this.getAccessRole() == null) return false; if (other.getAccessRole() != null && other.getAccessRole().equals(this.getAccessRole()) == false) return false; if (other.getLoggingRole() == null ^ this.getLoggingRole() == null) return false; if (other.getLoggingRole() != null && other.getLoggingRole().equals(this.getLoggingRole()) == false) return false; if (other.getSftpConfig() == null ^ this.getSftpConfig() == null) return false; if (other.getSftpConfig() != null && other.getSftpConfig().equals(this.getSftpConfig()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getConnectorId() == null) ? 0 : getConnectorId().hashCode()); hashCode = prime * hashCode + ((getUrl() == null) ? 0 : getUrl().hashCode()); hashCode = prime * hashCode + ((getAs2Config() == null) ? 0 : getAs2Config().hashCode()); hashCode = prime * hashCode + ((getAccessRole() == null) ? 0 : getAccessRole().hashCode()); hashCode = prime * hashCode + ((getLoggingRole() == null) ? 0 : getLoggingRole().hashCode()); hashCode = prime * hashCode + ((getSftpConfig() == null) ? 0 : getSftpConfig().hashCode()); return hashCode; } @Override public UpdateConnectorRequest clone() { return (UpdateConnectorRequest) super.clone(); } }