CacheControlHeaderValue.MaxAge Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
The maximum age, specified in seconds, that the HTTP client is willing to accept a response.
public:
property Nullable<TimeSpan> MaxAge { Nullable<TimeSpan> get(); void set(Nullable<TimeSpan> value); };
public TimeSpan? MaxAge { get; set; }
member this.MaxAge : Nullable<TimeSpan> with get, set
Public Property MaxAge As Nullable(Of TimeSpan)
Property Value
The time in seconds.
Remarks
This property represents the "max-age" directive in a cache-control header field on an HTTP request or HTTP response.
Unless the MaxStale property is also set, the client is not willing to accept a stale response.
Applies to
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide.