use of org.apache.cxf.jaxrs.lifecycle.SingletonResourceProvider in project tika by apache.
the class StackTraceOffTest method setUpResources.
@Override
protected void setUpResources(JAXRSServerFactoryBean sf) {
List<ResourceProvider> rCoreProviders = new ArrayList<ResourceProvider>();
rCoreProviders.add(new SingletonResourceProvider(new MetadataResource()));
rCoreProviders.add(new SingletonResourceProvider(new RecursiveMetadataResource()));
rCoreProviders.add(new SingletonResourceProvider(new DetectorResource()));
rCoreProviders.add(new SingletonResourceProvider(new TikaResource()));
rCoreProviders.add(new SingletonResourceProvider(new UnpackerResource()));
sf.setResourceProviders(rCoreProviders);
}
use of org.apache.cxf.jaxrs.lifecycle.SingletonResourceProvider in project tika by apache.
the class TikaParsersTest method setUpResources.
@Override
protected void setUpResources(JAXRSServerFactoryBean sf) {
sf.setResourceClasses(TikaParsers.class);
sf.setResourceProvider(TikaParsers.class, new SingletonResourceProvider(new TikaParsers()));
}
use of org.apache.cxf.jaxrs.lifecycle.SingletonResourceProvider in project tika by apache.
the class UnpackerResourceTest method setUpResources.
@Override
protected void setUpResources(JAXRSServerFactoryBean sf) {
sf.setResourceClasses(UnpackerResource.class);
sf.setResourceProvider(UnpackerResource.class, new SingletonResourceProvider(new UnpackerResource()));
}
use of org.apache.cxf.jaxrs.lifecycle.SingletonResourceProvider in project tika by apache.
the class TikaWelcomeTest method setUpResources.
@Override
protected void setUpResources(JAXRSServerFactoryBean sf) {
List<ResourceProvider> rpsCore = new ArrayList<ResourceProvider>();
rpsCore.add(new SingletonResourceProvider(new TikaVersion()));
rpsCore.add(new SingletonResourceProvider(new DetectorResource()));
rpsCore.add(new SingletonResourceProvider(new MetadataResource()));
List<ResourceProvider> all = new ArrayList<ResourceProvider>(rpsCore);
all.add(new SingletonResourceProvider(new TikaWelcome(rpsCore)));
sf.setResourceProviders(all);
}
use of org.apache.cxf.jaxrs.lifecycle.SingletonResourceProvider in project tika by apache.
the class TranslateResourceTest method setUpResources.
@Override
protected void setUpResources(JAXRSServerFactoryBean sf) {
sf.setResourceClasses(TranslateResource.class);
sf.setResourceProvider(TranslateResource.class, new SingletonResourceProvider(new TranslateResource()));
}
Aggregations