public class TemplateAvailabilityProviders extends Object
TemplateAvailabilityProvider
beans that can be used to check
which (if any) templating engine supports a given view. Caches responses unless the
spring.template.provider.cache
property is set to false
.Modifier | Constructor and Description |
---|---|
|
TemplateAvailabilityProviders(org.springframework.context.ApplicationContext applicationContext)
Create a new
TemplateAvailabilityProviders instance. |
|
TemplateAvailabilityProviders(ClassLoader classLoader)
Create a new
TemplateAvailabilityProviders instance. |
protected |
TemplateAvailabilityProviders(Collection<? extends TemplateAvailabilityProvider> providers)
Create a new
TemplateAvailabilityProviders instance. |
Modifier and Type | Method and Description |
---|---|
TemplateAvailabilityProvider |
getProvider(String view,
org.springframework.context.ApplicationContext applicationContext)
Get the provider that can be used to render the given view.
|
TemplateAvailabilityProvider |
getProvider(String view,
org.springframework.core.env.Environment environment,
ClassLoader classLoader,
org.springframework.core.io.ResourceLoader resourceLoader)
Get the provider that can be used to render the given view.
|
List<TemplateAvailabilityProvider> |
getProviders()
Return the underlying providers being used.
|
public TemplateAvailabilityProviders(org.springframework.context.ApplicationContext applicationContext)
TemplateAvailabilityProviders
instance.applicationContext
- the source application contextpublic TemplateAvailabilityProviders(ClassLoader classLoader)
TemplateAvailabilityProviders
instance.classLoader
- the source class loaderprotected TemplateAvailabilityProviders(Collection<? extends TemplateAvailabilityProvider> providers)
TemplateAvailabilityProviders
instance.providers
- the underlying providerspublic List<TemplateAvailabilityProvider> getProviders()
public TemplateAvailabilityProvider getProvider(String view, org.springframework.context.ApplicationContext applicationContext)
view
- the view to renderapplicationContext
- the application contextTemplateAvailabilityProvider
or nullpublic TemplateAvailabilityProvider getProvider(String view, org.springframework.core.env.Environment environment, ClassLoader classLoader, org.springframework.core.io.ResourceLoader resourceLoader)
view
- the view to renderenvironment
- the environmentclassLoader
- the class loaderresourceLoader
- the resource loaderTemplateAvailabilityProvider
or nullCopyright © 2017 Pivotal Software, Inc.. All rights reserved.