public void setVariants(java.util.Collection<PromptVariant> variants) {
        if (variants == null) {
            this.variants = null;
            return;
        }

        this.variants = new java.util.ArrayList<PromptVariant>(variants);
    }
<p>
A list of objects, each containing details about a variant of the prompt.
</p>

@param variants
       A list of objects, each containing details about a variant of the prompt.
aws-java-sdk-bedrockagent/src/main/java/com/amazonaws/services/bedrockagent/model/CreatePromptRequest.java