public static String getName( Path pluginDir )
    {
        final String name = getElementValue( pluginDir, "/plugin/name" );
        final String pluginName = getCanonicalName( pluginDir );
        if ( name != null ) {
            try {
                return AdminConsole.getAdminText(name, pluginName);
            } catch (final Exception e) {
                Log.warn("Unexpected exception attempting to retrieve admin text", e);
                // Default to non-internationalised name
                return name;
            }
        }
        return pluginName;
    }
Returns the name of a plugin. The value is retrieved from the plugin.xml file of the plugin. If the value could not
be found, {@code null} will be returned. Note that this value is a 'human readable' name, which can be distinct
from the name of the plugin directory as returned by {@link #getCanonicalName(Path)}.

@param pluginDir the path of the plugin directory.
@return the plugin's human-readable name.
xmppserver/src/main/java/org/jivesoftware/openfire/container/PluginMetadataHelper.java