All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.machinezoo.noexception.optional.FallbackLongSupplier Maven / Gradle / Ivy

There is a newer version: 1.9.1
Show newest version
// Part of NoException: https://noexception.machinezoo.com
package com.machinezoo.noexception.optional;

import java.util.function.*;
import lombok.*;

@RequiredArgsConstructor final class FallbackLongSupplier implements LongSupplier {
	private final OptionalLongSupplier inner;
	private final LongSupplier source;
	@Override public long getAsLong() {
		return inner.get().orElseGet(source);
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy