DevForce Help Reference
RestoreCacheState(String,RestoreStrategy,Boolean) Method


Name of file to read.
The restore strategy to use.
True to restore a file in binary format; false if using text format.
Restores entities from a file system file into this EntityManager using the RestoreStrategy specified.
Syntax
'Declaration
 
Public Overloads Sub RestoreCacheState( _
   ByVal fileName As String, _
   ByVal strategy As RestoreStrategy, _
   Optional ByVal useBinaryFormat As Boolean _
) 
'Usage
 
Dim instance As CacheStateManager
Dim fileName As String
Dim strategy As RestoreStrategy
Dim useBinaryFormat As Boolean
 
instance.RestoreCacheState(fileName, strategy, useBinaryFormat)
public void RestoreCacheState( 
   string fileName,
   RestoreStrategy strategy,
   bool useBinaryFormat
)

Parameters

fileName
Name of file to read.
strategy
The restore strategy to use.
useBinaryFormat
True to restore a file in binary format; false if using 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.
Remarks
This loads an EntityCacheState from the file and then performs an Merge into this EntityManager.
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
EntityCacheState Class
SaveCacheState(String,Boolean) Method

Send Feedback