File tree Expand file tree Collapse file tree 5 files changed +25
-8
lines changed
src/main/java/org/openstack Expand file tree Collapse file tree 5 files changed +25
-8
lines changed Original file line number Diff line number Diff line change 33import java .util .Properties ;
44
55import javax .ws .rs .client .Target ;
6+ import javax .ws .rs .core .MediaType ;
67
78import org .openstack .api .common .Resource ;
89
1415 */
1516public class QuotasResource extends Resource {
1617
17- protected QuotasResource (Target target , Properties properties ) {
18+ public QuotasResource (Target target , Properties properties ) {
1819 super (target , properties );
1920 }
2021
21- public String show () {
22- return null ;
22+ public String get () {
23+ return target . request ( MediaType . APPLICATION_JSON ). get ( String . class ) ;
2324 }
2425
2526 public String update () {
Original file line number Diff line number Diff line change 33import java .util .Properties ;
44
55import javax .ws .rs .client .Target ;
6+ import javax .ws .rs .core .MediaType ;
67
78import org .openstack .api .common .Resource ;
89
@@ -17,5 +18,9 @@ public class SimpleTenantUsageResource extends Resource {
1718 public SimpleTenantUsageResource (Target target , Properties properties ) {
1819 super (target , properties );
1920 }
21+
22+ public String get () {
23+ return target .request (MediaType .APPLICATION_JSON ).get (String .class );
24+ }
2025
2126}
Original file line number Diff line number Diff line change 33import java .util .Properties ;
44
55import javax .ws .rs .client .Target ;
6+ import javax .ws .rs .core .MediaType ;
67
78import org .openstack .api .common .Resource ;
89
910public class FloatingIpDnsResource extends Resource {
1011
11- protected FloatingIpDnsResource (Target target , Properties properties ) {
12+ public FloatingIpDnsResource (Target target , Properties properties ) {
1213 super (target , properties );
1314 }
1415
15-
16+ public String get () {
17+ return target .request (MediaType .APPLICATION_JSON ).get (String .class );
18+ }
19+
1620}
Original file line number Diff line number Diff line change 33import java .util .Properties ;
44
55import javax .ws .rs .client .Target ;
6+ import javax .ws .rs .core .MediaType ;
67
78import org .openstack .api .common .Resource ;
89
@@ -19,9 +20,14 @@ public class VolumeTypeResource extends Resource {
1920 // return new FlavorsRepresentation(client, list);
2021 // }
2122
22- protected VolumeTypeResource (Target target , Properties properties ) {
23+ public VolumeTypeResource (Target target , Properties properties ) {
2324 super (target , properties );
2425 }
26+
27+ public String get () {
28+ return target .request (MediaType .APPLICATION_JSON ).get (String .class );
29+ }
30+
2531 public void delete () {
2632 }
2733
Original file line number Diff line number Diff line change 11package org .openstack .model .compute .nova ;
22
33import java .io .Serializable ;
4+ import java .util .ArrayList ;
45import java .util .HashMap ;
56import java .util .List ;
67import java .util .Map ;
@@ -124,15 +125,15 @@ public void setContents(String contents) {
124125
125126 @ XmlElementWrapper (name = "personality" )
126127 @ XmlElement (name ="file" )
127- private List <File > personality ;
128+ private List <File > personality = new ArrayList < NovaServerForCreate . File >() ;
128129
129130 /**
130131 * This security groups are not created on the fly. They must be exist in
131132 * the tenant.
132133 */
133134 @ XmlElementWrapper (name = "security_groups" )
134135 @ XmlElement (name = "security_group" )
135- private List <SecurityGroup > securityGroups ;
136+ private List <SecurityGroup > securityGroups = new ArrayList < NovaServerForCreate . SecurityGroup >() ;
136137
137138 /* (non-Javadoc)
138139 * @see org.openstack.model.compute.nova.ServerForCreate#getName()
You can’t perform that action at this time.
0 commit comments