firstOr


Description:

public T firstOr (T fallback)

Returns the first element or the fallback value if empty.

Parameters:

fallback

the fallback value.

Returns:

first element or fallback when empty.