Improve readability.

This commit is contained in:
Michael Lipp 2025-01-26 14:52:26 +01:00
parent 224855efd3
commit 981cbe2744
3 changed files with 65 additions and 20 deletions

View file

@ -353,6 +353,24 @@ public class VmDefinition {
.map("True"::equals).orElse(false));
}
/**
* Return true if the console is in use.
*
* @return true, if successful
*/
public boolean consoleConnected() {
return conditionStatus("ConsoleConnected").orElse(false);
}
/**
* Return the last known console user.
*
* @return the optional
*/
public Optional<String> consoleUser() {
return this.<String> fromStatus("consoleUser");
}
/**
* Set extra data (locally used, unknown to kubernetes).
*