类的使用
org.springframework.http.CacheControl
使用CacheControl的程序包 程序包 说明 org.springframework.http Contains a basic abstraction over client/server-side HTTP.org.springframework.test.web.reactive.server Support for testing Spring WebFlux server endpoints viaWebTestClient.org.springframework.web.reactive.config Spring WebFlux configuration infrastructure.org.springframework.web.reactive.function.server Provides the types that make up Spring's functional web framework for Reactive environments.org.springframework.web.reactive.resource Support classes for serving static resources.org.springframework.web.servlet.config.annotation Annotation-based setup for Spring MVC.org.springframework.web.servlet.function Provides the types that make up Spring's functional web framework for Servlet environments.org.springframework.web.servlet.mvc Standard controller implementations for the Servlet MVC framework that comes with Spring.org.springframework.web.servlet.support Support classes for Spring's web MVC framework.org.springframework.http中CacheControl的使用
返回CacheControl的org.springframework.http中的方法 修饰符和类型 方法 说明 CacheControlCacheControl. cachePrivate()Add a "private" directive.CacheControlCacheControl. cachePublic()Add a "public" directive.static CacheControlCacheControl. empty()Return an empty directive.static CacheControlCacheControl. maxAge(long maxAge, TimeUnit unit)Add a "max-age=" directive.static CacheControlCacheControl. maxAge(Duration maxAge)Add a "max-age=" directive.CacheControlCacheControl. mustRevalidate()Add a "must-revalidate" directive.static CacheControlCacheControl. noCache()Add a "no-cache" directive.static CacheControlCacheControl. noStore()Add a "no-store" directive.CacheControlCacheControl. noTransform()Add a "no-transform" directive.CacheControlCacheControl. proxyRevalidate()Add a "proxy-revalidate" directive.CacheControlCacheControl. sMaxAge(long sMaxAge, TimeUnit unit)Add an "s-maxage" directive.CacheControlCacheControl. sMaxAge(Duration sMaxAge)Add an "s-maxage" directive.CacheControlCacheControl. staleIfError(long staleIfError, TimeUnit unit)Add a "stale-if-error" directive.CacheControlCacheControl. staleIfError(Duration staleIfError)Add a "stale-if-error" directive.CacheControlCacheControl. staleWhileRevalidate(long staleWhileRevalidate, TimeUnit unit)Add a "stale-while-revalidate" directive.CacheControlCacheControl. staleWhileRevalidate(Duration staleWhileRevalidate)Add a "stale-while-revalidate" directive.参数类型为CacheControl的org.springframework.http中的方法 修饰符和类型 方法 说明 BResponseEntity.HeadersBuilder. cacheControl(CacheControl cacheControl)Set the caching directives for the resource, as specified by the HTTP 1.1Cache-Controlheader.voidHttpHeaders. setCacheControl(CacheControl cacheControl)Set a configuredCacheControlinstance as the new value of theCache-Controlheader.org.springframework.test.web.reactive.server中CacheControl的使用
参数类型为CacheControl的org.springframework.test.web.reactive.server中的方法 修饰符和类型 方法 说明 WebTestClient.ResponseSpecHeaderAssertions. cacheControl(CacheControl cacheControl)Expect a "Cache-Control" header with the given value.org.springframework.web.reactive.config中CacheControl的使用
参数类型为CacheControl的org.springframework.web.reactive.config中的方法 修饰符和类型 方法 说明 ResourceHandlerRegistrationResourceHandlerRegistration. setCacheControl(CacheControl cacheControl)Specify theCacheControlwhich should be used by the resource handler.org.springframework.web.reactive.function.server中CacheControl的使用
参数类型为CacheControl的org.springframework.web.reactive.function.server中的方法 修饰符和类型 方法 说明 EntityResponse.Builder<T>EntityResponse.Builder. cacheControl(CacheControl cacheControl)Set the caching directives for the resource, as specified by the HTTP 1.1Cache-Controlheader.BServerResponse.HeadersBuilder. cacheControl(CacheControl cacheControl)Set the caching directives for the resource, as specified by the HTTP 1.1Cache-Controlheader.org.springframework.web.reactive.resource中CacheControl的使用
返回CacheControl的org.springframework.web.reactive.resource中的方法 修饰符和类型 方法 说明 CacheControlResourceWebHandler. getCacheControl()Return theCacheControlinstance to build the Cache-Control HTTP response header.参数类型为CacheControl的org.springframework.web.reactive.resource中的方法 修饰符和类型 方法 说明 voidResourceWebHandler. setCacheControl(CacheControl cacheControl)Set theCacheControlinstance to build the Cache-Control HTTP response header.org.springframework.web.servlet.config.annotation中CacheControl的使用
参数类型为CacheControl的org.springframework.web.servlet.config.annotation中的方法 修饰符和类型 方法 说明 ResourceHandlerRegistrationResourceHandlerRegistration. setCacheControl(CacheControl cacheControl)Specify theCacheControlwhich should be used by the resource handler.org.springframework.web.servlet.function中CacheControl的使用
参数类型为CacheControl的org.springframework.web.servlet.function中的方法 修饰符和类型 方法 说明 EntityResponse.Builder<T>EntityResponse.Builder. cacheControl(CacheControl cacheControl)Set the caching directives for the resource, as specified by the HTTP 1.1Cache-Controlheader.BServerResponse.HeadersBuilder. cacheControl(CacheControl cacheControl)Set the caching directives for the resource, as specified by the HTTP 1.1Cache-Controlheader.org.springframework.web.servlet.mvc中CacheControl的使用
返回CacheControl的org.springframework.web.servlet.mvc中的方法 修饰符和类型 方法 说明 protected CacheControlWebContentInterceptor. lookupCacheControl(String urlPath)Look up aCacheControlinstance for the given URL path.