/* * 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.appmesh.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.protocol.StructuredPojo; import com.amazonaws.protocol.ProtocolMarshaller; /** *
* An object that represents the specification of a virtual router. *
* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class VirtualRouterSpec implements Serializable, Cloneable, StructuredPojo { /** ** The listeners that the virtual router is expected to receive inbound traffic from. You can specify one listener. *
*/ private java.util.List* The listeners that the virtual router is expected to receive inbound traffic from. You can specify one listener. *
* * @return The listeners that the virtual router is expected to receive inbound traffic from. You can specify one * listener. */ public java.util.List* The listeners that the virtual router is expected to receive inbound traffic from. You can specify one listener. *
* * @param listeners * The listeners that the virtual router is expected to receive inbound traffic from. You can specify one * listener. */ public void setListeners(java.util.Collection* The listeners that the virtual router is expected to receive inbound traffic from. You can specify one listener. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setListeners(java.util.Collection)} or {@link #withListeners(java.util.Collection)} if you want to * override the existing values. *
* * @param listeners * The listeners that the virtual router is expected to receive inbound traffic from. You can specify one * listener. * @return Returns a reference to this object so that method calls can be chained together. */ public VirtualRouterSpec withListeners(VirtualRouterListener... listeners) { if (this.listeners == null) { setListeners(new java.util.ArrayList* The listeners that the virtual router is expected to receive inbound traffic from. You can specify one listener. *
* * @param listeners * The listeners that the virtual router is expected to receive inbound traffic from. You can specify one * listener. * @return Returns a reference to this object so that method calls can be chained together. */ public VirtualRouterSpec withListeners(java.util.Collection