1 package com.guinetik.hexafun.hexa;
2
3 /**
4 * Core abstraction of business logic in Hexagonal Architecture.
5 * Each use case represents a specific operation or workflow in your domain.
6 * @param <I> Input type - the input to the use case
7 * @param <O> Output type - the result of the use case
8 */
9 @FunctionalInterface
10 public interface UseCase<I, O> {
11 /**
12 * Apply the use case logic to the input and produce an output.
13 * @param input The input to process
14 * @return The result of the use case
15 */
16 O apply(I input);
17 }