javadoc and refactoring in PluginUtil