scripts
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
using System;
|
||||
|
||||
namespace System.Net.Cache
|
||||
{
|
||||
/// <summary>Specifies the meaning of time values that control caching behavior for resources obtained using <see cref="T:System.Net.HttpWebRequest" /> objects.</summary>
|
||||
// Token: 0x02000130 RID: 304
|
||||
public enum HttpCacheAgeControl
|
||||
{
|
||||
/// <summary>For internal use only. The Framework will throw an <see cref="T:System.ArgumentException" /> if you try to use this member.</summary>
|
||||
// Token: 0x04000AD9 RID: 2777
|
||||
None,
|
||||
/// <summary>Content can be taken from the cache if the time remaining before expiration is greater than or equal to the time specified with this value.</summary>
|
||||
// Token: 0x04000ADA RID: 2778
|
||||
MinFresh,
|
||||
/// <summary>Content can be taken from the cache until it is older than the age specified with this value.</summary>
|
||||
// Token: 0x04000ADB RID: 2779
|
||||
MaxAge,
|
||||
/// <summary>
|
||||
/// <see cref="P:System.Net.Cache.HttpRequestCachePolicy.MaxAge" /> and <see cref="P:System.Net.Cache.HttpRequestCachePolicy.MinFresh" />.</summary>
|
||||
// Token: 0x04000ADC RID: 2780
|
||||
MaxAgeAndMinFresh,
|
||||
/// <summary>Content can be taken from the cache after it has expired, until the time specified with this value elapses.</summary>
|
||||
// Token: 0x04000ADD RID: 2781
|
||||
MaxStale,
|
||||
/// <summary>
|
||||
/// <see cref="P:System.Net.Cache.HttpRequestCachePolicy.MaxAge" /> and <see cref="P:System.Net.Cache.HttpRequestCachePolicy.MaxStale" />.</summary>
|
||||
// Token: 0x04000ADE RID: 2782
|
||||
MaxAgeAndMaxStale = 6
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
using System;
|
||||
|
||||
namespace System.Net.Cache
|
||||
{
|
||||
/// <summary>Specifies caching behavior for resources obtained using the Hypertext Transfer protocol (HTTP).</summary>
|
||||
// Token: 0x02000131 RID: 305
|
||||
public enum HttpRequestCacheLevel
|
||||
{
|
||||
/// <summary>Satisfies a request for a resource either by using the cached copy of the resource or by sending a request for the resource to the server. The action taken is determined by the current cache policy and the age of the content in the cache. This is the cache level that should be used by most applications.</summary>
|
||||
// Token: 0x04000AE0 RID: 2784
|
||||
Default,
|
||||
/// <summary>Satisfies a request by using the server. No entries are taken from caches, added to caches, or removed from caches between the client and server. This is the default cache behavior specified in the machine configuration file that ships with the .NET Framework.</summary>
|
||||
// Token: 0x04000AE1 RID: 2785
|
||||
BypassCache,
|
||||
/// <summary>Satisfies a request using the locally cached resource; does not send a request for an item that is not in the cache. When this cache policy level is specified, a <see cref="T:System.Net.WebException" /> exception is thrown if the item is not in the client cache.</summary>
|
||||
// Token: 0x04000AE2 RID: 2786
|
||||
CacheOnly,
|
||||
/// <summary>Satisfies a request for a resource from the cache if the resource is available; otherwise, sends a request for a resource to the server. If the requested item is available in any cache between the client and the server, the request might be satisfied by the intermediate cache.</summary>
|
||||
// Token: 0x04000AE3 RID: 2787
|
||||
CacheIfAvailable,
|
||||
/// <summary>Compares the copy of the resource in the cache with the copy on the server. If the copy on the server is newer, it is used to satisfy the request and replaces the copy in the cache. If the copy in the cache is the same as the server copy, the cached copy is used. In the HTTP caching protocol, this is achieved using a conditional request.</summary>
|
||||
// Token: 0x04000AE4 RID: 2788
|
||||
Revalidate,
|
||||
/// <summary>Satisfies a request by using the server. The response might be saved in the cache. In the HTTP caching protocol, this is achieved using the no-cache cache control directive and the no-cache Pragma header.</summary>
|
||||
// Token: 0x04000AE5 RID: 2789
|
||||
Reload,
|
||||
/// <summary>Never satisfies a request by using resources from the cache and does not cache resources. If the resource is present in the local cache, it is removed. This policy level indicates to intermediate caches that they should remove the resource. In the HTTP caching protocol, this is achieved using the no-cache cache control directive.</summary>
|
||||
// Token: 0x04000AE6 RID: 2790
|
||||
NoCacheNoStore,
|
||||
/// <summary>Satisfies a request for a resource either from the local computer's cache or a remote cache on the local area network. If the request cannot be satisfied, a <see cref="T:System.Net.WebException" /> exception is thrown. In the HTTP caching protocol, this is achieved using the only-if-cached cache control directive.</summary>
|
||||
// Token: 0x04000AE7 RID: 2791
|
||||
CacheOrNextCacheOnly,
|
||||
/// <summary>Satisfies a request by using the server or a cache other than the local cache. Before the request can be satisfied by an intermediate cache, that cache must revalidate its cached entry with the server. In the HTTP caching protocol, this is achieved using the max-age = 0 cache control directive and the no-cache Pragma header.</summary>
|
||||
// Token: 0x04000AE8 RID: 2792
|
||||
Refresh
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,170 @@
|
||||
using System;
|
||||
|
||||
namespace System.Net.Cache
|
||||
{
|
||||
/// <summary>Defines an application's caching requirements for resources obtained by using <see cref="T:System.Net.HttpWebRequest" /> objects.</summary>
|
||||
// Token: 0x02000132 RID: 306
|
||||
public class HttpRequestCachePolicy : RequestCachePolicy
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Net.Cache.HttpRequestCachePolicy" /> class. </summary>
|
||||
// Token: 0x06000A72 RID: 2674 RVA: 0x0001D918 File Offset: 0x0001BB18
|
||||
public HttpRequestCachePolicy()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Net.Cache.HttpRequestCachePolicy" /> class using the specified cache synchronization date.</summary>
|
||||
/// <param name="cacheSyncDate">A <see cref="T:System.DateTime" /> object that specifies the time when resources stored in the cache must be revalidated.</param>
|
||||
// Token: 0x06000A73 RID: 2675 RVA: 0x0001D920 File Offset: 0x0001BB20
|
||||
public HttpRequestCachePolicy(DateTime cacheSyncDate)
|
||||
{
|
||||
this.cacheSyncDate = cacheSyncDate;
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Net.Cache.HttpRequestCachePolicy" /> class using the specified cache policy.</summary>
|
||||
/// <param name="level">An <see cref="T:System.Net.Cache.HttpRequestCacheLevel" /> value. </param>
|
||||
// Token: 0x06000A74 RID: 2676 RVA: 0x0001D930 File Offset: 0x0001BB30
|
||||
public HttpRequestCachePolicy(HttpRequestCacheLevel level)
|
||||
{
|
||||
this.level = level;
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Net.Cache.HttpRequestCachePolicy" /> class using the specified age control and time values. </summary>
|
||||
/// <param name="cacheAgeControl">One of the following <see cref="T:System.Net.Cache.HttpCacheAgeControl" /> enumeration values: <see cref="F:System.Net.Cache.HttpCacheAgeControl.MaxAge" />, <see cref="F:System.Net.Cache.HttpCacheAgeControl.MaxStale" />, or <see cref="F:System.Net.Cache.HttpCacheAgeControl.MinFresh" />.</param>
|
||||
/// <param name="ageOrFreshOrStale">A <see cref="T:System.TimeSpan" /> value that specifies an amount of time. See the Remarks section for more information. </param>
|
||||
/// <exception cref="T:System.ArgumentException">The value specified for the <paramref name="cacheAgeControl" /> parameter cannot be used with this constructor.</exception>
|
||||
// Token: 0x06000A75 RID: 2677 RVA: 0x0001D940 File Offset: 0x0001BB40
|
||||
public HttpRequestCachePolicy(HttpCacheAgeControl cacheAgeControl, TimeSpan ageOrFreshOrStale)
|
||||
{
|
||||
switch (cacheAgeControl)
|
||||
{
|
||||
case HttpCacheAgeControl.MinFresh:
|
||||
this.minFresh = ageOrFreshOrStale;
|
||||
return;
|
||||
case HttpCacheAgeControl.MaxAge:
|
||||
this.maxAge = ageOrFreshOrStale;
|
||||
return;
|
||||
case HttpCacheAgeControl.MaxStale:
|
||||
this.maxStale = ageOrFreshOrStale;
|
||||
return;
|
||||
}
|
||||
throw new ArgumentException("ageOrFreshOrStale");
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Net.Cache.HttpRequestCachePolicy" /> class using the specified maximum age, age control value, and time value.</summary>
|
||||
/// <param name="cacheAgeControl">An <see cref="T:System.Net.Cache.HttpCacheAgeControl" /> value. </param>
|
||||
/// <param name="maxAge">A <see cref="T:System.TimeSpan" /> value that specifies the maximum age for resources.</param>
|
||||
/// <param name="freshOrStale">A <see cref="T:System.TimeSpan" /> value that specifies an amount of time. See the Remarks section for more information. </param>
|
||||
/// <exception cref="T:System.ArgumentException">The value specified for the <paramref name="cacheAgeControl" /> parameter is not valid.</exception>
|
||||
// Token: 0x06000A76 RID: 2678 RVA: 0x0001D9A4 File Offset: 0x0001BBA4
|
||||
public HttpRequestCachePolicy(HttpCacheAgeControl cacheAgeControl, TimeSpan maxAge, TimeSpan freshOrStale)
|
||||
{
|
||||
this.maxAge = maxAge;
|
||||
switch (cacheAgeControl)
|
||||
{
|
||||
case HttpCacheAgeControl.MinFresh:
|
||||
this.minFresh = freshOrStale;
|
||||
return;
|
||||
case HttpCacheAgeControl.MaxStale:
|
||||
this.maxStale = freshOrStale;
|
||||
return;
|
||||
}
|
||||
throw new ArgumentException("freshOrStale");
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Net.Cache.HttpRequestCachePolicy" /> class using the specified maximum age, age control value, time value, and cache synchronization date.</summary>
|
||||
/// <param name="cacheAgeControl">An <see cref="T:System.Net.Cache.HttpCacheAgeControl" /> value. </param>
|
||||
/// <param name="maxAge">A <see cref="T:System.TimeSpan" /> value that specifies the maximum age for resources.</param>
|
||||
/// <param name="freshOrStale">A <see cref="T:System.TimeSpan" /> value that specifies an amount of time. See the Remarks section for more information. </param>
|
||||
/// <param name="cacheSyncDate">A <see cref="T:System.DateTime" /> object that specifies the time when resources stored in the cache must be revalidated.</param>
|
||||
// Token: 0x06000A77 RID: 2679 RVA: 0x0001DA00 File Offset: 0x0001BC00
|
||||
public HttpRequestCachePolicy(HttpCacheAgeControl cacheAgeControl, TimeSpan maxAge, TimeSpan freshOrStale, DateTime cacheSyncDate)
|
||||
: this(cacheAgeControl, maxAge, freshOrStale)
|
||||
{
|
||||
this.cacheSyncDate = cacheSyncDate;
|
||||
}
|
||||
|
||||
/// <summary>Gets the cache synchronization date for this instance.</summary>
|
||||
/// <returns>A <see cref="T:System.DateTime" /> value set to the date specified when this instance was created. If no date was specified, this property's value is <see cref="F:System.DateTime.MinValue" />.</returns>
|
||||
// Token: 0x170002A5 RID: 677
|
||||
// (get) Token: 0x06000A78 RID: 2680 RVA: 0x0001DA14 File Offset: 0x0001BC14
|
||||
public DateTime CacheSyncDate
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.cacheSyncDate;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Net.Cache.HttpRequestCacheLevel" /> value that was specified when this instance was created.</summary>
|
||||
/// <returns>A <see cref="T:System.Net.Cache.HttpRequestCacheLevel" /> value that specifies the cache behavior for resources that were obtained using <see cref="T:System.Net.HttpWebRequest" /> objects.</returns>
|
||||
// Token: 0x170002A6 RID: 678
|
||||
// (get) Token: 0x06000A79 RID: 2681 RVA: 0x0001DA1C File Offset: 0x0001BC1C
|
||||
public new HttpRequestCacheLevel Level
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.level;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the maximum age permitted for a resource returned from the cache.</summary>
|
||||
/// <returns>A <see cref="T:System.TimeSpan" /> value that is set to the maximum age value specified when this instance was created. If no date was specified, this property's value is <see cref="F:System.DateTime.MinValue" />.</returns>
|
||||
// Token: 0x170002A7 RID: 679
|
||||
// (get) Token: 0x06000A7A RID: 2682 RVA: 0x0001DA24 File Offset: 0x0001BC24
|
||||
public TimeSpan MaxAge
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.maxAge;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the maximum staleness value that is permitted for a resource returned from the cache.</summary>
|
||||
/// <returns>A <see cref="T:System.TimeSpan" /> value that is set to the maximum staleness value specified when this instance was created. If no date was specified, this property's value is <see cref="F:System.DateTime.MinValue" />.</returns>
|
||||
// Token: 0x170002A8 RID: 680
|
||||
// (get) Token: 0x06000A7B RID: 2683 RVA: 0x0001DA2C File Offset: 0x0001BC2C
|
||||
public TimeSpan MaxStale
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.maxStale;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the minimum freshness that is permitted for a resource returned from the cache.</summary>
|
||||
/// <returns>A <see cref="T:System.TimeSpan" /> value that specifies the minimum freshness specified when this instance was created. If no date was specified, this property's value is <see cref="F:System.DateTime.MinValue" />.</returns>
|
||||
// Token: 0x170002A9 RID: 681
|
||||
// (get) Token: 0x06000A7C RID: 2684 RVA: 0x0001DA34 File Offset: 0x0001BC34
|
||||
public TimeSpan MinFresh
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.minFresh;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Returns a string representation of this instance.</summary>
|
||||
/// <returns>A <see cref="T:System.String" /> value that contains the property values for this instance.</returns>
|
||||
// Token: 0x06000A7D RID: 2685 RVA: 0x0001DA3C File Offset: 0x0001BC3C
|
||||
[global::System.MonoTODO]
|
||||
public override string ToString()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
// Token: 0x04000AE9 RID: 2793
|
||||
private DateTime cacheSyncDate;
|
||||
|
||||
// Token: 0x04000AEA RID: 2794
|
||||
private HttpRequestCacheLevel level;
|
||||
|
||||
// Token: 0x04000AEB RID: 2795
|
||||
private TimeSpan maxAge;
|
||||
|
||||
// Token: 0x04000AEC RID: 2796
|
||||
private TimeSpan maxStale;
|
||||
|
||||
// Token: 0x04000AED RID: 2797
|
||||
private TimeSpan minFresh;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
|
||||
namespace System.Net.Cache
|
||||
{
|
||||
/// <summary>Specifies caching behavior for resources obtained using <see cref="T:System.Net.WebRequest" /> and its derived classes.</summary>
|
||||
// Token: 0x02000133 RID: 307
|
||||
public enum RequestCacheLevel
|
||||
{
|
||||
/// <summary>Satisfies a request for a resource either by using the cached copy of the resource or by sending a request for the resource to the server. The action taken is determined by the current cache policy and the age of the content in the cache. This is the cache level that should be used by most applications.</summary>
|
||||
// Token: 0x04000AEF RID: 2799
|
||||
Default,
|
||||
/// <summary>Satisfies a request by using the server. No entries are taken from caches, added to caches, or removed from caches between the client and server. This is the default cache behavior specified in the machine configuration file that ships with the .NET Framework.</summary>
|
||||
// Token: 0x04000AF0 RID: 2800
|
||||
BypassCache,
|
||||
/// <summary>Satisfies a request using the locally cached resource; does not send a request for an item that is not in the cache. When this cache policy level is specified, a <see cref="T:System.Net.WebException" /> exception is thrown if the item is not in the client cache.</summary>
|
||||
// Token: 0x04000AF1 RID: 2801
|
||||
CacheOnly,
|
||||
/// <summary>Satisfies a request for a resource from the cache, if the resource is available; otherwise, sends a request for a resource to the server. If the requested item is available in any cache between the client and the server, the request might be satisfied by the intermediate cache.</summary>
|
||||
// Token: 0x04000AF2 RID: 2802
|
||||
CacheIfAvailable,
|
||||
/// <summary>Satisfies a request by using the cached copy of the resource if the timestamp is the same as the timestamp of the resource on the server; otherwise, the resource is downloaded from the server, presented to the caller, and stored in the cache.</summary>
|
||||
// Token: 0x04000AF3 RID: 2803
|
||||
Revalidate,
|
||||
/// <summary>Satisfies a request by using the server. The response might be saved in the cache. In the HTTP caching protocol, this is achieved using the no-cache cache control directive and the no-cache Pragma header.</summary>
|
||||
// Token: 0x04000AF4 RID: 2804
|
||||
Reload,
|
||||
/// <summary>Never satisfies a request by using resources from the cache and does not cache resources. If the resource is present in the local cache, it is removed. This policy level indicates to intermediate caches that they should remove the resource. In the HTTP caching protocol, this is achieved using the no-cache cache control directive.</summary>
|
||||
// Token: 0x04000AF5 RID: 2805
|
||||
NoCacheNoStore
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,48 @@
|
||||
using System;
|
||||
|
||||
namespace System.Net.Cache
|
||||
{
|
||||
/// <summary>Defines an application's caching requirements for resources obtained by using <see cref="T:System.Net.WebRequest" /> objects.</summary>
|
||||
// Token: 0x02000134 RID: 308
|
||||
public class RequestCachePolicy
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Net.Cache.RequestCachePolicy" /> class. </summary>
|
||||
// Token: 0x06000A7E RID: 2686 RVA: 0x0001DA44 File Offset: 0x0001BC44
|
||||
public RequestCachePolicy()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Net.Cache.RequestCachePolicy" /> class. using the specified cache policy.</summary>
|
||||
/// <param name="level">A <see cref="T:System.Net.Cache.RequestCacheLevel" /> that specifies the cache behavior for resources obtained using <see cref="T:System.Net.WebRequest" /> objects. </param>
|
||||
/// <exception cref="T:System.ArgumentOutOfRangeException">level is not a valid <see cref="T:System.Net.Cache.RequestCacheLevel" />.value.</exception>
|
||||
// Token: 0x06000A7F RID: 2687 RVA: 0x0001DA4C File Offset: 0x0001BC4C
|
||||
public RequestCachePolicy(RequestCacheLevel level)
|
||||
{
|
||||
this.level = level;
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Net.Cache.RequestCacheLevel" /> value specified when this instance was constructed.</summary>
|
||||
/// <returns>A <see cref="T:System.Net.Cache.RequestCacheLevel" /> value that specifies the cache behavior for resources obtained using <see cref="T:System.Net.WebRequest" /> objects.</returns>
|
||||
// Token: 0x170002AA RID: 682
|
||||
// (get) Token: 0x06000A80 RID: 2688 RVA: 0x0001DA5C File Offset: 0x0001BC5C
|
||||
public RequestCacheLevel Level
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.level;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Returns a string representation of this instance.</summary>
|
||||
/// <returns>A <see cref="T:System.String" /> containing the <see cref="P:System.Net.Cache.RequestCachePolicy.Level" /> for this instance.</returns>
|
||||
// Token: 0x06000A81 RID: 2689 RVA: 0x0001DA64 File Offset: 0x0001BC64
|
||||
[global::System.MonoTODO]
|
||||
public override string ToString()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
// Token: 0x04000AF6 RID: 2806
|
||||
private RequestCacheLevel level;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user