Package picocli
Interface CommandLine.Model.IExtensible
-
- Enclosing class:
- CommandLine.Model
public static interface CommandLine.Model.IExtensibleInterface to allow extending the capabilities of other interface without Java 8 default methods.Example usage:
// suppose we want to add a method `getInitialValueState` to `IAnnotatedElement` IAnnotatedElement element = getAnnotatedElement(); if (element instanceof IExtensible) { InitialValueState state = ((IExtensible) element).getExtension(InitialValueState.class); if (state != null) { // ... } }- Since:
- 4.3
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description <T> TgetExtension(java.lang.Class<T> cls)Returns an instance of the specified class, ornullif this extension is not supported.
-