com.softlayer.api.service.virtual.DedicatedHost Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of softlayer-api-client Show documentation
Show all versions of softlayer-api-client Show documentation
API client for accessing the SoftLayer API
package com.softlayer.api.service.virtual;
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.Account;
import com.softlayer.api.service.Entity;
import com.softlayer.api.service.Hardware;
import com.softlayer.api.service.Location;
import com.softlayer.api.service.container.virtual.dedicatedhost.pci.device.AllocationStatus;
import com.softlayer.api.service.hardware.router.Backend;
import com.softlayer.api.service.tag.Reference;
import com.softlayer.api.service.virtual.Guest;
import com.softlayer.api.service.virtual.host.PciDevice;
import java.util.ArrayList;
import java.util.GregorianCalendar;
import java.util.List;
import java.util.concurrent.Future;
/**
* This data type presents the structure for a dedicated host. The data type contains relational properties to distinguish a dedicated host and associate an account to it.
*
* @see SoftLayer_Virtual_DedicatedHost
*/
@ApiType("SoftLayer_Virtual_DedicatedHost")
public class DedicatedHost extends Entity {
/**
* The account that the dedicated host belongs to.
*/
@ApiProperty
protected Account account;
public Account getAccount() {
return account;
}
public void setAccount(Account account) {
this.account = account;
}
/**
* The container that represents allocations on the dedicated host.
*/
@ApiProperty
protected com.softlayer.api.service.container.virtual.dedicatedhost.AllocationStatus allocationStatus;
public com.softlayer.api.service.container.virtual.dedicatedhost.AllocationStatus getAllocationStatus() {
return allocationStatus;
}
public void setAllocationStatus(com.softlayer.api.service.container.virtual.dedicatedhost.AllocationStatus allocationStatus) {
this.allocationStatus = allocationStatus;
}
/**
* The backend router behind dedicated host's pool of resources.
*/
@ApiProperty
protected Backend backendRouter;
public Backend getBackendRouter() {
return backendRouter;
}
public void setBackendRouter(Backend backendRouter) {
this.backendRouter = backendRouter;
}
/**
* The billing item for the dedicated host.
*/
@ApiProperty
protected com.softlayer.api.service.billing.item.virtual.DedicatedHost billingItem;
public com.softlayer.api.service.billing.item.virtual.DedicatedHost getBillingItem() {
return billingItem;
}
public void setBillingItem(com.softlayer.api.service.billing.item.virtual.DedicatedHost billingItem) {
this.billingItem = billingItem;
}
/**
* The datacenter that the dedicated host resides in.
*/
@ApiProperty
protected Location datacenter;
public Location getDatacenter() {
return datacenter;
}
public void setDatacenter(Location datacenter) {
this.datacenter = datacenter;
}
/**
* The guests associated with the dedicated host.
*/
@ApiProperty
protected List guests;
public List getGuests() {
if (guests == null) {
guests = new ArrayList();
}
return guests;
}
@ApiProperty
protected List internalTagReferences;
public List getInternalTagReferences() {
if (internalTagReferences == null) {
internalTagReferences = new ArrayList();
}
return internalTagReferences;
}
/**
* The container that represents PCI device allocations on the dedicated host.
*/
@ApiProperty
protected AllocationStatus pciDeviceAllocationStatus;
public AllocationStatus getPciDeviceAllocationStatus() {
return pciDeviceAllocationStatus;
}
public void setPciDeviceAllocationStatus(AllocationStatus pciDeviceAllocationStatus) {
this.pciDeviceAllocationStatus = pciDeviceAllocationStatus;
}
/**
* A collection of SoftLayer_Virtual_Host_PciDevice objects on the host.
*/
@ApiProperty
protected List pciDevices;
public List getPciDevices() {
if (pciDevices == null) {
pciDevices = new ArrayList();
}
return pciDevices;
}
@ApiProperty
protected List tagReferences;
public List getTagReferences() {
if (tagReferences == null) {
tagReferences = new ArrayList();
}
return tagReferences;
}
/**
* The dedicated host's associated account id.
*/
@ApiProperty(canBeNullOrNotSet = true)
protected Long accountId;
public Long getAccountId() {
return accountId;
}
public void setAccountId(Long accountId) {
accountIdSpecified = true;
this.accountId = accountId;
}
protected boolean accountIdSpecified;
public boolean isAccountIdSpecified() {
return accountIdSpecified;
}
public void unsetAccountId() {
accountId = null;
accountIdSpecified = false;
}
/**
* The capacity that the dedicated host's CPU allocation is restricted to.
*/
@ApiProperty(canBeNullOrNotSet = true)
protected Long cpuCount;
public Long getCpuCount() {
return cpuCount;
}
public void setCpuCount(Long cpuCount) {
cpuCountSpecified = true;
this.cpuCount = cpuCount;
}
protected boolean cpuCountSpecified;
public boolean isCpuCountSpecified() {
return cpuCountSpecified;
}
public void unsetCpuCount() {
cpuCount = null;
cpuCountSpecified = false;
}
/**
* The date that the dedicated host was created.
*/
@ApiProperty(canBeNullOrNotSet = true)
protected GregorianCalendar createDate;
public GregorianCalendar getCreateDate() {
return createDate;
}
public void setCreateDate(GregorianCalendar createDate) {
createDateSpecified = true;
this.createDate = createDate;
}
protected boolean createDateSpecified;
public boolean isCreateDateSpecified() {
return createDateSpecified;
}
public void unsetCreateDate() {
createDate = null;
createDateSpecified = false;
}
/**
* The capacity that the dedicated host's disk allocation is restricted to.
*/
@ApiProperty(canBeNullOrNotSet = true)
protected Long diskCapacity;
public Long getDiskCapacity() {
return diskCapacity;
}
public void setDiskCapacity(Long diskCapacity) {
diskCapacitySpecified = true;
this.diskCapacity = diskCapacity;
}
protected boolean diskCapacitySpecified;
public boolean isDiskCapacitySpecified() {
return diskCapacitySpecified;
}
public void unsetDiskCapacity() {
diskCapacity = null;
diskCapacitySpecified = false;
}
/**
* The dedicated host's associated unique id.
*/
@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 capacity that the dedicated host's memory allocation is restricted to.
*/
@ApiProperty(canBeNullOrNotSet = true)
protected Long memoryCapacity;
public Long getMemoryCapacity() {
return memoryCapacity;
}
public void setMemoryCapacity(Long memoryCapacity) {
memoryCapacitySpecified = true;
this.memoryCapacity = memoryCapacity;
}
protected boolean memoryCapacitySpecified;
public boolean isMemoryCapacitySpecified() {
return memoryCapacitySpecified;
}
public void unsetMemoryCapacity() {
memoryCapacity = null;
memoryCapacitySpecified = false;
}
/**
* The date that the dedicated host was last modified.
*/
@ApiProperty(canBeNullOrNotSet = true)
protected GregorianCalendar modifyDate;
public GregorianCalendar getModifyDate() {
return modifyDate;
}
public void setModifyDate(GregorianCalendar modifyDate) {
modifyDateSpecified = true;
this.modifyDate = modifyDate;
}
protected boolean modifyDateSpecified;
public boolean isModifyDateSpecified() {
return modifyDateSpecified;
}
public void unsetModifyDate() {
modifyDate = null;
modifyDateSpecified = false;
}
/**
* The dedicated host's name.
*/
@ApiProperty(canBeNullOrNotSet = true)
protected String name;
public String getName() {
return name;
}
public void setName(String name) {
nameSpecified = true;
this.name = name;
}
protected boolean nameSpecified;
public boolean isNameSpecified() {
return nameSpecified;
}
public void unsetName() {
name = null;
nameSpecified = false;
}
/**
* A note of up to 1,000 characters about a dedicated host.
*/
@ApiProperty(canBeNullOrNotSet = true)
protected String notes;
public String getNotes() {
return notes;
}
public void setNotes(String notes) {
notesSpecified = true;
this.notes = notes;
}
protected boolean notesSpecified;
public boolean isNotesSpecified() {
return notesSpecified;
}
public void unsetNotes() {
notes = null;
notesSpecified = false;
}
/**
* A count of the guests associated with the dedicated host.
*/
@ApiProperty
protected Long guestCount;
public Long getGuestCount() {
return guestCount;
}
public void setGuestCount(Long guestCount) {
this.guestCount = guestCount;
}
/**
* A count of
*/
@ApiProperty
protected Long internalTagReferenceCount;
public Long getInternalTagReferenceCount() {
return internalTagReferenceCount;
}
public void setInternalTagReferenceCount(Long internalTagReferenceCount) {
this.internalTagReferenceCount = internalTagReferenceCount;
}
/**
* A count of a collection of SoftLayer_Virtual_Host_PciDevice objects on the host.
*/
@ApiProperty
protected Long pciDeviceCount;
public Long getPciDeviceCount() {
return pciDeviceCount;
}
public void setPciDeviceCount(Long pciDeviceCount) {
this.pciDeviceCount = pciDeviceCount;
}
/**
* A count of
*/
@ApiProperty
protected Long tagReferenceCount;
public Long getTagReferenceCount() {
return tagReferenceCount;
}
public void setTagReferenceCount(Long tagReferenceCount) {
this.tagReferenceCount = tagReferenceCount;
}
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());
}
/**
* SoftLayer_Virtual_DedicatedHost models a single tenant virtual host dedicated to a specific account.
*
* @see SoftLayer_Virtual_DedicatedHost
*/
@com.softlayer.api.annotation.ApiService("SoftLayer_Virtual_DedicatedHost")
public static interface Service extends com.softlayer.api.Service {
public ServiceAsync asAsync();
public Mask withNewMask();
public Mask withMask();
public void setMask(Mask mask);
/**
* This method will cancel a dedicated host immediately.
*
* @see SoftLayer_Virtual_DedicatedHost::deleteObject
*/
@ApiMethod(instanceRequired = true)
public Boolean deleteObject();
/**
* Edit a dedicated host's properties.
*
* @see SoftLayer_Virtual_DedicatedHost::editObject
*/
@ApiMethod(instanceRequired = true)
public Boolean editObject(DedicatedHost templateObject);
/**
* This method will get the available backend routers to order a dedicated host.
*
* @see SoftLayer_Virtual_DedicatedHost::getAvailableRouters
*/
@ApiMethod
public List getAvailableRouters(DedicatedHost dedicatedHost);
/**
* @see SoftLayer_Virtual_DedicatedHost::getObject
*/
@ApiMethod(instanceRequired = true)
public DedicatedHost getObject();
/**
* @see SoftLayer_Virtual_DedicatedHost::setTags
*/
@ApiMethod(instanceRequired = true)
public Boolean setTags(String tags);
/**
* The account that the dedicated host belongs to.
*
* @see SoftLayer_Virtual_DedicatedHost::getAccount
*/
@ApiMethod(instanceRequired = true)
public Account getAccount();
/**
* The container that represents allocations on the dedicated host.
*
* @see SoftLayer_Virtual_DedicatedHost::getAllocationStatus
*/
@ApiMethod(instanceRequired = true)
public com.softlayer.api.service.container.virtual.dedicatedhost.AllocationStatus getAllocationStatus();
/**
* The backend router behind dedicated host's pool of resources.
*
* @see SoftLayer_Virtual_DedicatedHost::getBackendRouter
*/
@ApiMethod(instanceRequired = true)
public Backend getBackendRouter();
/**
* The billing item for the dedicated host.
*
* @see SoftLayer_Virtual_DedicatedHost::getBillingItem
*/
@ApiMethod(instanceRequired = true)
public com.softlayer.api.service.billing.item.virtual.DedicatedHost getBillingItem();
/**
* The datacenter that the dedicated host resides in.
*
* @see SoftLayer_Virtual_DedicatedHost::getDatacenter
*/
@ApiMethod(instanceRequired = true)
public Location getDatacenter();
/**
* The guests associated with the dedicated host.
*
* @see SoftLayer_Virtual_DedicatedHost::getGuests
*/
@ApiMethod(instanceRequired = true)
public List getGuests();
/**
* @see SoftLayer_Virtual_DedicatedHost::getInternalTagReferences
*/
@ApiMethod(instanceRequired = true)
public List getInternalTagReferences();
/**
* The container that represents PCI device allocations on the dedicated host.
*
* @see SoftLayer_Virtual_DedicatedHost::getPciDeviceAllocationStatus
*/
@ApiMethod(instanceRequired = true)
public AllocationStatus getPciDeviceAllocationStatus();
/**
* A collection of SoftLayer_Virtual_Host_PciDevice objects on the host.
*
* @see SoftLayer_Virtual_DedicatedHost::getPciDevices
*/
@ApiMethod(instanceRequired = true)
public List getPciDevices();
/**
* @see SoftLayer_Virtual_DedicatedHost::getTagReferences
*/
@ApiMethod(instanceRequired = true)
public List getTagReferences();
}
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#deleteObject}
*/
public Future deleteObject();
public Future> deleteObject(ResponseHandler callback);
/**
* Async version of {@link Service#editObject}
*/
public Future editObject(DedicatedHost templateObject);
public Future> editObject(DedicatedHost templateObject, ResponseHandler callback);
/**
* Async version of {@link Service#getAvailableRouters}
*/
public Future> getAvailableRouters(DedicatedHost dedicatedHost);
public Future> getAvailableRouters(DedicatedHost dedicatedHost, ResponseHandler> callback);
/**
* Async version of {@link Service#getObject}
*/
public Future getObject();
public Future> getObject(ResponseHandler callback);
/**
* Async version of {@link Service#setTags}
*/
public Future setTags(String tags);
public Future> setTags(String tags, ResponseHandler callback);
/**
* Async version of {@link Service#getAccount}
*/
public Future getAccount();
/**
* Async callback version of {@link Service#getAccount}
*/
public Future> getAccount(ResponseHandler callback);
/**
* Async version of {@link Service#getAllocationStatus}
*/
public Future getAllocationStatus();
/**
* Async callback version of {@link Service#getAllocationStatus}
*/
public Future> getAllocationStatus(ResponseHandler callback);
/**
* Async version of {@link Service#getBackendRouter}
*/
public Future getBackendRouter();
/**
* Async callback version of {@link Service#getBackendRouter}
*/
public Future> getBackendRouter(ResponseHandler callback);
/**
* Async version of {@link Service#getBillingItem}
*/
public Future getBillingItem();
/**
* Async callback version of {@link Service#getBillingItem}
*/
public Future> getBillingItem(ResponseHandler callback);
/**
* Async version of {@link Service#getDatacenter}
*/
public Future getDatacenter();
/**
* Async callback version of {@link Service#getDatacenter}
*/
public Future> getDatacenter(ResponseHandler callback);
/**
* Async version of {@link Service#getGuests}
*/
public Future> getGuests();
/**
* Async callback version of {@link Service#getGuests}
*/
public Future> getGuests(ResponseHandler> callback);
/**
* Async version of {@link Service#getInternalTagReferences}
*/
public Future> getInternalTagReferences();
/**
* Async callback version of {@link Service#getInternalTagReferences}
*/
public Future> getInternalTagReferences(ResponseHandler> callback);
/**
* Async version of {@link Service#getPciDeviceAllocationStatus}
*/
public Future getPciDeviceAllocationStatus();
/**
* Async callback version of {@link Service#getPciDeviceAllocationStatus}
*/
public Future> getPciDeviceAllocationStatus(ResponseHandler callback);
/**
* Async version of {@link Service#getPciDevices}
*/
public Future> getPciDevices();
/**
* Async callback version of {@link Service#getPciDevices}
*/
public Future> getPciDevices(ResponseHandler> callback);
/**
* Async version of {@link Service#getTagReferences}
*/
public Future> getTagReferences();
/**
* Async callback version of {@link Service#getTagReferences}
*/
public Future> getTagReferences(ResponseHandler> callback);
}
public static class Mask extends com.softlayer.api.service.Entity.Mask {
public com.softlayer.api.service.Account.Mask account() {
return withSubMask("account", com.softlayer.api.service.Account.Mask.class);
}
public com.softlayer.api.service.container.virtual.dedicatedhost.AllocationStatus.Mask allocationStatus() {
return withSubMask("allocationStatus", com.softlayer.api.service.container.virtual.dedicatedhost.AllocationStatus.Mask.class);
}
public com.softlayer.api.service.hardware.router.Backend.Mask backendRouter() {
return withSubMask("backendRouter", com.softlayer.api.service.hardware.router.Backend.Mask.class);
}
public com.softlayer.api.service.billing.item.virtual.DedicatedHost.Mask billingItem() {
return withSubMask("billingItem", com.softlayer.api.service.billing.item.virtual.DedicatedHost.Mask.class);
}
public com.softlayer.api.service.Location.Mask datacenter() {
return withSubMask("datacenter", com.softlayer.api.service.Location.Mask.class);
}
public Guest.Mask guests() {
return withSubMask("guests", Guest.Mask.class);
}
public com.softlayer.api.service.tag.Reference.Mask internalTagReferences() {
return withSubMask("internalTagReferences", com.softlayer.api.service.tag.Reference.Mask.class);
}
public com.softlayer.api.service.container.virtual.dedicatedhost.pci.device.AllocationStatus.Mask pciDeviceAllocationStatus() {
return withSubMask("pciDeviceAllocationStatus", com.softlayer.api.service.container.virtual.dedicatedhost.pci.device.AllocationStatus.Mask.class);
}
public com.softlayer.api.service.virtual.host.PciDevice.Mask pciDevices() {
return withSubMask("pciDevices", com.softlayer.api.service.virtual.host.PciDevice.Mask.class);
}
public com.softlayer.api.service.tag.Reference.Mask tagReferences() {
return withSubMask("tagReferences", com.softlayer.api.service.tag.Reference.Mask.class);
}
public Mask accountId() {
withLocalProperty("accountId");
return this;
}
public Mask cpuCount() {
withLocalProperty("cpuCount");
return this;
}
public Mask createDate() {
withLocalProperty("createDate");
return this;
}
public Mask diskCapacity() {
withLocalProperty("diskCapacity");
return this;
}
public Mask id() {
withLocalProperty("id");
return this;
}
public Mask memoryCapacity() {
withLocalProperty("memoryCapacity");
return this;
}
public Mask modifyDate() {
withLocalProperty("modifyDate");
return this;
}
public Mask name() {
withLocalProperty("name");
return this;
}
public Mask notes() {
withLocalProperty("notes");
return this;
}
public Mask guestCount() {
withLocalProperty("guestCount");
return this;
}
public Mask internalTagReferenceCount() {
withLocalProperty("internalTagReferenceCount");
return this;
}
public Mask pciDeviceCount() {
withLocalProperty("pciDeviceCount");
return this;
}
public Mask tagReferenceCount() {
withLocalProperty("tagReferenceCount");
return this;
}
}
}