All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.spotinst.sdkjava.model.bl.azure.elastiGroup.V3.ElastigroupComputeConfigurationAzure Maven / Gradle / Ivy

There is a newer version: 1.0.121
Show newest version
package com.spotinst.sdkjava.model.bl.azure.elastiGroup.V3;

import com.fasterxml.jackson.annotation.JsonIgnore;

import java.util.HashSet;
import java.util.Set;

public class ElastigroupComputeConfigurationAzure {
    //region Members
    // Partial Update support
    @JsonIgnore
    private Set                         isSet;
    private String                              os;
    private ElastigroupLaunchSpecificationAzure launchSpecification;
    private ElastigroupVmSizesAzure             vmSizes;
    //endregion

    //region Constructor
    private ElastigroupComputeConfigurationAzure() {
        isSet = new HashSet<>();
    }
    //endregion

    //region Getters & Setters
    public Set getIsSet() {
        return isSet;
    }

    public void setIsSet(Set isSet) {
        this.isSet = isSet;
    }

    public String getOs() {
        return os;
    }

    public void setOs(String os) {
        isSet.add("os");
        this.os = os;
    }

    public ElastigroupVmSizesAzure getVmSizes() {
        return vmSizes;
    }

    public void setVmSizes(ElastigroupVmSizesAzure vmSizes) {
        isSet.add("vmSizes");
        this.vmSizes = vmSizes;
    }

    public ElastigroupLaunchSpecificationAzure getLaunchSpecification() {
        return launchSpecification;
    }

    public void setLaunchSpecification(ElastigroupLaunchSpecificationAzure launchSpecification) {
        isSet.add("launchSpecification");
        this.launchSpecification = launchSpecification;
    }
    //endregion

    //region Builder class
    public static class Builder {
        private ElastigroupComputeConfigurationAzure compute;

        private Builder() {
            this.compute = new ElastigroupComputeConfigurationAzure();
        }

        public static Builder get() {
            return new Builder();
        }

        public Builder setOs(final String os) {
            compute.setOs(os);
            return this;
        }

        public Builder setLaunchSpecification(final ElastigroupLaunchSpecificationAzure launchSpecification) {
            compute.setLaunchSpecification(launchSpecification);
            return this;
        }

        public Builder setVmSizes(final ElastigroupVmSizesAzure vmSizes) {
            compute.setVmSizes(vmSizes);
            return this;
        }

        public ElastigroupComputeConfigurationAzure build() {
            // TODO : Validations
            return compute;
        }
    }
    //endregion

    //region isSet methods
    // Is os Set boolean method
    @JsonIgnore
    public boolean isOsSet() {
        return isSet.contains("os");
    }

    // Is vmSizes Set boolean method
    @JsonIgnore
    public boolean isVmSizesSet() {
        return isSet.contains("vmSizes");
    }

    // Is launchSpecification Set boolean method
    @JsonIgnore
    public boolean isLaunchSpecificationSet() {
        return isSet.contains("launchSpecification");
    }
    //endregion

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy