-
Notifications
You must be signed in to change notification settings - Fork 163
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
24 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,12 +26,24 @@ | |
/** | ||
* Function. | ||
* | ||
* <p>If you don't want to have any checked exceptions being thrown | ||
* out of your {@link Func}, you can use | ||
* {@link org.cactoos.func.UncheckedFunc} decorator. Also | ||
* you may try {@link org.cactoos.func.IoCheckedFunc}.</p> | ||
* | ||
* <p>If you want to cache the result of the {@link Func} and | ||
* make sure it doesn't calculate anything twice, you can use | ||
* {@link org.cactoos.func.StickyFunc} decorator.</p> | ||
* | ||
* <p>There is no thread-safety guarantee. | ||
* | ||
* @author Yegor Bugayenko ([email protected]) | ||
* @version $Id$ | ||
* @param <X> Type of input | ||
* @param <Y> Type of output | ||
* @see org.cactoos.func.StickyFunc | ||
* @see org.cactoos.func.UncheckedFunc | ||
* @see org.cactoos.func.IoCheckedFunc | ||
* @since 0.1 | ||
*/ | ||
public interface Func<X, Y> { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,11 +26,23 @@ | |
/** | ||
* Scalar. | ||
* | ||
* <p>If you don't want to have any checked exceptions being thrown | ||
* out of your {@link Scalar}, you can use | ||
* {@link org.cactoos.func.UncheckedScalar} decorator. Also | ||
* you may try {@link org.cactoos.func.IoCheckedScalar}.</p> | ||
* | ||
* <p>If you want to cache the result of the {@link Scalar} and | ||
* make sure it doesn't calculate anything twice, you can use | ||
* {@link org.cactoos.func.StickyScalar} decorator.</p> | ||
* | ||
* <p>There is no thread-safety guarantee. | ||
* | ||
* @author Yegor Bugayenko ([email protected]) | ||
* @version $Id$ | ||
* @param <T> Type of result | ||
* @see org.cactoos.func.StickyScalar | ||
* @see org.cactoos.func.UncheckedScalar | ||
* @see org.cactoos.func.IoCheckedScalar | ||
* @since 0.1 | ||
*/ | ||
public interface Scalar<T> { | ||
|