io.ebeanservice.docstore.none.NoneDocStoreFactory Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ebean Show documentation
Show all versions of ebean Show documentation
composite of common runtime dependencies for all platforms
package io.ebeanservice.docstore.none;
import io.ebean.DocumentStore;
import io.ebean.plugin.SpiServer;
import io.ebeaninternal.server.deploy.BeanDescriptor;
import io.ebeaninternal.server.deploy.meta.DeployBeanDescriptor;
import io.ebeanservice.docstore.api.DocStoreBeanAdapter;
import io.ebeanservice.docstore.api.DocStoreFactory;
import io.ebeanservice.docstore.api.DocStoreIntegration;
import io.ebeanservice.docstore.api.DocStoreUpdateProcessor;
/**
* A stub implementation of DocStoreFactory that will barf if the docStore features are used.
*/
public class NoneDocStoreFactory implements DocStoreFactory {
@Override
public DocStoreIntegration create(SpiServer server) {
return new NoneIntegration();
}
@Override
public DocStoreBeanAdapter createAdapter(BeanDescriptor desc, DeployBeanDescriptor deploy) {
return new NoneDocStoreBeanAdapter<>(desc, deploy);
}
static class NoneIntegration implements DocStoreIntegration {
@Override
public DocStoreUpdateProcessor updateProcessor() {
return new NoneDocStoreUpdateProcessor();
}
@Override
public DocumentStore documentStore() {
return new NoneDocStore();
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy