private void customizeResourceHandlerRegistration( ResourceHandlerRegistration registration) { if (this.resourceHandlerRegistrationCustomizer != null) { this.resourceHandlerRegistrationCustomizer.customize(registration); } }
private void registerResourceChain(ResourceHandlerRegistration registration) { ResourceProperties.Chain properties = this.resourceProperties.getChain(); if (properties.getEnabled()) { configureResourceChain(properties, registration.resourceChain(properties.isCache())); } }
@Override public void addResourceHandlers(ResourceHandlerRegistry registry) { ResourceHandlerRegistration staticResources = registry.addResourceHandler("/**"); staticResources.addResourceLocations("classpath:/public/"); }
@Override public void customize(ResourceHandlerRegistration registration) { ResourceProperties.Chain properties = this.resourceProperties.getChain(); configureResourceChain(properties, registration.resourceChain(properties.isCache())); }
@Override public void addResourceHandlers(ResourceHandlerRegistry registry) { ResourceHandlerRegistration resourceHandlerRegistration = registry.addResourceHandler("/resources"); resourceHandlerRegistration.addResourceLocations("/WEB-INF/resources"); resourceHandlerRegistration.setCachePeriod(0); }
void customize(ResourceHandlerRegistration registration);