DevForce Help Reference
SaveCacheState(IEnumerable,String,Boolean) Method


List of entities
Name of file to use. Will be overwritten if it exists.
True to save the file in binary format; false to use text format.
Stores the state of this EntityManager and the specified entities to a file system file.
Syntax
'Declaration
 
Public Overloads Sub SaveCacheState( _
   ByVal entities As IEnumerable, _
   ByVal fileName As String, _
   Optional ByVal useBinaryFormat As Boolean _
) 
'Usage
 
Dim instance As CacheStateManager
Dim entities As IEnumerable
Dim fileName As String
Dim useBinaryFormat As Boolean
 
instance.SaveCacheState(entities, fileName, useBinaryFormat)
public void SaveCacheState( 
   IEnumerable entities,
   string fileName,
   bool useBinaryFormat
)

Parameters

entities
List of entities
fileName
Name of file to use. Will be overwritten if it exists.
useBinaryFormat
True to save the file in binary format; false to use text format.
Exceptions
ExceptionDescription
System.UnauthorizedAccessExceptionThe exception that is thrown when the operating system denies access because of an I/O error or a specific type of security error.
System.Security.SecurityExceptionThe exception that is thrown when a security error is detected.
System.IO.IOExceptionThe exception that is thrown when an I/O error occurs.
System.UnauthorizedAccessExceptionThe exception that is thrown when the operating system denies access because of an I/O error or a specific type of security error.
System.Security.SecurityExceptionThe exception that is thrown when a security error is detected.
System.IO.IOExceptionThe exception that is thrown when an I/O error occurs.
Remarks
The specified entities and the current state of the EntityManager will be saved to the specified file in either binary or text format. The user must have write permissions to the folder, and if the file exists it will be overwritten.
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

CacheStateManager Class
CacheStateManager Members
Overload List

Send Feedback