Interface ModuleDescription.ForLoadedModule.Optional

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.Object orElse​(java.lang.Object value, java.lang.Object fallback)
      Returns the value if present, otherwise returns the fallback value.
    • Method Detail

      • orElse

        @MaybeNull
        java.lang.Object orElse​(java.lang.Object value,
                                @MaybeNull
                                java.lang.Object fallback)
        Returns the value if present, otherwise returns the fallback value.
        Parameters:
        value - The java.util.Optional instance.
        fallback - The fallback value to return if the optional is empty.
        Returns:
        The value if present, otherwise the fallback value.