/* * 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.simplesystemsmanagement.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 StartSessionRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *
* The managed node to connect to for the session. *
*/ private String target; /** *
* The name of the SSM document you want to use to define the type of session, input parameters, or preferences for
* the session. For example, SSM-SessionManagerRunShell
. You can call the GetDocument API to
* verify the document exists before attempting to start a session. If no document name is provided, a shell to the
* managed node is launched by default. For more information, see Start a session in the Amazon Web Services Systems Manager User Guide.
*
* The reason for connecting to the instance. This value is included in the details for the Amazon CloudWatch Events * event created when you start the session. *
*/ private String reason; /** ** The values you want to specify for the parameters defined in the Session document. *
*/ private java.util.Map* The managed node to connect to for the session. *
* * @param target * The managed node to connect to for the session. */ public void setTarget(String target) { this.target = target; } /** ** The managed node to connect to for the session. *
* * @return The managed node to connect to for the session. */ public String getTarget() { return this.target; } /** ** The managed node to connect to for the session. *
* * @param target * The managed node to connect to for the session. * @return Returns a reference to this object so that method calls can be chained together. */ public StartSessionRequest withTarget(String target) { setTarget(target); return this; } /** *
* The name of the SSM document you want to use to define the type of session, input parameters, or preferences for
* the session. For example, SSM-SessionManagerRunShell
. You can call the GetDocument API to
* verify the document exists before attempting to start a session. If no document name is provided, a shell to the
* managed node is launched by default. For more information, see Start a session in the Amazon Web Services Systems Manager User Guide.
*
SSM-SessionManagerRunShell
. You can call the
* GetDocument API to verify the document exists before attempting to start a session. If no document
* name is provided, a shell to the managed node is launched by default. For more information, see Start a session in the Amazon Web Services Systems Manager User Guide.
*/
public void setDocumentName(String documentName) {
this.documentName = documentName;
}
/**
*
* The name of the SSM document you want to use to define the type of session, input parameters, or preferences for
* the session. For example, SSM-SessionManagerRunShell
. You can call the GetDocument API to
* verify the document exists before attempting to start a session. If no document name is provided, a shell to the
* managed node is launched by default. For more information, see Start a session in the Amazon Web Services Systems Manager User Guide.
*
SSM-SessionManagerRunShell
. You can call the
* GetDocument API to verify the document exists before attempting to start a session. If no document
* name is provided, a shell to the managed node is launched by default. For more information, see Start a session in the Amazon Web Services Systems Manager User Guide.
*/
public String getDocumentName() {
return this.documentName;
}
/**
*
* The name of the SSM document you want to use to define the type of session, input parameters, or preferences for
* the session. For example, SSM-SessionManagerRunShell
. You can call the GetDocument API to
* verify the document exists before attempting to start a session. If no document name is provided, a shell to the
* managed node is launched by default. For more information, see Start a session in the Amazon Web Services Systems Manager User Guide.
*
SSM-SessionManagerRunShell
. You can call the
* GetDocument API to verify the document exists before attempting to start a session. If no document
* name is provided, a shell to the managed node is launched by default. For more information, see Start a session in the Amazon Web Services Systems Manager User Guide.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public StartSessionRequest withDocumentName(String documentName) {
setDocumentName(documentName);
return this;
}
/**
* * The reason for connecting to the instance. This value is included in the details for the Amazon CloudWatch Events * event created when you start the session. *
* * @param reason * The reason for connecting to the instance. This value is included in the details for the Amazon CloudWatch * Events event created when you start the session. */ public void setReason(String reason) { this.reason = reason; } /** ** The reason for connecting to the instance. This value is included in the details for the Amazon CloudWatch Events * event created when you start the session. *
* * @return The reason for connecting to the instance. This value is included in the details for the Amazon * CloudWatch Events event created when you start the session. */ public String getReason() { return this.reason; } /** ** The reason for connecting to the instance. This value is included in the details for the Amazon CloudWatch Events * event created when you start the session. *
* * @param reason * The reason for connecting to the instance. This value is included in the details for the Amazon CloudWatch * Events event created when you start the session. * @return Returns a reference to this object so that method calls can be chained together. */ public StartSessionRequest withReason(String reason) { setReason(reason); return this; } /** ** The values you want to specify for the parameters defined in the Session document. *
* * @return The values you want to specify for the parameters defined in the Session document. */ public java.util.Map* The values you want to specify for the parameters defined in the Session document. *
* * @param parameters * The values you want to specify for the parameters defined in the Session document. */ public void setParameters(java.util.Map* The values you want to specify for the parameters defined in the Session document. *
* * @param parameters * The values you want to specify for the parameters defined in the Session document. * @return Returns a reference to this object so that method calls can be chained together. */ public StartSessionRequest withParameters(java.util.Map