Given a known
@ActionID(category=Constants.CATEGORY, id=Constants.ID) ...
it is often useful to load that Action for some sort of programmatic presentation. Currently you need to do
FileUtil.getConfigObject("Actions/" + Constants.CATEGORY + "/" + Constants.ID.replace('.', '-') + ".instance", Action.class)
which is awkward. This should rather be a utility method in Actions.
Created attachment 114514 [details]
Employed the new method in a bunch more places. Also changed it to throw IAE when the corresponding @ActionID would have been rejected during compilation, to defend against likely mistakes such as using '-' as a package separator. core-main #f5e9614e5a7d
Integrated into 'main-golden'
User: Jesse Glick <firstname.lastname@example.org>
Log: #205798: API to retrieve a specific action by ID.