mirror of https://github.com/apache/cloudstack.git
Use static inner class instead of enum for Param parameter (used in VirtualMachineProfile)
This commit is contained in:
parent
5aa91b6d55
commit
848cff6318
|
|
@ -40,12 +40,26 @@ import com.cloud.user.Account;
|
|||
* @param <T> a VirtualMachine
|
||||
*/
|
||||
public interface VirtualMachineProfile<T extends VirtualMachine> {
|
||||
|
||||
|
||||
enum Param {
|
||||
VmPassword,
|
||||
ControlNic,
|
||||
RestartNetwork,
|
||||
}
|
||||
public static class Param {
|
||||
|
||||
public static final Param VmPassword = new Param("VmPassword");
|
||||
public static final Param ControlNic = new Param("ControlNic");
|
||||
public static final Param RestartNetwork = new Param("RestartNetwork");
|
||||
|
||||
private String name;
|
||||
|
||||
public Param(String name) {
|
||||
synchronized(Param.class) {
|
||||
this.name = name;
|
||||
}
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
}
|
||||
|
||||
String getHostName();
|
||||
|
||||
|
|
|
|||
|
|
@ -1148,6 +1148,7 @@ public class SecondaryStorageManagerImpl implements SecondaryStorageVmManager, V
|
|||
_secStorageVmDao.update(secVm.getId(), secVm);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean finalizeStart(VirtualMachineProfile<SecondaryStorageVmVO> profile, long hostId, Commands cmds, ReservationContext context) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue