// Path: src/main/java/de/agilecoders/wicket/jquery/settings/IWicketJquerySelectorsSettings.java
// public interface IWicketJquerySelectorsSettings {
// 
//     /**
//      * @return object mapper factory
//      */
//     ObjectMapperFactory getObjectMapperFactory();
// }
// 
// Path: src/main/java/de/agilecoders/wicket/jquery/settings/WicketJquerySelectorsSettings.java
// public class WicketJquerySelectorsSettings implements IWicketJquerySelectorsSettings {
// 
//     private ObjectMapperFactory objectMapperFactory;
// 
//     /**
//      * Construct.
//      */
//     public WicketJquerySelectorsSettings() {
//         objectMapperFactory = new SingletonObjectMapperFactory();
//     }
// 
//     /**
//      * @return object mapper factory
//      */
//     @Override
//     public ObjectMapperFactory getObjectMapperFactory() {
//         return objectMapperFactory;
//     }
// 
//     /**
//      * sets the object mapper factory
//      *
//      * @param objectMapperFactory the object mapper factory to use for json serialization
//      * @return this instance for chaining
//      */
//     public WicketJquerySelectorsSettings setObjectMapperFactory(ObjectMapperFactory objectMapperFactory) {
//         this.objectMapperFactory = objectMapperFactory;
//         return this;
//     }
// }


import de.agilecoders.wicket.jquery.settings.IWicketJquerySelectorsSettings;
import de.agilecoders.wicket.jquery.settings.WicketJquerySelectorsSettings;
import org.apache.wicket.Application;
import org.apache.wicket.MetaDataKey;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
package de.agilecoders.wicket.jquery;


/**
 * base wicket-jquery-selectors class that is responsible for installation of custom settings.
 *
 * @author Michael Haitz <michael.haitz@agilecoders.de>
 */
public final class WicketJquerySelectors {
    private static final Logger LOG = LoggerFactory.getLogger("wicket-jquery-selectors");

    /**
     * The {@link org.apache.wicket.MetaDataKey} used to retrieve the {@link de.agilecoders.wicket.jquery.settings.IWicketJquerySelectorsSettings}
     * from the Wicket {@link Appendable}.
     */
    private static final MetaDataKey<IWicketJquerySelectorsSettings> JQUERY_SELECTORS_SETTINGS_METADATA_KEY = new MetaDataKey<IWicketJquerySelectorsSettings>() {
    };

    /**
     * Checks whether this library support is already installed
     *
     * @param application the wicket application
     * @return {@code true} if library is already installed, otherwise {@code false}
     */
    public static boolean isInstalled(Application application) {
        return application != null && application.getMetaData(JQUERY_SELECTORS_SETTINGS_METADATA_KEY) != null;
    }
    /**
     * installs the library to given application
     *
     * @param app the wicket application
     */
    public static void install(final Application app) {
        install(app, null);
    }

    /**
     * installs the library settings to given app.
     *
     * @param app      the wicket application
     * @param settings the settings to use
     */
// Path: src/main/java/de/agilecoders/wicket/jquery/settings/IWicketJquerySelectorsSettings.java
// public interface IWicketJquerySelectorsSettings {
// 
//     /**
//      * @return object mapper factory
//      */
//     ObjectMapperFactory getObjectMapperFactory();
// }
// 
// Path: src/main/java/de/agilecoders/wicket/jquery/settings/WicketJquerySelectorsSettings.java
// public class WicketJquerySelectorsSettings implements IWicketJquerySelectorsSettings {
// 
//     private ObjectMapperFactory objectMapperFactory;
// 
//     /**
//      * Construct.
//      */
//     public WicketJquerySelectorsSettings() {
//         objectMapperFactory = new SingletonObjectMapperFactory();
//     }
// 
//     /**
//      * @return object mapper factory
//      */
//     @Override
//     public ObjectMapperFactory getObjectMapperFactory() {
//         return objectMapperFactory;
//     }
// 
//     /**
//      * sets the object mapper factory
//      *
//      * @param objectMapperFactory the object mapper factory to use for json serialization
//      * @return this instance for chaining
//      */
//     public WicketJquerySelectorsSettings setObjectMapperFactory(ObjectMapperFactory objectMapperFactory) {
//         this.objectMapperFactory = objectMapperFactory;
//         return this;
//     }
// }


// Path: src/main/java/de/agilecoders/wicket/jquery/WicketJquerySelectors.java
import de.agilecoders.wicket.jquery.settings.IWicketJquerySelectorsSettings;
import de.agilecoders.wicket.jquery.settings.WicketJquerySelectorsSettings;
import org.apache.wicket.Application;
import org.apache.wicket.MetaDataKey;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

package de.agilecoders.wicket.jquery;


/**
 * base wicket-jquery-selectors class that is responsible for installation of custom settings.
 *
 * @author Michael Haitz <michael.haitz@agilecoders.de>
 */
public final class WicketJquerySelectors {
    private static final Logger LOG = LoggerFactory.getLogger("wicket-jquery-selectors");

    /**
     * The {@link org.apache.wicket.MetaDataKey} used to retrieve the {@link de.agilecoders.wicket.jquery.settings.IWicketJquerySelectorsSettings}
     * from the Wicket {@link Appendable}.
     */
    private static final MetaDataKey<IWicketJquerySelectorsSettings> JQUERY_SELECTORS_SETTINGS_METADATA_KEY = new MetaDataKey<IWicketJquerySelectorsSettings>() {
    };

    /**
     * Checks whether this library support is already installed
     *
     * @param application the wicket application
     * @return {@code true} if library is already installed, otherwise {@code false}
     */
    public static boolean isInstalled(Application application) {
        return application != null && application.getMetaData(JQUERY_SELECTORS_SETTINGS_METADATA_KEY) != null;
    }
    /**
     * installs the library to given application
     *
     * @param app the wicket application
     */
    public static void install(final Application app) {
        install(app, null);
    }

    /**
     * installs the library settings to given app.
     *
     * @param app      the wicket application
     * @param settings the settings to use
     */
    public static void install(Application app, IWicketJquerySelectorsSettings settings) {