/* * 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.devicefarm.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.protocol.StructuredPojo; import com.amazonaws.protocol.ProtocolMarshaller; /** *
* Represents the metadata of a device offering. *
* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class Offering implements Serializable, Cloneable, StructuredPojo { /** ** The ID that corresponds to a device offering. *
*/ private String id; /** ** A string that describes the offering. *
*/ private String description; /** *
* The type of offering (for example, RECURRING
) for a device.
*
* The platform of the device (for example, ANDROID
or IOS
).
*
* Specifies whether there are recurring charges for the offering. *
*/ private java.util.List* The ID that corresponds to a device offering. *
* * @param id * The ID that corresponds to a device offering. */ public void setId(String id) { this.id = id; } /** ** The ID that corresponds to a device offering. *
* * @return The ID that corresponds to a device offering. */ public String getId() { return this.id; } /** ** The ID that corresponds to a device offering. *
* * @param id * The ID that corresponds to a device offering. * @return Returns a reference to this object so that method calls can be chained together. */ public Offering withId(String id) { setId(id); return this; } /** ** A string that describes the offering. *
* * @param description * A string that describes the offering. */ public void setDescription(String description) { this.description = description; } /** ** A string that describes the offering. *
* * @return A string that describes the offering. */ public String getDescription() { return this.description; } /** ** A string that describes the offering. *
* * @param description * A string that describes the offering. * @return Returns a reference to this object so that method calls can be chained together. */ public Offering withDescription(String description) { setDescription(description); return this; } /** *
* The type of offering (for example, RECURRING
) for a device.
*
RECURRING
) for a device.
* @see OfferingType
*/
public void setType(String type) {
this.type = type;
}
/**
*
* The type of offering (for example, RECURRING
) for a device.
*
RECURRING
) for a device.
* @see OfferingType
*/
public String getType() {
return this.type;
}
/**
*
* The type of offering (for example, RECURRING
) for a device.
*
RECURRING
) for a device.
* @return Returns a reference to this object so that method calls can be chained together.
* @see OfferingType
*/
public Offering withType(String type) {
setType(type);
return this;
}
/**
*
* The type of offering (for example, RECURRING
) for a device.
*
RECURRING
) for a device.
* @see OfferingType
*/
public void setType(OfferingType type) {
withType(type);
}
/**
*
* The type of offering (for example, RECURRING
) for a device.
*
RECURRING
) for a device.
* @return Returns a reference to this object so that method calls can be chained together.
* @see OfferingType
*/
public Offering withType(OfferingType type) {
this.type = type.toString();
return this;
}
/**
*
* The platform of the device (for example, ANDROID
or IOS
).
*
ANDROID
or IOS
).
* @see DevicePlatform
*/
public void setPlatform(String platform) {
this.platform = platform;
}
/**
*
* The platform of the device (for example, ANDROID
or IOS
).
*
ANDROID
or IOS
).
* @see DevicePlatform
*/
public String getPlatform() {
return this.platform;
}
/**
*
* The platform of the device (for example, ANDROID
or IOS
).
*
ANDROID
or IOS
).
* @return Returns a reference to this object so that method calls can be chained together.
* @see DevicePlatform
*/
public Offering withPlatform(String platform) {
setPlatform(platform);
return this;
}
/**
*
* The platform of the device (for example, ANDROID
or IOS
).
*
ANDROID
or IOS
).
* @see DevicePlatform
*/
public void setPlatform(DevicePlatform platform) {
withPlatform(platform);
}
/**
*
* The platform of the device (for example, ANDROID
or IOS
).
*
ANDROID
or IOS
).
* @return Returns a reference to this object so that method calls can be chained together.
* @see DevicePlatform
*/
public Offering withPlatform(DevicePlatform platform) {
this.platform = platform.toString();
return this;
}
/**
* * Specifies whether there are recurring charges for the offering. *
* * @return Specifies whether there are recurring charges for the offering. */ public java.util.List* Specifies whether there are recurring charges for the offering. *
* * @param recurringCharges * Specifies whether there are recurring charges for the offering. */ public void setRecurringCharges(java.util.Collection* Specifies whether there are recurring charges for the offering. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setRecurringCharges(java.util.Collection)} or {@link #withRecurringCharges(java.util.Collection)} if you * want to override the existing values. *
* * @param recurringCharges * Specifies whether there are recurring charges for the offering. * @return Returns a reference to this object so that method calls can be chained together. */ public Offering withRecurringCharges(RecurringCharge... recurringCharges) { if (this.recurringCharges == null) { setRecurringCharges(new java.util.ArrayList* Specifies whether there are recurring charges for the offering. *
* * @param recurringCharges * Specifies whether there are recurring charges for the offering. * @return Returns a reference to this object so that method calls can be chained together. */ public Offering withRecurringCharges(java.util.Collection