summaryrefslogtreecommitdiffstats
path: root/cinder-model
diff options
context:
space:
mode:
authorSmokowski, Steve (ss835w) <ss835w@us.att.com>2019-05-02 09:42:55 -0400
committerSmokowski, Steve (ss835w) <ss835w@us.att.com>2019-05-02 12:15:48 -0400
commite153f0adfbed711ce1e215748594a4d04fd1edaf (patch)
tree15a1f4d7b8af126e2061633c1547881992cfbb6f /cinder-model
parentf9b78e1d7ca2b64badd8529aa4600250387ddae7 (diff)
Enhance Openstack Client
Update Openstack Client to support Cinder, and drop null query params Issue-ID: SO-1844 Change-Id: If58717656e0468ec0ce5d53055c381fe7d1c03f5 Signed-off-by: Smokowski, Steve (ss835w) <ss835w@us.att.com>
Diffstat (limited to 'cinder-model')
-rwxr-xr-xcinder-model/pom.xml12
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/BaseConnection.java42
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/Capabilities.java153
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionForInitialize.java34
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionForTerminate.java34
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionInfo.java72
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/Limits.java260
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/Metadata.java49
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/Pool.java56
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/Pools.java47
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/Snapshot.java113
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/SnapshotForCreate.java105
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/SnapshotForUpdate.java68
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/Snapshots.java50
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/Volume.java180
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForCreate.java225
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForExtend.java53
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForImageCreate.java85
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForUpdate.java68
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeType.java64
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeTypeForCreate.java71
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeTypes.java50
-rwxr-xr-xcinder-model/src/main/java/com/woorea/openstack/cinder/model/Volumes.java50
23 files changed, 1941 insertions, 0 deletions
diff --git a/cinder-model/pom.xml b/cinder-model/pom.xml
new file mode 100755
index 0000000..a739859
--- /dev/null
+++ b/cinder-model/pom.xml
@@ -0,0 +1,12 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.onap.so.libs</groupId>
+ <artifactId>openstack-java-sdk</artifactId>
+ <version>1.4.0-SNAPSHOT</version>
+ </parent>
+ <groupId>org.onap.so.libs.openstack-java-sdk</groupId>
+ <artifactId>cinder-model</artifactId>
+ <name>OpenStack Cinder Model</name>
+ <description>OpenStack Cinder Model</description>
+</project> \ No newline at end of file
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/BaseConnection.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/BaseConnection.java
new file mode 100755
index 0000000..16be17b
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/BaseConnection.java
@@ -0,0 +1,42 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.HashMap;
+import java.util.Map;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+public abstract class BaseConnection implements Serializable {
+ @JsonProperty("connector")
+ private Map<String, Object> connector = new HashMap<String, Object>();
+
+ /**
+ * @return the connector
+ */
+ public Map<String, Object> getConnector() {
+ return connector;
+ }
+
+ /**
+ * @param connector
+ * the connector to set
+ */
+ public void setConnector(Map<String, Object> connector) {
+ this.connector = connector;
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Capabilities.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Capabilities.java
new file mode 100755
index 0000000..7a1609c
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Capabilities.java
@@ -0,0 +1,153 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.List;
+import java.util.Map;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+/**
+ * Model for Volume
+ */
+@JsonRootName("capabilities")
+public class Capabilities implements Serializable {
+
+ @JsonProperty("pool_name")
+ private String poolName;
+ @JsonProperty("QoS_support")
+ private boolean qosSupport;
+ @JsonProperty("allocated_capacity_gb")
+ private Long allocatedCapacityGb;
+ @JsonProperty("driver_version")
+ private String driverVersion;
+ @JsonProperty("free_capacity_gb")
+ private Long freeCapacityGb;
+ @JsonProperty("location_info")
+ private String locationInfo;
+
+ private String timestamp;
+ @JsonProperty("volume_backend_name")
+ private String volumeBackendName;
+ @JsonProperty("total_capacity_gb")
+ private Long totalCapacityGb;
+ @JsonProperty("reserved_percentage")
+ private Integer reservedPercentage;
+ @JsonProperty("vendor_name")
+ private String vendorName;
+ @JsonProperty("storage_protocol")
+ private String storageProtocol;
+ @JsonProperty("extra_specs")
+ private Map<String, String> extraSpecs;
+
+ public String getPoolName() {
+ return poolName;
+ }
+ public void setPoolName(String poolName) {
+ this.poolName = poolName;
+ }
+ public boolean isQosSupport() {
+ return qosSupport;
+ }
+ public void setQosSupport(boolean qosSupport) {
+ this.qosSupport = qosSupport;
+ }
+ public Long getAllocatedCapacityGb() {
+ return allocatedCapacityGb;
+ }
+ public void setAllocatedCapacityGb(Long allocatedCapacityGb) {
+ this.allocatedCapacityGb = allocatedCapacityGb;
+ }
+ public String getDriverVersion() {
+ return driverVersion;
+ }
+ public void setDriverVersion(String driverVersion) {
+ this.driverVersion = driverVersion;
+ }
+ public Long getFreeCapacityGb() {
+ return freeCapacityGb;
+ }
+ public void setFreeCapacityGb(Long freeCapacityGb) {
+ this.freeCapacityGb = freeCapacityGb;
+ }
+ public String getLocationInfo() {
+ return locationInfo;
+ }
+ public void setLocationInfo(String locationInfo) {
+ this.locationInfo = locationInfo;
+ }
+ public String getTimestamp() {
+ return timestamp;
+ }
+ public void setTimestamp(String timestamp) {
+ this.timestamp = timestamp;
+ }
+ public String getVolumeBackendName() {
+ return volumeBackendName;
+ }
+ public void setVolumeBackendName(String volumeBackendName) {
+ this.volumeBackendName = volumeBackendName;
+ }
+ public Long getTotalCapacityGb() {
+ return totalCapacityGb;
+ }
+ public void setTotalCapacityGb(Long totalCapacityGb) {
+ this.totalCapacityGb = totalCapacityGb;
+ }
+ public Integer getReservedPercentage() {
+ return reservedPercentage;
+ }
+ public void setReservedPercentage(Integer reservedPercentage) {
+ this.reservedPercentage = reservedPercentage;
+ }
+ public String getVendorName() {
+ return vendorName;
+ }
+ public void setVendorName(String vendorName) {
+ this.vendorName = vendorName;
+ }
+ public String getStorageProtocol() {
+ return storageProtocol;
+ }
+ public void setStorageProtocol(String storageProtocol) {
+ this.storageProtocol = storageProtocol;
+ }
+ public Map<String, String> getExtraSpecs() {
+ return extraSpecs;
+ }
+ public void setExtraSpecs(Map<String, String> extraSpecs) {
+ this.extraSpecs = extraSpecs;
+ }
+
+ @Override
+ public String toString() {
+ return "Capabilities{"
+ + "poolName='" + poolName
+ + ", qosSupport='" + qosSupport
+ + ", allocatedCapacityGb='" + allocatedCapacityGb
+ + ", driverVersion='" + driverVersion
+ + ", freeCapacityGb='" + freeCapacityGb
+ + ", locationInfo='" + locationInfo
+ + ", timestamp='" + timestamp
+ + ", volumeBackendName='" + volumeBackendName
+ + ", totalCapacityGb='" + totalCapacityGb
+ + ", reservedPercentage='" + reservedPercentage
+ + ", vendorName='" + vendorName
+ + ", storageProtocol='" + storageProtocol
+ + ", extraSpecs='" + extraSpecs
+ + '}';
+ }
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionForInitialize.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionForInitialize.java
new file mode 100755
index 0000000..7406eea
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionForInitialize.java
@@ -0,0 +1,34 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+import java.io.Serializable;
+
+@JsonRootName("os-initialize_connection")
+public class ConnectionForInitialize extends BaseConnection implements Serializable {
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "ConnectionForInitialize [connector=" + getConnector() + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionForTerminate.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionForTerminate.java
new file mode 100755
index 0000000..208fc54
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionForTerminate.java
@@ -0,0 +1,34 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+import java.io.Serializable;
+
+@JsonRootName("os-terminate_connection")
+public class ConnectionForTerminate extends BaseConnection implements Serializable {
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "ConnectionForInitialize [connector=" + getConnector() + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionInfo.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionInfo.java
new file mode 100755
index 0000000..1bf9677
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/ConnectionInfo.java
@@ -0,0 +1,72 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.Map;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("connection_info")
+public class ConnectionInfo implements Serializable {
+
+ @JsonProperty("driver_volume_type")
+ private String driverVolumeType;
+
+ private Map<String, Object> data;
+
+ /**
+ * @return the driverVolumeType
+ */
+ public String getDriverVolumeType() {
+ return driverVolumeType;
+ }
+
+ /**
+ * @param driverVolumeType
+ * the driverVolumeType to set
+ */
+ public void setDriverVolumeType(String driverVolumeType) {
+ this.driverVolumeType = driverVolumeType;
+ }
+
+ /**
+ * @return the data
+ */
+ public Map<String, Object> getData() {
+ return data;
+ }
+
+ /**
+ * @param data
+ * the data to set
+ */
+ public void setData(Map<String, Object> data) {
+ this.data = data;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "ConnectionInfo [driverVolumeType=" + driverVolumeType + "," +
+ " data=" + data + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Limits.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Limits.java
new file mode 100755
index 0000000..6c83845
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Limits.java
@@ -0,0 +1,260 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+import java.io.Serializable;
+import java.util.Calendar;
+import java.util.List;
+
+@JsonRootName("limits")
+public class Limits implements Serializable {
+
+ public static final class RateLimit implements Serializable {
+
+ public static final class LimitEntry implements Serializable {
+
+ @JsonProperty("next-available")
+ private Calendar nextAvailable;
+
+ private String unit;
+
+ private String verb;
+
+ private Integer remaining;
+
+ private Integer available;
+
+ private Integer value;
+
+ /**
+ * @return the nextAvailable
+ */
+ public Calendar getNextAvailable() {
+ return nextAvailable;
+ }
+
+ /**
+ * @return the unit
+ */
+ public String getUnit() {
+ return unit;
+ }
+
+ /**
+ * @return the verb
+ */
+ public String getVerb() {
+ return verb;
+ }
+
+ /**
+ * @return the remaining
+ */
+ public Integer getRemaining() {
+ return remaining;
+ }
+
+ /**
+ * @return the available
+ */
+ public Integer getAvailable() {
+ return available;
+ }
+
+ /**
+ * @return the value
+ */
+ public Integer getValue() {
+ return value;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "LimitEntry [nextAvailable=" + nextAvailable + ", unit="
+ + unit + ", verb=" + verb + ", remaining=" + remaining
+ + ", available=" + available + ", value=" + value + "]";
+ }
+
+ }
+
+ private String regex;
+
+ private String uri;
+
+ private List<LimitEntry> limit;
+
+ /**
+ * @return the regex
+ */
+ public String getRegex() {
+ return regex;
+ }
+
+ /**
+ * @return the uri
+ */
+ public String getUri() {
+ return uri;
+ }
+
+ /**
+ * @return the limit
+ */
+ public List<LimitEntry> getLimit() {
+ return limit;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "RateLimit [regex=" + regex + ", uri=" + uri + ", limit="
+ + limit + "]";
+ }
+
+ }
+
+ public static final class AbsoluteLimit {
+
+ private Integer maxTotalVolumes;
+ private Integer totalVolumesUsed;
+
+ private Integer maxTotalSnapshots;
+ private Integer totalSnapshotsUsed;
+
+ private Integer maxTotalVolumeGigabytes;
+ private Integer totalGigabytesUsed;
+
+ private Integer maxTotalBackups;
+ private Integer totalBackupsUsed;
+
+ private Integer maxTotalBackupGigabytes;
+ private Integer totalBackupGigabytesUsed;
+
+ /**
+ * @return the maxTotalVolumes
+ */
+ public Integer getMaxTotalVolumes() {
+ return maxTotalVolumes;
+ }
+
+ /**
+ * @return the totalVolumesUsed
+ */
+ public Integer getTotalVolumesUsed() {
+ return totalVolumesUsed;
+ }
+
+ /**
+ * @return the maxTotalSnapshots
+ */
+ public Integer getMaxTotalSnapshots() {
+ return maxTotalSnapshots;
+ }
+
+ /**
+ * @return the totalSnapshotsUsed
+ */
+ public Integer getTotalSnapshotsUsed() {
+ return totalSnapshotsUsed;
+ }
+
+ /**
+ * @return the maxTotalVolumeGigabytes
+ */
+ public Integer getMaxTotalVolumeGigabytes() {
+ return maxTotalVolumeGigabytes;
+ }
+
+ /**
+ * @return the totalGigabytesUsed
+ */
+ public Integer getTotalGigabytesUsed() {
+ return totalGigabytesUsed;
+ }
+
+ /**
+ * @return the maxTotalBackupGigabytes
+ */
+ public Integer getMaxTotalBackupGigabytes() {
+ return maxTotalBackupGigabytes;
+ }
+
+ /**
+ * @return the totalBackupGigabytesUsed
+ */
+ public Integer getTotalBackupGigabytesUsed() {
+ return totalBackupGigabytesUsed;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "AbsoluteLimit [maxTotalVolumes=" + maxTotalVolumes +
+ ", totalVolumesUsed=" + totalVolumesUsed +
+ ", maxTotalSnapshots=" + maxTotalSnapshots +
+ ", totalSnapshotsUsed=" + totalSnapshotsUsed +
+ ", maxTotalVolumeGigabytes=" + maxTotalVolumeGigabytes +
+ ", totalGigabytesUsed=" + totalGigabytesUsed +
+ ", maxTotalBackupGigabytes=" + maxTotalBackupGigabytes +
+ ", totalBackupGigabytesUsed=" + totalBackupGigabytesUsed +"]";
+ }
+
+ }
+
+ private List<RateLimit> rate;
+
+ private AbsoluteLimit absolute;
+
+ /**
+ * @return the rate
+ */
+ public List<RateLimit> getRate() {
+ return rate;
+ }
+
+ /**
+ * @return the absolute
+ */
+ public AbsoluteLimit getAbsolute() {
+ return absolute;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "Limits [rate=" + rate + ", absolute=" + absolute + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Metadata.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Metadata.java
new file mode 100755
index 0000000..b8ed1df
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Metadata.java
@@ -0,0 +1,49 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.util.Map;
+
+public class Metadata {
+
+ private Map<String, String> metadata;
+
+ /**
+ * @return the metadata
+ */
+ public Map<String, String> getMetadata() {
+ return metadata;
+ }
+
+ /**
+ * Set the metadata
+ *
+ * @param metadata
+ */
+ public void setMetadata(Map<String, String> metadata) {
+ this.metadata = metadata;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "Metadata [metadata=" + metadata + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Pool.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Pool.java
new file mode 100755
index 0000000..4f292c4
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Pool.java
@@ -0,0 +1,56 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.List;
+import java.util.Map;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+/**
+ * Model for Pool
+ */
+@JsonRootName("pool")
+public class Pool implements Serializable {
+
+ private String name;
+
+ private Capabilities capabilities;
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ public Capabilities getCapabilities() {
+ return capabilities;
+ }
+
+ public void setCapabilities(Capabilities capabilities) {
+ this.capabilities = capabilities;
+ }
+
+ @Override
+ public String toString() {
+ return "Pool{"
+ + "name='" + name
+ + ", capabilities='" + capabilities
+ + '}';
+ }
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Pools.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Pools.java
new file mode 100755
index 0000000..771b0ac
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Pools.java
@@ -0,0 +1,47 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.Iterator;
+import java.util.List;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/**
+ * Model for List of pools
+ */
+public class Pools implements Iterable<Pool>, Serializable {
+
+ @JsonProperty("pools")
+ private List<Pool> list;
+
+ public List<Pool> getList() {
+ return list;
+ }
+
+ public void setList(List<Pool> list) {
+ this.list = list;
+ }
+
+ @Override
+ public Iterator<Pool> iterator() {
+ return list.iterator();
+ }
+
+ @Override
+ public String toString() {
+ return "Pools [list=" + list + "]";
+ }
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Snapshot.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Snapshot.java
new file mode 100755
index 0000000..6f78c8f
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Snapshot.java
@@ -0,0 +1,113 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.Map;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("snapshot")
+public class Snapshot implements Serializable {
+
+ private String id;
+
+ private String status;
+
+ private String name;
+
+ private String description;
+
+ @JsonProperty("volume_id")
+ private String volumeId;
+
+ private Integer size;
+
+ @JsonProperty("created_at")
+ private String createdAt;
+
+ private Map<String, String> metadata;
+
+ /**
+ * @return the id
+ */
+ public String getId() {
+ return id;
+ }
+
+ /**
+ * @return the status
+ */
+ public String getStatus() {
+ return status;
+ }
+
+ /**
+ * @return the name
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * @return the description
+ */
+ public String getDescription() {
+ return description;
+ }
+
+ /**
+ * @return the volumeId
+ */
+ public String getVolumeId() {
+ return volumeId;
+ }
+
+ /**
+ * @return the size
+ */
+ public Integer getSize() {
+ return size;
+ }
+
+ /**
+ * @return the createdAt
+ */
+ public String getCreatedAt() {
+ return createdAt;
+ }
+
+ /**
+ * @return the metadata
+ */
+ public Map<String, String> getMetadata() {
+ return metadata;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "Snapshot [id=" + id + ", status=" + status +
+ ", name=" + name + ", description=" + description +
+ ", volumeId=" + volumeId + ", size=" + size +
+ ", createdAt=" + createdAt + ", metadata=" + metadata + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/SnapshotForCreate.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/SnapshotForCreate.java
new file mode 100755
index 0000000..e2896b8
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/SnapshotForCreate.java
@@ -0,0 +1,105 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("snapshot")
+public class SnapshotForCreate implements Serializable {
+
+ @JsonProperty("volume_id")
+ private String volumeId;
+
+ private Boolean force;
+
+ private String name;
+
+ private String description;
+
+ /**
+ * @return the volumeId
+ */
+ public String getVolumeId() {
+ return volumeId;
+ }
+
+ /**
+ * @param volumeId
+ * the volumeId to set
+ */
+ public void setVolumeId(String volumeId) {
+ this.volumeId = volumeId;
+ }
+
+ /**
+ * @return the force
+ */
+ public Boolean getForce() {
+ return force;
+ }
+
+ /**
+ * @param force
+ * the force to set
+ */
+ public void setForce(Boolean force) {
+ this.force = force;
+ }
+
+ /**
+ * @return the name
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * @param name
+ * the name to set
+ */
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ /**
+ * @return the description
+ */
+ public String getDescription() {
+ return description;
+ }
+
+ /**
+ * @param description
+ * the description to set
+ */
+ public void setDescription(String description) {
+ this.description = description;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "SnapshotForCreate [volumeId=" + volumeId + ", force=" + force
+ + ", name=" + name + ", description=" + description + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/SnapshotForUpdate.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/SnapshotForUpdate.java
new file mode 100755
index 0000000..dd16b55
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/SnapshotForUpdate.java
@@ -0,0 +1,68 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("snapshot")
+public class SnapshotForUpdate implements Serializable {
+
+ private String name;
+
+ private String description;
+
+ /**
+ * @return the name
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * @param name
+ * the name to set
+ */
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ /**
+ * @return the description
+ */
+ public String getDescription() {
+ return description;
+ }
+
+ /**
+ * @param description
+ * the description to set
+ */
+ public void setDescription(String description) {
+ this.description = description;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "SnapshotForUpdate [name=" + name + ", description=" + description + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Snapshots.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Snapshots.java
new file mode 100755
index 0000000..aec991a
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Snapshots.java
@@ -0,0 +1,50 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.Iterator;
+import java.util.List;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+public class Snapshots implements Iterable<Snapshot>, Serializable {
+
+ @JsonProperty("snapshots")
+ private List<Snapshot> list;
+
+ /**
+ * @return the list
+ */
+ public List<Snapshot> getList() {
+ return list;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "Snapshots [list=" + list + "]";
+ }
+
+ @Override
+ public Iterator<Snapshot> iterator() {
+ return list.iterator();
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Volume.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Volume.java
new file mode 100755
index 0000000..6d0068c
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Volume.java
@@ -0,0 +1,180 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+import java.io.Serializable;
+import java.util.List;
+import java.util.Map;
+
+@JsonRootName("volume")
+public class Volume implements Serializable {
+
+ private String id;
+
+ private String status;
+
+ private String name;
+
+ private String description;
+
+ @JsonProperty("availability_zone")
+ private String availabilityZone;
+
+ @JsonProperty("volume_type")
+ private String volumeType;
+
+ @JsonProperty("snapshot_id")
+ private String snapshotId;
+
+ @JsonProperty("source_volid")
+ private String sourceVolid;
+
+ @JsonProperty("bootable")
+ private Boolean bootable;
+
+ private List<Map<String, Object>> attachments;
+
+ private Map<String, String> metadata;
+
+ @JsonProperty("created_at")
+ private String createdAt;
+
+ private Integer size;
+
+ /**
+ * @return the id
+ */
+ public String getId() {
+ return id;
+ }
+
+ /**
+ * @return the status
+ */
+ public String getStatus() {
+ return status;
+ }
+
+ /**
+ * @return the name
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * @return the description
+ */
+ public String getDescription() {
+ return description;
+ }
+
+ /**
+ * @return the availabilityZone
+ */
+ public String getAvailabilityZone() {
+ return availabilityZone;
+ }
+
+ /**
+ * @return the volumeType
+ */
+ public String getVolumeType() {
+ return volumeType;
+ }
+
+ /**
+ * @return the snapshotId
+ */
+ public String getSnapshotId() {
+ return snapshotId;
+ }
+
+ /**
+ * @return the ID of an existing volume (specify in order to create a volume from an existing volume)
+ */
+ public String getSourceVolid() {
+ return sourceVolid;
+ }
+
+ /**
+ * @param sourceVolid
+ * to set
+ */
+ public void setSourceVolid(String sourceVolid) {
+ this.sourceVolid = sourceVolid;
+ }
+
+ /**
+ * @param volumeType
+ * to set
+ */
+ public void setVolumeType(String volumeType) {
+ this.volumeType = volumeType;
+ }
+
+ /**
+ * @return the bootable flag to set
+ */
+ public Boolean getBootable() {
+ return bootable;
+ }
+
+ /**
+ * @return the attachments
+ */
+ public List<Map<String, Object>> getAttachments() {
+ return attachments;
+ }
+
+ /**
+ * @return the metadata
+ */
+ public Map<String, String> getMetadata() {
+ return metadata;
+ }
+
+ /**
+ * @return the createdAt
+ */
+ public String getCreatedAt() {
+ return createdAt;
+ }
+
+ /**
+ * @return the size
+ */
+ public Integer getSize() {
+ return size;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "Volume [id=" + id + ", status=" + status +
+ ", name=" + name + ", description=" + description +
+ ", availabilityZone=" + availabilityZone + ", volumeType=" + volumeType +
+ ", snapshotId=" + snapshotId + ", attachments=" + attachments +
+ ", metadata=" + metadata + ", createdAt=" + createdAt + ", size=" + size + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForCreate.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForCreate.java
new file mode 100755
index 0000000..dd70820
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForCreate.java
@@ -0,0 +1,225 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.Map;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("volume")
+public class VolumeForCreate implements Serializable {
+
+ private Integer size;
+
+ @JsonProperty("availability_zone")
+ private String availabilityZone;
+
+ @JsonProperty("display_name")
+ private String name;
+
+ @JsonProperty("display_description")
+ private String description;
+
+ @JsonProperty("snapshot_id")
+ private String snapshotId;
+
+ @JsonProperty("source_volid")
+ private String sourceVolid;
+
+ @JsonProperty("imageRef")
+ private String imageRef;
+
+ @JsonProperty("volume_type")
+ private String volumeType;
+
+ @JsonProperty("bootable")
+ private Boolean bootable;
+
+ private Map<String, String> metadata;
+
+ /**
+ * @return the size
+ */
+ public Integer getSize() {
+ return size;
+ }
+
+ /**
+ * @param size
+ * the size to set
+ */
+ public void setSize(Integer size) {
+ this.size = size;
+ }
+
+ /**
+ * @return the availabilityZone
+ */
+ public String getAvailabilityZone() {
+ return availabilityZone;
+ }
+
+ /**
+ * @param availabilityZone
+ * the availabilityZone to set
+ */
+ public void setAvailabilityZone(String availabilityZone) {
+ this.availabilityZone = availabilityZone;
+ }
+
+ /**
+ * @return the name
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * @param name
+ * the name to set
+ */
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ /**
+ * @return the description
+ */
+ public String getDescription() {
+ return description;
+ }
+
+ /**
+ * @param description
+ * the description to set
+ */
+ public void setDescription(String description) {
+ this.description = description;
+ }
+
+ /**
+ * @return the snapshotId
+ */
+ public String getSnapshotId() {
+ return snapshotId;
+ }
+
+ /**
+ * @param snapshotId
+ * the snapshotId to set
+ */
+ public void setSnapshotId(String snapshotId) {
+ this.snapshotId = snapshotId;
+ }
+
+ /**
+ * @return the ID of an existing volume (specify in order to create a volume from an existing volume)
+ */
+ public String getSourceVolid() {
+ return sourceVolid;
+ }
+
+ /**
+ * @param sourceVolid
+ * to set
+ */
+ public void setSourceVolid(String sourceVolid) {
+ this.sourceVolid = sourceVolid;
+ }
+
+ /**
+ * @return the ID of the image from which you want to create the volume (required to create a bootable volume)
+ */
+ public String getImageRef() {
+ return imageRef;
+ }
+
+ /**
+ * @param imageRef
+ * to set
+ */
+ public void setImageRef(String imageRef) {
+ this.imageRef = imageRef;
+ }
+
+ /**
+ * @return the associated volume type
+ */
+ public String getVolumeType() {
+ return volumeType;
+ }
+
+ /**
+ * @param volumeType
+ * to set
+ */
+ public void setVolumeType(String volumeType) {
+ this.volumeType = volumeType;
+ }
+
+ /**
+ * @return the bootable flag to set
+ */
+ public Boolean getBootable() {
+ return bootable;
+ }
+
+ /**
+ * Enables or disables the bootable attribute. You can boot an instance from a bootable volume.
+ *
+ * @param bootable
+ * flag
+ */
+ public void setBootable(Boolean bootable) {
+ this.bootable = bootable;
+ }
+
+ /**
+ * @return the metadata
+ */
+ public Map<String, String> getMetadata() {
+ return metadata;
+ }
+
+ /**
+ * @param metadata
+ * the metadata to set
+ */
+ public void setMetadata(Map<String, String> metadata) {
+ this.metadata = metadata;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "VolumeForCreate [size=" + size +
+ ", availabilityZone=" + availabilityZone +
+ ", name=" + name +
+ ", description=" + description +
+ ", snapshotId=" + snapshotId +
+ ", source_volid=" + sourceVolid +
+ ", imageRef=" + imageRef +
+ ", volume_type=" + volumeType +
+ ", bootable=" + bootable +
+ ", metadata=" + metadata + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForExtend.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForExtend.java
new file mode 100755
index 0000000..75eee2d
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForExtend.java
@@ -0,0 +1,53 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("os-extend")
+public class VolumeForExtend implements Serializable {
+
+ @JsonProperty("new_size")
+ private Integer size;
+
+ /**
+ * @return the size
+ */
+ public Integer getSize() {
+ return size;
+ }
+
+ /**
+ * @param size
+ * the size to set
+ */
+ public void setSize(Integer size) {
+ this.size = size;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "VolumeForExtend [size=" + size + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForImageCreate.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForImageCreate.java
new file mode 100755
index 0000000..916892f
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForImageCreate.java
@@ -0,0 +1,85 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("os-volume_upload_image")
+public class VolumeForImageCreate implements Serializable {
+ String volumeId;
+ String tenantId;
+
+ public String getTenantId() {
+ return tenantId;
+ }
+
+ public void setTenantId(String tenantId) {
+ this.tenantId = tenantId;
+ }
+
+ @JsonProperty("force")
+ private Boolean force;
+
+ public Boolean getForce() {
+ return force;
+ }
+
+ public void setForce(Boolean force) {
+ this.force = force;
+ }
+
+ @JsonProperty("container_format")
+ String container_format;
+ @JsonProperty("disk_format")
+ String disk_format;
+ @JsonProperty("image_name")
+ String image_name;
+
+ public String getVolumeId() {
+ return volumeId;
+ }
+
+ public void setVolumeId(String volumeId) {
+ this.volumeId = volumeId;
+ }
+
+ public String getContainer_format() {
+ return container_format;
+ }
+
+ public void setContainer_format(String container_format) {
+ this.container_format = container_format;
+ }
+
+ public String getDisk_format() {
+ return disk_format;
+ }
+
+ public void setDisk_format(String disk_format) {
+ this.disk_format = disk_format;
+ }
+
+ public String getImage_name() {
+ return image_name;
+ }
+
+ public void setImage_name(String image_name) {
+ this.image_name = image_name;
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForUpdate.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForUpdate.java
new file mode 100755
index 0000000..5746f49
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeForUpdate.java
@@ -0,0 +1,68 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("volume")
+public class VolumeForUpdate implements Serializable {
+
+ private String name;
+
+ private String description;
+
+ /**
+ * @return the name
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * @param name
+ * the name to set
+ */
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ /**
+ * @return the description
+ */
+ public String getDescription() {
+ return description;
+ }
+
+ /**
+ * @param description
+ * the description to set
+ */
+ public void setDescription(String description) {
+ this.description = description;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "VolumeForUpdate [name=" + name + ", description=" + description + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeType.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeType.java
new file mode 100755
index 0000000..73fdfe1
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeType.java
@@ -0,0 +1,64 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.Map;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("volume_type")
+public class VolumeType implements Serializable {
+
+ private String id;
+
+ private String name;
+
+ @JsonProperty("extra_specs")
+ private Map<String, String> extraSpecs;
+
+ /**
+ * @return the id
+ */
+ public String getId() {
+ return id;
+ }
+
+ /**
+ * @return the name
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * @return the extra_specs
+ */
+ public Map<String, String> getExtraSpecs() {
+ return extraSpecs;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "VolumeType [id=" + id + ", name=" + name + ", extra_specs=" + extraSpecs + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeTypeForCreate.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeTypeForCreate.java
new file mode 100755
index 0000000..e228c27
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeTypeForCreate.java
@@ -0,0 +1,71 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.Map;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonRootName;
+
+@JsonRootName("volume_type")
+public class VolumeTypeForCreate implements Serializable {
+
+ private String name;
+
+ @JsonProperty("extra_specs")
+ private Map<String, String> extraSpecs;
+
+ /**
+ * @return the name
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * @param name
+ * the name to set
+ */
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ /**
+ * @return the extraSpecs
+ */
+ public Map<String, String> getExtraSpecs() {
+ return extraSpecs;
+ }
+
+ /**
+ * @param extraSpecs
+ * the extra_specs to set
+ */
+ public void setExtraSpecs(Map<String, String> extraSpecs) {
+ this.extraSpecs = extraSpecs;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "VolumeForCreate [name=" + name + ", metadata=" + extraSpecs + "]";
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeTypes.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeTypes.java
new file mode 100755
index 0000000..761a702
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/VolumeTypes.java
@@ -0,0 +1,50 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.Iterator;
+import java.util.List;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+public class VolumeTypes implements Iterable<VolumeType>, Serializable {
+
+ @JsonProperty("volume_types")
+ private List<VolumeType> list;
+
+ /**
+ * @return the list
+ */
+ public List<VolumeType> getList() {
+ return list;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "Volume Types [list=" + list + "]";
+ }
+
+ @Override
+ public Iterator<VolumeType> iterator() {
+ return list.iterator();
+ }
+
+}
diff --git a/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Volumes.java b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Volumes.java
new file mode 100755
index 0000000..096bf9a
--- /dev/null
+++ b/cinder-model/src/main/java/com/woorea/openstack/cinder/model/Volumes.java
@@ -0,0 +1,50 @@
+/* ============LICENSE_START=======================================================
+ * 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.
+ * ============LICENSE_END=========================================================
+ */
+package com.woorea.openstack.cinder.model;
+
+import java.io.Serializable;
+import java.util.Iterator;
+import java.util.List;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+public class Volumes implements Iterable<Volume>, Serializable {
+
+ @JsonProperty("volumes")
+ private List<Volume> list;
+
+ /**
+ * @return the list
+ */
+ public List<Volume> getList() {
+ return list;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see java.lang.Object#toString()
+ */
+ @Override
+ public String toString() {
+ return "Volumes [list=" + list + "]";
+ }
+
+ @Override
+ public Iterator<Volume> iterator() {
+ return list.iterator();
+ }
+
+}