From 612e67046968c45e942fb5affcabd38d5dcb3ea5 Mon Sep 17 00:00:00 2001 From: seshukm Date: Wed, 25 Jul 2018 19:07:06 +0800 Subject: basic code issues of nova model Issue-ID: SO-729 Change-Id: Id70f17ad47b78c968fee3b88feea8a1335880c8e Signed-off-by: seshukm --- .../com/woorea/openstack/nova/model/Flavor.java | 454 ++++++++++----------- .../openstack/nova/model/FlavorForCreate.java | 262 ++++++------ .../com/woorea/openstack/nova/model/Flavors.java | 42 +- .../woorea/openstack/nova/model/FloatingIp.java | 100 ++--- .../openstack/nova/model/FloatingIpDomain.java | 84 ++-- .../openstack/nova/model/FloatingIpDomains.java | 46 +-- .../openstack/nova/model/FloatingIpPools.java | 78 ++-- 7 files changed, 533 insertions(+), 533 deletions(-) diff --git a/nova-model/src/main/java/com/woorea/openstack/nova/model/Flavor.java b/nova-model/src/main/java/com/woorea/openstack/nova/model/Flavor.java index 6db8da1..817c50f 100644 --- a/nova-model/src/main/java/com/woorea/openstack/nova/model/Flavor.java +++ b/nova-model/src/main/java/com/woorea/openstack/nova/model/Flavor.java @@ -25,231 +25,231 @@ import org.codehaus.jackson.map.annotate.JsonRootName; @JsonRootName("flavor") public class Flavor implements Serializable { - private String id; - - private String name; - - private Integer vcpus; - - private Integer ram; - - private Integer disk; - - @JsonProperty("OS-FLV-EXT-DATA:ephemeral") - private Integer ephemeral; - - private String swap; - - @JsonProperty("rxtx_factor") - private Float rxtxFactor; - - @JsonProperty("OS-FLV-DISABLED:disabled") - private Boolean disabled; - - @JsonProperty("rxtx_quota") - private Integer rxtxQuota; - - @JsonProperty("rxtx_cap") - private Integer rxtxCap; - - private List links; - - @JsonProperty("os-flavor-access:is_public") - private Boolean isPublic; - - /** - * @return the id - */ - public String getId() { - return id; - } - - /** - * @param id the id to set - */ - public void setId(String id) { - this.id = id; - } - - /** - * @return the name - */ - public String getName() { - return name; - } - - /** - * @param name the name to set - */ - public void setName(String name) { - this.name = name; - } - - /** - * @return the vcpus - */ - public Integer getVcpus() { - return vcpus; - } - - /** - * @param vcpus the vcpus to set - */ - public void setVcpus(Integer vcpus) { - this.vcpus = vcpus; - } - - /** - * @return the ram - */ - public Integer getRam() { - return ram; - } - - /** - * @param ram the ram to set - */ - public void setRam(Integer ram) { - this.ram = ram; - } - - /** - * @return the disk - */ - public Integer getDisk() { - return disk; - } - - /** - * @param disk the disk to set - */ - public void setDisk(Integer disk) { - this.disk = disk; - } - - /** - * @return the ephemeral - */ - public Integer getEphemeral() { - return ephemeral; - } - - /** - * @param ephemeral the ephemeral to set - */ - public void setEphemeral(Integer ephemeral) { - this.ephemeral = ephemeral; - } - - /** - * @return the swap - */ - public String getSwap() { - return swap; - } - - /** - * @param swap the swap to set - */ - public void setSwap(String swap) { - this.swap = swap; - } - - /** - * @return the rxtxFactor - */ - public Float getRxtxFactor() { - return rxtxFactor; - } - - /** - * @param rxtxFactor the rxtxFactor to set - */ - public void setRxtxFactor(Float rxtxFactor) { - this.rxtxFactor = rxtxFactor; - } - - /** - * @return the rxtxQuota - */ - public Integer getRxtxQuota() { - return rxtxQuota; - } - - /** - * @param rxtxQuota the rxtxQuota to set - */ - public void setRxtxQuota(Integer rxtxQuota) { - this.rxtxQuota = rxtxQuota; - } - - /** - * @return the rxtxCap - */ - public Integer getRxtxCap() { - return rxtxCap; - } - - /** - * @param rxtxCap the rxtxCap to set - */ - public void setRxtxCap(Integer rxtxCap) { - this.rxtxCap = rxtxCap; - } - - /** - * @return the disabled - */ - public Boolean getDisabled() { - return disabled; - } - - /** - * @param disabled the disabled to set - */ - public void setDisabled(Boolean disabled) { - this.disabled = disabled; - } - - /** - * @return the isPublic - */ - public Boolean isPublic() { - return isPublic; - } - - /** - * @param isPublic the isPublic to set - */ - public void setPublic(Boolean isPublic) { - this.isPublic = isPublic; - } - - /** - * @return the links - */ - public List getLinks() { - return links; - } - - /** - * @param links the links to set - */ - public void setLinks(List links) { - this.links = links; - } - - /* (non-Javadoc) - * @see java.lang.Object#toString() - */ - @Override - public String toString() { - return "Flavor [id=" + id + ", name=" + name + ", vcpus=" + vcpus - + ", ram=" + ram + ", disk=" + disk + ", ephemeral=" - + ephemeral + ", swap=" + swap + ", rxtxFactor=" + rxtxFactor - + ", disabled=" + disabled + ", rxtxQuota=" + rxtxQuota - + ", rxtxCap=" + rxtxCap + ", links=" + links + ", isPublic=" - + isPublic + "]"; - } - + private String id; + + private String name; + + private Integer vcpus; + + private Integer ram; + + private Integer disk; + + @JsonProperty("OS-FLV-EXT-DATA:ephemeral") + private Integer ephemeral; + + private String swap; + + @JsonProperty("rxtx_factor") + private Float rxtxFactor; + + @JsonProperty("OS-FLV-DISABLED:disabled") + private Boolean disabled; + + @JsonProperty("rxtx_quota") + private Integer rxtxQuota; + + @JsonProperty("rxtx_cap") + private Integer rxtxCap; + + private List links; + + @JsonProperty("os-flavor-access:is_public") + private Boolean isPublic; + + /** + * @return the id + */ + public String getId() { + return id; + } + + /** + * @param id the id to set + */ + public void setId(String id) { + this.id = id; + } + + /** + * @return the name + */ + public String getName() { + return name; + } + + /** + * @param name the name to set + */ + public void setName(String name) { + this.name = name; + } + + /** + * @return the vcpus + */ + public Integer getVcpus() { + return vcpus; + } + + /** + * @param vcpus the vcpus to set + */ + public void setVcpus(Integer vcpus) { + this.vcpus = vcpus; + } + + /** + * @return the ram + */ + public Integer getRam() { + return ram; + } + + /** + * @param ram the ram to set + */ + public void setRam(Integer ram) { + this.ram = ram; + } + + /** + * @return the disk + */ + public Integer getDisk() { + return disk; + } + + /** + * @param disk the disk to set + */ + public void setDisk(Integer disk) { + this.disk = disk; + } + + /** + * @return the ephemeral + */ + public Integer getEphemeral() { + return ephemeral; + } + + /** + * @param ephemeral the ephemeral to set + */ + public void setEphemeral(Integer ephemeral) { + this.ephemeral = ephemeral; + } + + /** + * @return the swap + */ + public String getSwap() { + return swap; + } + + /** + * @param swap the swap to set + */ + public void setSwap(String swap) { + this.swap = swap; + } + + /** + * @return the rxtxFactor + */ + public Float getRxtxFactor() { + return rxtxFactor; + } + + /** + * @param rxtxFactor the rxtxFactor to set + */ + public void setRxtxFactor(Float rxtxFactor) { + this.rxtxFactor = rxtxFactor; + } + + /** + * @return the rxtxQuota + */ + public Integer getRxtxQuota() { + return rxtxQuota; + } + + /** + * @param rxtxQuota the rxtxQuota to set + */ + public void setRxtxQuota(Integer rxtxQuota) { + this.rxtxQuota = rxtxQuota; + } + + /** + * @return the rxtxCap + */ + public Integer getRxtxCap() { + return rxtxCap; + } + + /** + * @param rxtxCap the rxtxCap to set + */ + public void setRxtxCap(Integer rxtxCap) { + this.rxtxCap = rxtxCap; + } + + /** + * @return the disabled + */ + public Boolean getDisabled() { + return disabled; + } + + /** + * @param disabled the disabled to set + */ + public void setDisabled(Boolean disabled) { + this.disabled = disabled; + } + + /** + * @return the isPublic + */ + public Boolean isPublic() { + return isPublic; + } + + /** + * @param isPublic the isPublic to set + */ + public void setPublic(Boolean isPublic) { + this.isPublic = isPublic; + } + + /** + * @return the links + */ + public List getLinks() { + return links; + } + + /** + * @param links the links to set + */ + public void setLinks(List links) { + this.links = links; + } + + /* (non-Javadoc) + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return "Flavor [id=" + id + ", name=" + name + ", vcpus=" + vcpus + + ", ram=" + ram + ", disk=" + disk + ", ephemeral=" + + ephemeral + ", swap=" + swap + ", rxtxFactor=" + rxtxFactor + + ", disabled=" + disabled + ", rxtxQuota=" + rxtxQuota + + ", rxtxCap=" + rxtxCap + ", links=" + links + ", isPublic=" + + isPublic + "]"; + } + } diff --git a/nova-model/src/main/java/com/woorea/openstack/nova/model/FlavorForCreate.java b/nova-model/src/main/java/com/woorea/openstack/nova/model/FlavorForCreate.java index 8d632a4..481e3bf 100644 --- a/nova-model/src/main/java/com/woorea/openstack/nova/model/FlavorForCreate.java +++ b/nova-model/src/main/java/com/woorea/openstack/nova/model/FlavorForCreate.java @@ -24,135 +24,135 @@ import org.codehaus.jackson.map.annotate.JsonRootName; @JsonRootName("flavor") public class FlavorForCreate implements Serializable { - - private String id; - - private String name; - - private String vcpus; - - private Integer ram; - - private String disk; - - @JsonProperty("OS-FLV-EXT-DATA:ephemeral") - private Integer ephemeral; - - private String swap; - - @JsonProperty("rxtx_factor") - private Float rxtxFactor; - - /** - * @return the id - */ - public String getId() { - return id; - } - - /** - * @param id the id to set - */ - public void setId(String id) { - this.id = id; - } - - /** - * @return the name - */ - public String getName() { - return name; - } - - /** - * @param name the name to set - */ - public void setName(String name) { - this.name = name; - } - - /** - * @return the vcpus - */ - public String getVcpus() { - return vcpus; - } - - /** - * @param vcpus the vcpus to set - */ - public void setVcpus(String vcpus) { - this.vcpus = vcpus; - } - - /** - * @return the ram - */ - public Integer getRam() { - return ram; - } - - /** - * @param ram the ram to set - */ - public void setRam(Integer ram) { - this.ram = ram; - } - - /** - * @return the disk - */ - public String getDisk() { - return disk; - } - - /** - * @param disk the disk to set - */ - public void setDisk(String disk) { - this.disk = disk; - } - - /** - * @return the ephemeral - */ - public Integer getEphemeral() { - return ephemeral; - } - - /** - * @param ephemeral the ephemeral to set - */ - public void setEphemeral(Integer ephemeral) { - this.ephemeral = ephemeral; - } - - /** - * @return the swap - */ - public String getSwap() { - return swap; - } - - /** - * @param swap the swap to set - */ - public void setSwap(String swap) { - this.swap = swap; - } - - /** - * @return the rxtxFactor - */ - public Float getRxtxFactor() { - return rxtxFactor; - } - - /** - * @param rxtxFactor the rxtxFactor to set - */ - public void setRxtxFactor(Float rxtxFactor) { - this.rxtxFactor = rxtxFactor; - } - + + private String id; + + private String name; + + private String vcpus; + + private Integer ram; + + private String disk; + + @JsonProperty("OS-FLV-EXT-DATA:ephemeral") + private Integer ephemeral; + + private String swap; + + @JsonProperty("rxtx_factor") + private Float rxtxFactor; + + /** + * @return the id + */ + public String getId() { + return id; + } + + /** + * @param id the id to set + */ + public void setId(String id) { + this.id = id; + } + + /** + * @return the name + */ + public String getName() { + return name; + } + + /** + * @param name the name to set + */ + public void setName(String name) { + this.name = name; + } + + /** + * @return the vcpus + */ + public String getVcpus() { + return vcpus; + } + + /** + * @param vcpus the vcpus to set + */ + public void setVcpus(String vcpus) { + this.vcpus = vcpus; + } + + /** + * @return the ram + */ + public Integer getRam() { + return ram; + } + + /** + * @param ram the ram to set + */ + public void setRam(Integer ram) { + this.ram = ram; + } + + /** + * @return the disk + */ + public String getDisk() { + return disk; + } + + /** + * @param disk the disk to set + */ + public void setDisk(String disk) { + this.disk = disk; + } + + /** + * @return the ephemeral + */ + public Integer getEphemeral() { + return ephemeral; + } + + /** + * @param ephemeral the ephemeral to set + */ + public void setEphemeral(Integer ephemeral) { + this.ephemeral = ephemeral; + } + + /** + * @return the swap + */ + public String getSwap() { + return swap; + } + + /** + * @param swap the swap to set + */ + public void setSwap(String swap) { + this.swap = swap; + } + + /** + * @return the rxtxFactor + */ + public Float getRxtxFactor() { + return rxtxFactor; + } + + /** + * @param rxtxFactor the rxtxFactor to set + */ + public void setRxtxFactor(Float rxtxFactor) { + this.rxtxFactor = rxtxFactor; + } + } diff --git a/nova-model/src/main/java/com/woorea/openstack/nova/model/Flavors.java b/nova-model/src/main/java/com/woorea/openstack/nova/model/Flavors.java index 5720340..0bc4ae8 100644 --- a/nova-model/src/main/java/com/woorea/openstack/nova/model/Flavors.java +++ b/nova-model/src/main/java/com/woorea/openstack/nova/model/Flavors.java @@ -24,27 +24,27 @@ import org.codehaus.jackson.annotate.JsonProperty; public class Flavors implements Iterable, Serializable { - @JsonProperty("flavors") - private List list; + @JsonProperty("flavors") + private List list; - /** - * @return the list - */ - public List getList() { - return list; - } - - @Override - public Iterator iterator() { - return list.iterator(); - } - - /* (non-Javadoc) - * @see java.lang.Object#toString() - */ - @Override - public String toString() { - return "Flavors [list=" + list + "]"; - } + /** + * @return the list + */ + public List getList() { + return list; + } + + @Override + public Iterator iterator() { + return list.iterator(); + } + + /* (non-Javadoc) + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return "Flavors [list=" + list + "]"; + } } diff --git a/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIp.java b/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIp.java index f92ec2a..b38e78e 100644 --- a/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIp.java +++ b/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIp.java @@ -24,60 +24,60 @@ import org.codehaus.jackson.map.annotate.JsonRootName; @JsonRootName("floating_ip") public class FloatingIp implements Serializable { - private String id; - - private String pool; - - private String ip; - - @JsonProperty("fixed_ip") - private String fixedIp; - - @JsonProperty("instance_id") - private String instanceId; + private String id; + + private String pool; + + private String ip; + + @JsonProperty("fixed_ip") + private String fixedIp; + + @JsonProperty("instance_id") + private String instanceId; - /** - * @return the id - */ - public String getId() { - return id; - } + /** + * @return the id + */ + public String getId() { + return id; + } - /** - * @return the pool - */ - public String getPool() { - return pool; - } + /** + * @return the pool + */ + public String getPool() { + return pool; + } - /** - * @return the ip - */ - public String getIp() { - return ip; - } + /** + * @return the ip + */ + public String getIp() { + return ip; + } - /** - * @return the fixedIp - */ - public String getFixedIp() { - return fixedIp; - } + /** + * @return the fixedIp + */ + public String getFixedIp() { + return fixedIp; + } - /** - * @return the instanceId - */ - public String getInstanceId() { - return instanceId; - } + /** + * @return the instanceId + */ + public String getInstanceId() { + return instanceId; + } - /* (non-Javadoc) - * @see java.lang.Object#toString() - */ - @Override - public String toString() { - return "FloatingIp [id=" + id + ", pool=" + pool + ", ip=" + ip - + ", fixedIp=" + fixedIp + ", instanceId=" + instanceId + "]"; - } - + /* (non-Javadoc) + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return "FloatingIp [id=" + id + ", pool=" + pool + ", ip=" + ip + + ", fixedIp=" + fixedIp + ", instanceId=" + instanceId + "]"; + } + } diff --git a/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpDomain.java b/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpDomain.java index 1aa0b79..2a5eb75 100644 --- a/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpDomain.java +++ b/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpDomain.java @@ -24,51 +24,51 @@ import org.codehaus.jackson.map.annotate.JsonRootName; @JsonRootName("floating-ip-pool") public class FloatingIpDomain implements Serializable { - private String domain; - - private String scope; - - private String project; - - @JsonProperty("availabilityZone") - private String availabilityZone; + private String domain; + + private String scope; + + private String project; + + @JsonProperty("availabilityZone") + private String availabilityZone; - /** - * @return the domain - */ - public String getDomain() { - return domain; - } + /** + * @return the domain + */ + public String getDomain() { + return domain; + } - /** - * @return the scope - */ - public String getScope() { - return scope; - } + /** + * @return the scope + */ + public String getScope() { + return scope; + } - /** - * @return the project - */ - public String getProject() { - return project; - } + /** + * @return the project + */ + public String getProject() { + return project; + } - /** - * @return the availabilityZone - */ - public String getAvailabilityZone() { - return availabilityZone; - } + /** + * @return the availabilityZone + */ + public String getAvailabilityZone() { + return availabilityZone; + } - /* (non-Javadoc) - * @see java.lang.Object#toString() - */ - @Override - public String toString() { - return "FloatingIpDomain [domain=" + domain + ", scope=" + scope - + ", project=" + project + ", availabilityZone=" - + availabilityZone + "]"; - } - + /* (non-Javadoc) + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return "FloatingIpDomain [domain=" + domain + ", scope=" + scope + + ", project=" + project + ", availabilityZone=" + + availabilityZone + "]"; + } + } diff --git a/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpDomains.java b/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpDomains.java index 3b452d6..bf849f3 100644 --- a/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpDomains.java +++ b/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpDomains.java @@ -24,27 +24,27 @@ import org.codehaus.jackson.annotate.JsonProperty; public class FloatingIpDomains implements Iterable, Serializable { - @JsonProperty("domain_entries") - private List list; - - /** - * @return the list - */ - public List getList() { - return list; - } - - @Override - public Iterator iterator() { - return list.iterator(); - } - - /* (non-Javadoc) - * @see java.lang.Object#toString() - */ - @Override - public String toString() { - return "FloatingIpDomains [list=" + list + "]"; - } - + @JsonProperty("domain_entries") + private List list; + + /** + * @return the list + */ + public List getList() { + return list; + } + + @Override + public Iterator iterator() { + return list.iterator(); + } + + /* (non-Javadoc) + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return "FloatingIpDomains [list=" + list + "]"; + } + } diff --git a/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpPools.java b/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpPools.java index a6341ec..b3196b6 100644 --- a/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpPools.java +++ b/nova-model/src/main/java/com/woorea/openstack/nova/model/FloatingIpPools.java @@ -25,49 +25,49 @@ import org.codehaus.jackson.annotate.JsonProperty; import com.woorea.openstack.nova.model.FloatingIpPools.FloatingIpPool; public class FloatingIpPools implements Iterable, Serializable { - - public static class FloatingIpPool implements Serializable { + + public static class FloatingIpPool implements Serializable { - private String name; + private String name; - /** - * @return the name - */ - public String getName() { - return name; - } + /** + * @return the name + */ + public String getName() { + return name; + } - /* (non-Javadoc) - * @see java.lang.Object#toString() - */ - @Override - public String toString() { - return "FloatingIpPool [name=" + name + "]"; - } - - } + /* (non-Javadoc) + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return "FloatingIpPool [name=" + name + "]"; + } + + } - @JsonProperty("floating_ip_pools") - private List list; + @JsonProperty("floating_ip_pools") + private List list; - /** - * @return the list - */ - public List getList() { - return list; - } - - @Override - public Iterator iterator() { - return list.iterator(); - } - - /* (non-Javadoc) - * @see java.lang.Object#toString() - */ - @Override - public String toString() { - return "FloatingIpPools [list=" + list + "]"; - } + /** + * @return the list + */ + public List getList() { + return list; + } + + @Override + public Iterator iterator() { + return list.iterator(); + } + + /* (non-Javadoc) + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return "FloatingIpPools [list=" + list + "]"; + } } -- cgit 1.2.3-korg