public interface Action
You can use the following code to extract the concrete type of an Action
.
List<Action> actions = ...
actions.forEach(x -> {
if (x instanceof AddFile) {
AddFile addFile = (AddFile) x;
...
} else if (x instanceof AddCDCFile) {
AddCDCFile addCDCFile = (AddCDCFile)x;
...
} else if ...
});