All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.servicerocket.confluence.plugin.utility.library.InjectionAdaptorModuleDescriptor Maven / Gradle / Ivy

The newest version!
package com.servicerocket.confluence.plugin.utility.library;

import com.atlassian.plugin.Plugin;
import com.atlassian.plugin.descriptors.AbstractModuleDescriptor;
import com.atlassian.plugin.module.ModuleFactory;
import com.servicerocket.confluence.randombits.supplier.core.param.Adaptor;
import org.dom4j.Element;

/**
 *
 */
public class InjectionAdaptorModuleDescriptor extends AbstractModuleDescriptor> {

    private Adaptor adaptor;

    public InjectionAdaptorModuleDescriptor(ModuleFactory moduleFactory) {
        super(moduleFactory);
    }

    @Override
    public void init(@NotNull final Plugin plugin, @NotNull Element element) {
        super.init(plugin, element);
        adaptor = null;
    }

    @Override
    public Adaptor getModule() {
        if (adaptor == null)
            adaptor = moduleFactory.createModule(moduleClassName, this);
        return adaptor;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy