Package org.seedstack.seed.command
Interface PrettyCommand<T>
-
- Type Parameters:
T- The return parameter of theCommand.execute(Object)method.
- All Superinterfaces:
Command<T>
public interface PrettyCommand<T> extends Command<T>
This interface can be implemented by commands that are able to prettify their output object as a string.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Stringprettify(T object)This method is called with the return value ofCommand.execute(Object)as parameter if the execution context allows pretty output.
-
-
-
Method Detail
-
prettify
String prettify(T object) throws Exception
This method is called with the return value ofCommand.execute(Object)as parameter if the execution context allows pretty output.- Parameters:
object- the return value ofCommand.execute(Object)- Returns:
- a formatted string for pretty output.
- Throws:
Exception- if the prettifying process throws an error.
-
-