/** * Create new server scope provider with injected {@link Configuration configuration} and * {@link InjectionManager jersey injection manager}. */ @Inject public ServerScopeProvider(final Configuration config, final InjectionManager injectionManager) { super(config, injectionManager); this.uriToContexts = DataStructures.createConcurrentMap(); }
/** * Create a new input stream that is backed by a a queue of {@link java.nio.ByteBuffer byte buffers} * to be read. */ public ByteBufferInputStream() { this.buffers = DataStructures.createLinkedTransferQueue(); this.current = null; }
cacheEnabled = PropertiesHelper.getValue(properties, MvcFeature.CACHE_TEMPLATES, false, null); this.cache = cacheEnabled ? DataStructures.<String, T>createConcurrentMap() : null; this.encoding = TemplateHelper.getTemplateOutputEncoding(config, suffix);
/** * Create a new input stream that is backed by a a queue of {@link java.nio.ByteBuffer byte buffers} * to be read. */ public ByteBufferInputStream() { this.buffers = DataStructures.createLinkedTransferQueue(); this.current = null; }
/** * Create new server scope provider with injected {@link Configuration configuration} and * {@link ServiceLocator HK2 service locator}. */ @Inject public ServerScopeProvider(final Configuration config, final ServiceLocator serviceLocator) { super(config, serviceLocator); this.uriToContexts = DataStructures.createConcurrentMap(); }
/** * Create a new input stream that is backed by a a queue of {@link java.nio.ByteBuffer byte buffers} * to be read. */ public ByteBufferInputStream() { this.buffers = DataStructures.createLinkedTransferQueue(); this.current = null; }
/** * Create new server scope provider with injected {@link Configuration configuration} and * {@link InjectionManager jersey injection manager}. */ @Inject public ServerScopeProvider(final Configuration config, final InjectionManager injectionManager) { super(config, injectionManager); this.uriToContexts = DataStructures.createConcurrentMap(); }
/** * Create a new input stream that is backed by a a queue of {@link java.nio.ByteBuffer byte buffers} * to be read. */ public ByteBufferInputStream() { this.buffers = DataStructures.createLinkedTransferQueue(); this.current = null; }
/** * Create new server scope provider with injected {@link Configuration configuration} and * {@link ServiceLocator HK2 service locator}. */ @Inject public ServerScopeProvider(final Configuration config, final ServiceLocator serviceLocator) { super(config, serviceLocator); this.uriToContexts = DataStructures.createConcurrentMap(); }
/** * Create a new input stream that is backed by a a queue of {@link java.nio.ByteBuffer byte buffers} * to be read. */ public ByteBufferInputStream() { this.buffers = DataStructures.createLinkedTransferQueue(); this.current = null; }
/** * <p>Constructor for AbstractTemplateProcessor.</p> * * @param config a {@link javax.ws.rs.core.Configuration} object. * @param propertySuffix a {@link java.lang.String} object. * @param supportedExtensions a {@link java.lang.String} object. */ public AbstractTemplateProcessor(Configuration config, String propertySuffix, String... supportedExtensions) { this.config = config; this.suffix = '.' + propertySuffix; Map<String, Object> properties = config.getProperties(); String basePath = TemplateHelper.getBasePath(properties, propertySuffix); Collection<String> basePaths = TemplateHelper.getBasePaths(basePath); this.basePath = basePaths.toArray(new String[basePaths.size()]); Boolean cacheEnabled = PropertiesHelper.getValue(properties, MvcFeature.CACHE_TEMPLATES + this.suffix, Boolean.class, null); if (cacheEnabled == null) { cacheEnabled = PropertiesHelper.getValue(properties, MvcFeature.CACHE_TEMPLATES, false, null); } this.cache = cacheEnabled ? DataStructures.createConcurrentMap() : null; this.encoding = TemplateHelper.getTemplateOutputEncoding(config, this.suffix); this.supportedExtensions = Sets.newHashSet(Collections2.transform( Arrays.asList(supportedExtensions), input -> { input = input.toLowerCase(); return input.startsWith(".") ? input : "." + input; })); }
/** * Create a new input stream that is backed by a a queue of {@link java.nio.ByteBuffer byte buffers} * to be read. */ public ByteBufferInputStream() { this.buffers = DataStructures.createLinkedTransferQueue(); this.current = null; }
cacheEnabled = PropertiesHelper.getValue(properties, MvcFeature.CACHE_TEMPLATES, false, null); this.cache = cacheEnabled ? DataStructures.<String, T>createConcurrentMap() : null; this.encoding = TemplateHelper.getTemplateOutputEncoding(config, suffix);
/** * Create a new input stream that is backed by a a queue of {@link java.nio.ByteBuffer byte buffers} * to be read. */ public ByteBufferInputStream() { this.buffers = DataStructures.createLinkedTransferQueue(); this.current = null; }
cacheEnabled = PropertiesHelper.getValue(properties, MvcFeature.CACHE_TEMPLATES, false, null); this.cache = cacheEnabled ? DataStructures.<String, T>createConcurrentMap() : null; this.encoding = TemplateHelper.getTemplateOutputEncoding(config, suffix);
cacheEnabled = PropertiesHelper.getValue(properties, MvcFeature.CACHE_TEMPLATES, false, null); this.cache = cacheEnabled ? DataStructures.<String, T>createConcurrentMap() : null; this.encoding = TemplateHelper.getTemplateOutputEncoding(config, suffix);