@Test(expectedExceptions = NullPointerException.class) public void testNoUnderlyingDiskGetId() { attachedDiskEntity.getUnderlyingDiskId(); }
public String getUnderlyingDiskId() { switch (kind) { case PersistentDisk.KIND: return persistentDiskId; case EphemeralDisk.KIND: return ephemeralDiskId; } throw new IllegalStateException("Unknown disk kind: " + kind); }
AttachedDiskEntity extends BaseEntity { public String getUnderlyingDiskId() { switch (kind) { case PersistentDisk.KIND: return persistentDiskId; case EphemeralDisk.KIND: return ephemeralDiskId; } throw new IllegalStateException("Unknown disk kind: " + kind); } }
AttachedDiskEntity extends BaseEntity { public String getUnderlyingDiskId() { switch (kind) { case PersistentDisk.KIND: return persistentDiskId; case EphemeralDisk.KIND: return ephemeralDiskId; } throw new IllegalStateException("Unknown disk kind: " + kind); }  }
AttachedDiskEntity extends BaseEntity { public String getUnderlyingDiskId() { switch (kind) { case PersistentDisk.KIND: return persistentDiskId; case EphemeralDisk.KIND: return ephemeralDiskId; } throw new IllegalStateException("Unknown disk kind: " + kind); }  @Override String getKind(); void setKind(String kind); String getPersistentDiskId(); void setPersistentDiskId(String persistentDiskId); String getEphemeralDiskId(); void setEphemeralDiskId(String ephemeralDiskId); PersistentDiskEntity getTransientPersistentDisk(); void setTransientPersistentDiskId(PersistentDiskEntity persistentDisk); EphemeralDiskEntity getTransientEphemeralDiskId(); void setETransientphemeralDisk(EphemeralDiskEntity ephemeralDisk); String getVmId(); void setVmId(String vmId); boolean isBootDisk(); void setBootDisk(boolean bootDisk); String getUnderlyingDiskId(); BaseDiskEntity getUnderlyingTransientDisk(); void setUnderlyingDiskIdAndKind(BaseDiskEntity diskEntity); String getDiskId(); }
AttachedDiskEntity extends BaseEntity { public String getUnderlyingDiskId() { switch (kind) { case PersistentDisk.KIND: return persistentDiskId; case EphemeralDisk.KIND: return ephemeralDiskId; } throw new IllegalStateException("Unknown disk kind: " + kind); }  @Override String getKind(); void setKind(String kind); String getPersistentDiskId(); void setPersistentDiskId(String persistentDiskId); String getEphemeralDiskId(); void setEphemeralDiskId(String ephemeralDiskId); PersistentDiskEntity getTransientPersistentDisk(); void setTransientPersistentDiskId(PersistentDiskEntity persistentDisk); EphemeralDiskEntity getTransientEphemeralDiskId(); void setETransientphemeralDisk(EphemeralDiskEntity ephemeralDisk); String getVmId(); void setVmId(String vmId); boolean isBootDisk(); void setBootDisk(boolean bootDisk); String getUnderlyingDiskId(); BaseDiskEntity getUnderlyingTransientDisk(); void setUnderlyingDiskIdAndKind(BaseDiskEntity diskEntity); String getDiskId();  }