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

com.abiquo.server.core.statistics.VirtualDatacenterResourcesDto Maven / Gradle / Ivy

/**
 * Copyright (C) 2008 Abiquo Holdings S.L.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License 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.abiquo.server.core.statistics;

import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlType;

import com.abiquo.model.transport.SingleResourceWithLimitsDto;

/**
 * Shows statistical data on resources used by virtual datacenters
 */
@XmlRootElement(name = "vdcResources")
@XmlType(propOrder = {"id", "extStorageReservedInMb", "extStorageReserved", "extStorageUsedInMb",
"extStorageUsed", "idEnterprise", "localStorageReservedInMb", "localStorageReserved",
"localStorageUsedInMb", "localStorageUsed", "memoryReservedInMb", "memoryReserved",
"memoryUsedInMb", "memoryUsed", "publicIPsReserved", "publicIPsUsed", "vdcName",
"virtualCpuReserved", "virtualCpuUsed", "vlanReserved", "vlanUsed", "vmActive", "vmCreated",
"volAttached", "volCreated"})
public class VirtualDatacenterResourcesDto extends SingleResourceWithLimitsDto
{
    private static final long serialVersionUID = 5990721643175198188L;

    private static final String TYPE = "application/vnd.abiquo.virtualdatacenterresources";

    public static final String MEDIA_TYPE = TYPE + "+" + JSON;

    public static final String SHORT_MEDIA_TYPE_JSON = MEDIA_TYPE;

    public static final String SHORT_MEDIA_TYPE_XML = TYPE + "+" + XML;

    public static final String MEDIA_TYPE_XML = TYPE + "+" + XML + VERSION_PARAM + API_VERSION;

    public static final String MEDIA_TYPE_JSON = MEDIA_TYPE + VERSION_PARAM + API_VERSION;

    /** Identifier of the entity */
    private Integer id;

    /** Name of the virtual datacenter */
    private String vdcName;

    /** Number of volumes created in this virtual datacenter. */
    private int volCreated;

    /** Number of volumes currently attached to a VM in this virtual datacenter. */
    private int volAttached;

    /** Number of VMs created in this virtual datacenter. */
    private int vmCreated;

    /** Number of VMs currently running in this virtual datacenter. */
    private int vmActive;

    /** Number of VMs currently running in this virtual datacenter. */
    private int idEnterprise;

    /** Maximum amount of RAM reserved for this virtual datacenter in megabytes */
    private long memoryReservedInMb;

    /** Total maximum number of VLANs reserved for this virtual datacenter. (enterprise.vlanHard) */
    private long vlanReserved;

    /** Total number of IPs used by VMs */
    private long publicIPsUsed;

    /** Total number of IPs assigned to this virtual datacenter (Reserved) */
    private long publicIPsReserved;

    /** Maximum storage size reserved for this virtual datacenter for VMs in megabytes */
    private long localStorageReservedInMb;

    /**
     * Storage in external storage volumes used (attached or mounted) by any virtual machines (in
     * megabytes)
     */
    private long extStorageUsedInMb;

    /** Total number of VLANs in use by this virtual datacenter */
    private long vlanUsed;

    /** Maximum external storage size reserved for this virtual datacenter in megabytes */
    private long extStorageReservedInMb;

    /** Total storage size used by VMs currently in a running state in megabytes */
    private long localStorageUsedInMb;

    /** Total number of Virtual CPUs in virtual machines currently in a running state */
    private long virtualCpuUsed;

    /** Maximum number of Virtual CPUs reserved for this virtual datacenter */
    private long virtualCpuReserved;

    /** Total amount of RAM used by VMs currently in a running state in megabytes */
    private long memoryUsedInMb;

    /** Deprecated, use memoryUsedInMb */
    @Deprecated
    private long memoryUsed;

    /** Deprecated, use memoryReservedInMb */
    @Deprecated
    private long memoryReserved;

    /** Deprecated, use localStorageUsedInMb */
    @Deprecated
    private long localStorageUsed;

    /** Deprecated, use localStorageReservedInMb */
    @Deprecated
    private long localStorageReserved;

    /** Deprecated, use extStorageUsedInMb */
    @Deprecated
    private long extStorageUsed;

    /** Deprecated, use extStorageReservedInMb */
    @Deprecated
    private long extStorageReserved;

    public long getExtStorageReservedInMb()
    {
        return extStorageReservedInMb;
    }

    public long getExtStorageUsedInMb()
    {
        return extStorageUsedInMb;
    }

    public Integer getId()
    {
        return id;
    }

    public int getIdEnterprise()
    {
        return idEnterprise;
    }

    public long getLocalStorageReservedInMb()
    {
        return localStorageReservedInMb;
    }

    public long getLocalStorageUsedInMb()
    {
        return localStorageUsedInMb;
    }

    public long getMemoryReservedInMb()
    {
        return memoryReservedInMb;
    }

    public long getMemoryUsedInMb()
    {
        return memoryUsedInMb;
    }

    public long getPublicIPsReserved()
    {
        return publicIPsReserved;
    }

    public long getPublicIPsUsed()
    {
        return publicIPsUsed;
    }

    public String getVdcName()
    {
        return vdcName;
    }

    public long getVirtualCpuReserved()
    {
        return virtualCpuReserved;
    }

    public long getVirtualCpuUsed()
    {
        return virtualCpuUsed;
    }

    public long getVlanReserved()
    {
        return vlanReserved;
    }

    public long getVlanUsed()
    {
        return vlanUsed;
    }

    public int getVmActive()
    {
        return vmActive;
    }

    public int getVmCreated()
    {
        return vmCreated;
    }

    public int getVolAttached()
    {
        return volAttached;
    }

    public int getVolCreated()
    {
        return volCreated;
    }

    public void setExtStorageReservedInMb(final long extStorageReservedInMb)
    {
        this.extStorageReservedInMb = extStorageReservedInMb;
    }

    public void setExtStorageUsedInMb(final long extStorageUsedInMb)
    {
        this.extStorageUsedInMb = extStorageUsedInMb;
    }

    public void setId(final Integer id)
    {
        this.id = id;
    }

    public void setIdEnterprise(final int idEnterprise)
    {
        this.idEnterprise = idEnterprise;
    }

    public void setLocalStorageReservedInMb(final long localStorageReservedInMb)
    {
        this.localStorageReservedInMb = localStorageReservedInMb;
    }

    public void setLocalStorageUsedInMb(final long localStorageUsedInMb)
    {
        this.localStorageUsedInMb = localStorageUsedInMb;
    }

    public void setMemoryReservedInMb(final long memoryReservedInMb)
    {
        this.memoryReservedInMb = memoryReservedInMb;
    }

    public void setMemoryUsedInMb(final long memoryUsedInMb)
    {
        this.memoryUsedInMb = memoryUsedInMb;
    }

    public void setPublicIPsReserved(final long publicIPsReserved)
    {
        this.publicIPsReserved = publicIPsReserved;
    }

    public void setPublicIPsUsed(final long publicIPsUsed)
    {
        this.publicIPsUsed = publicIPsUsed;
    }

    public void setVdcName(final String vdcName)
    {
        this.vdcName = vdcName;
    }

    public void setVirtualCpuReserved(final long virtualCpuReserved)
    {
        this.virtualCpuReserved = virtualCpuReserved;
    }

    public void setVirtualCpuUsed(final long virtualCpuUsed)
    {
        this.virtualCpuUsed = virtualCpuUsed;
    }

    public void setVlanReserved(final long vlanReserved)
    {
        this.vlanReserved = vlanReserved;
    }

    public void setVlanUsed(final long vlanUsed)
    {
        this.vlanUsed = vlanUsed;
    }

    public void setVmActive(final int vmActive)
    {
        this.vmActive = vmActive;
    }

    public void setVmCreated(final int vmCreated)
    {
        this.vmCreated = vmCreated;
    }

    public void setVolAttached(final int volAttached)
    {
        this.volAttached = volAttached;
    }

    public void setVolCreated(final int volCreated)
    {
        this.volCreated = volCreated;
    }

    @Deprecated
    public long getMemoryUsed()
    {
        return memoryUsed;
    }

    @Deprecated
    public void setMemoryUsed(final long memoryUsed)
    {
        this.memoryUsed = memoryUsed;
    }

    @Deprecated
    public long getMemoryReserved()
    {
        return memoryReserved;
    }

    @Deprecated
    public void setMemoryReserved(final long memoryReserved)
    {
        this.memoryReserved = memoryReserved;
    }

    @Deprecated
    public long getLocalStorageUsed()
    {
        return localStorageUsed;
    }

    @Deprecated
    public void setLocalStorageUsed(final long localStorageUsed)
    {
        this.localStorageUsed = localStorageUsed;
    }

    @Deprecated
    public long getLocalStorageReserved()
    {
        return localStorageReserved;
    }

    @Deprecated
    public void setLocalStorageReserved(final long localStorageReserved)
    {
        this.localStorageReserved = localStorageReserved;
    }

    @Deprecated
    public long getExtStorageUsed()
    {
        return extStorageUsed;
    }

    @Deprecated
    public void setExtStorageUsed(final long extStorageUsed)
    {
        this.extStorageUsed = extStorageUsed;
    }

    @Deprecated
    public long getExtStorageReserved()
    {
        return extStorageReserved;
    }

    @Deprecated
    public void setExtStorageReserved(final long extStorageReserved)
    {
        this.extStorageReserved = extStorageReserved;
    }

    @Override
    public String getBaseMediaType()
    {
        return MEDIA_TYPE;
    }

    @Override
    public String getMediaType()
    {
        return MEDIA_TYPE_JSON;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy