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

com.aol.cyclops.guava.FromJavaslang Maven / Gradle / Ivy

There is a newer version: 9.0.0-MI7
Show newest version
package com.aol.cyclops.guava;

import javaslang.Function1;
import javaslang.control.Option;

import com.google.common.base.Function;
import com.google.common.base.Optional;

public class FromJavaslang {
	public static  Function f1(Function1 fn) {
		return (t) -> fn.apply(t);
	}

	public static  Optional option(Option o) {
		if (o.isEmpty())
			return Optional.absent();
		return Optional.of(o.get());
	}

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy