OutputCache.Serialize Method (Stream, Object)
.NET Framework (current version)
Serializes output-cache data into binary data.
Assembly: System.Web (in System.Web.dll)
[SecurityPermissionAttribute(SecurityAction.Assert, Flags = SecurityPermissionFlag.SerializationFormatter)] public static void Serialize( Stream stream, object data )
Parameters
- stream
-
Type:
System.IO.Stream
The object to contain the serialized binary data.
- data
-
Type:
System.Object
The output-cache data to serialize.
| Exception | Condition |
|---|---|
| ArgumentException | data is not one of the specified output-cache types. |
| ArgumentNullException | data is null or stream is null. |
This method is used by output-cache providers that are operating under partial trust.
.NET Framework
Available since 4.0
Available since 4.0
Show: