3535import com .cloud .storage .Storage .StoragePoolType ;
3636import com .cloud .storage .Volume ;
3737import com .cloud .utils .db .GenericDao ;
38- import com .cloud .utils .exception .CloudRuntimeException ;
3938import com .cloud .vm .VirtualMachine ;
4039import com .cloud .vm .VirtualMachine .State ;
4140
@@ -48,10 +47,10 @@ public class UserVmJoinVO extends BaseViewVO implements ControlledViewEntity {
4847 private long id ;
4948
5049 @ Column (name ="name" , updatable =false , nullable =false , length =255 )
51- private final String name = null ;
50+ private String name = null ;
5251
5352 @ Column (name ="display_name" , updatable =false , nullable =false , length =255 )
54- private final String displayName = null ;
53+ private String displayName = null ;
5554
5655 @ Column (name ="account_id" )
5756 private long accountId ;
@@ -60,7 +59,7 @@ public class UserVmJoinVO extends BaseViewVO implements ControlledViewEntity {
6059 private String accountUuid ;
6160
6261 @ Column (name ="account_name" )
63- private final String accountName = null ;
62+ private String accountName = null ;
6463
6564 @ Column (name ="account_type" )
6665 private short accountType ;
@@ -72,10 +71,10 @@ public class UserVmJoinVO extends BaseViewVO implements ControlledViewEntity {
7271 private String domainUuid ;
7372
7473 @ Column (name ="domain_name" )
75- private final String domainName = null ;
74+ private String domainName = null ;
7675
7776 @ Column (name ="domain_path" )
78- private final String domainPath = null ;
77+ private String domainPath = null ;
7978
8079 @ Column (name ="instance_group_id" )
8180 private long instanceGroupId ;
@@ -97,7 +96,7 @@ public class UserVmJoinVO extends BaseViewVO implements ControlledViewEntity {
9796 */
9897 @ Enumerated (value =EnumType .STRING )
9998 @ Column (name ="state" , updatable =true , nullable =false , length =32 )
100- private final State state = null ;
99+ private State state = null ;
101100
102101 @ Column (name =GenericDao .CREATED_COLUMN )
103102 private Date created ;
@@ -150,7 +149,7 @@ public class UserVmJoinVO extends BaseViewVO implements ControlledViewEntity {
150149 private String dataCenterUuid ;
151150
152151 @ Column (name ="data_center_name" )
153- private final String dataCenterName = null ;
152+ private String dataCenterName = null ;
154153
155154 @ Column (name ="security_group_enabled" )
156155 private boolean securityGroupEnabled ;
@@ -226,7 +225,7 @@ public class UserVmJoinVO extends BaseViewVO implements ControlledViewEntity {
226225 private String volume_uuid ;
227226
228227 @ Column (name = "volume_device_id" )
229- private final Long volumeDeviceId = null ;
228+ private Long volumeDeviceId = null ;
230229
231230 @ Column (name = "volume_type" )
232231 @ Enumerated (EnumType .STRING )
@@ -727,11 +726,9 @@ public Map<String, String> getDetails() {
727726 }
728727
729728 public String getDetail (String name ) {
730- if (details == null ) {
731- throw new CloudRuntimeException ("No details to get. Did you forget to load the details?" );
732- }
729+ assert (details != null ) : "Did you forget to load the details?" ;
733730
734- return details .get (name );
731+ return details != null ? details .get (name ) : null ;
735732 }
736733
737734 public String getUserData () {
0 commit comments