/**
   * Create and return a List of Strings found in the PluginFile.
   *
   * @param pluginFile the pluginFile to be read
   * @return a List of Strings representing the lines of this file
   */
  public static List<String> readPluginFile(final PluginFile pluginFile) throws PluginException {
    if (!pluginFile.exists() || pluginFile.isDirectory()) {
      throw PluginException.create(PluginException.Type.DOES_NOT_EXIST, pluginFile.getFilename());
    }
    List<String> list;
    try {
      list = Files.readAllLines(pluginFile.toPath(), Plugin.CHARSET);

    } catch (IOException | SecurityException e) {
      throw PluginException.create(
          PluginException.Type.FILE_READ_ERROR, e, pluginFile.getFilename());
    }
    return list;
  }