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

com.softlayer.api.service.provisioning.maintenance.Classification Maven / Gradle / Ivy

The newest version!
package com.softlayer.api.service.provisioning.maintenance;

import com.softlayer.api.ApiClient;
import com.softlayer.api.ResponseHandler;
import com.softlayer.api.annotation.ApiMethod;
import com.softlayer.api.annotation.ApiProperty;
import com.softlayer.api.annotation.ApiType;
import com.softlayer.api.service.Entity;
import com.softlayer.api.service.provisioning.maintenance.classification.item.Category;
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.Future;

/**
 * The SoftLayer_Provisioning_Maintenance_Classification represent a maintenance type for the specific hardware maintenance desired. 
 *
 * @see SoftLayer_Provisioning_Maintenance_Classification
 */
@ApiType("SoftLayer_Provisioning_Maintenance_Classification")
public class Classification extends Entity {

    @ApiProperty
    protected List itemCategories;

    public List getItemCategories() {
        if (itemCategories == null) {
            itemCategories = new ArrayList();
        }
        return itemCategories;
    }

    /**
     * The id of the maintenance classification.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected Long id;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        idSpecified = true;
        this.id = id;
    }

    protected boolean idSpecified;

    public boolean isIdSpecified() {
        return idSpecified;
    }

    public void unsetId() {
        id = null;
        idSpecified = false;
    }

    /**
     * The number of slots required for the maintenance classification.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected Long slots;

    public Long getSlots() {
        return slots;
    }

    public void setSlots(Long slots) {
        slotsSpecified = true;
        this.slots = slots;
    }

    protected boolean slotsSpecified;

    public boolean isSlotsSpecified() {
        return slotsSpecified;
    }

    public void unsetSlots() {
        slots = null;
        slotsSpecified = false;
    }

    /**
     * The type or name of the maintenance classification.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String type;

    public String getType() {
        return type;
    }

    public void setType(String type) {
        typeSpecified = true;
        this.type = type;
    }

    protected boolean typeSpecified;

    public boolean isTypeSpecified() {
        return typeSpecified;
    }

    public void unsetType() {
        type = null;
        typeSpecified = false;
    }

    /**
     * A count of 
     */
    @ApiProperty
    protected Long itemCategoryCount;

    public Long getItemCategoryCount() {
        return itemCategoryCount;
    }

    public void setItemCategoryCount(Long itemCategoryCount) {
        this.itemCategoryCount = itemCategoryCount;
    }

    public Service asService(ApiClient client) {
        return service(client, id);
    }

    public static Service service(ApiClient client) {
        return client.createService(Service.class, null);
    }

    public static Service service(ApiClient client, Long id) {
        return client.createService(Service.class, id == null ? null : id.toString());
    }

    /**
     * The SoftLayer_Provisioning_Maintenance_Classification service returns available maintenance classifications. 
     *
     * @see SoftLayer_Provisioning_Maintenance_Classification
     */
    @com.softlayer.api.annotation.ApiService("SoftLayer_Provisioning_Maintenance_Classification")
    public static interface Service extends com.softlayer.api.Service {

        public ServiceAsync asAsync();
        public Mask withNewMask();
        public Mask withMask();
        public void setMask(Mask mask);

        /**
         * Retrieve an array of SoftLayer_Provisioning_Maintenance_Classification data types, which contain all maintenance classifications. 
         *
         * @see SoftLayer_Provisioning_Maintenance_Classification::getMaintenanceClassification
         */
        @ApiMethod
        public List getMaintenanceClassification(Long maintenanceClassificationId);

        /**
         * Retrieve an array of SoftLayer_Provisioning_Maintenance_Classification data types, which contain all maintenance classifications. 
         *
         * @see SoftLayer_Provisioning_Maintenance_Classification::getMaintenanceClassificationsByItemCategory
         */
        @ApiMethod
        public List getMaintenanceClassificationsByItemCategory();

        /**
         * @see SoftLayer_Provisioning_Maintenance_Classification::getObject
         */
        @ApiMethod(instanceRequired = true)
        public Classification getObject();

        /**
         * @see SoftLayer_Provisioning_Maintenance_Classification::getItemCategories
         */
        @ApiMethod(instanceRequired = true)
        public List getItemCategories();

    }

    public static interface ServiceAsync extends com.softlayer.api.ServiceAsync {

        public Mask withNewMask();
        public Mask withMask();
        public void setMask(Mask mask);

        /**
         * Async version of {@link Service#getMaintenanceClassification}
         */
        public Future> getMaintenanceClassification(Long maintenanceClassificationId);

        public Future getMaintenanceClassification(Long maintenanceClassificationId, ResponseHandler> callback);

        /**
         * Async version of {@link Service#getMaintenanceClassificationsByItemCategory}
         */
        public Future> getMaintenanceClassificationsByItemCategory();

        public Future getMaintenanceClassificationsByItemCategory(ResponseHandler> callback);

        /**
         * Async version of {@link Service#getObject}
         */
        public Future getObject();

        public Future getObject(ResponseHandler callback);

        /**
         * Async version of {@link Service#getItemCategories}
         */
        public Future> getItemCategories();

        /**
         * Async callback version of {@link Service#getItemCategories}
         */
        public Future getItemCategories(ResponseHandler> callback);

    }

    public static class Mask extends com.softlayer.api.service.Entity.Mask {

        public com.softlayer.api.service.provisioning.maintenance.classification.item.Category.Mask itemCategories() {
            return withSubMask("itemCategories", com.softlayer.api.service.provisioning.maintenance.classification.item.Category.Mask.class);
        }

        public Mask id() {
            withLocalProperty("id");
            return this;
        }

        public Mask slots() {
            withLocalProperty("slots");
            return this;
        }

        public Mask type() {
            withLocalProperty("type");
            return this;
        }

        public Mask itemCategoryCount() {
            withLocalProperty("itemCategoryCount");
            return this;
        }

    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy