Is it possible to transform this code to a Java 8 Optional one-line expression?
long lastPollTime; if (object != null) { lastPollTime = object.getTime();
long lastPollTime = object != null ?object.getTime():0;