Click or drag to resize

IceNetSdkGetInProcRepositoryFactory Method

Provides a factory class to create an in-memory repository.

Namespace:  PDTec.IceNet.Sdk
Assembly:  PDTec.IceNet.Sdk (in PDTec.IceNet.Sdk.dll) Version: 7.2.0.0 (7.2.7583.15464)
Syntax
C#
public static IInProcRepositoryFactory GetInProcRepositoryFactory()

Return Value

Type: IInProcRepositoryFactory
A factory class that creates the in-memory repository.
Remarks
The factory returned by this method does not include business object implementations for the Core.File object type in order to allow maximum flexibility. However, by using the GetInProcFileImplFactory method a predefined implementation can be used.
Examples

The example shows how to create a in-memory repository with file management support.

IInProcFileImplFactory pFileFactory = IceNetSdk.GetInProcFileImplFactory();

pFileFactory.EnforceFileExistence  = false;

pFileFactory.ResolveVaultDirectory += delegate(object sender, ResolveVaultDirectoryEventArgs e)
{
    e.Directory = @"D:\test\inprocvault";
};

IInProcRepositoryFactory pFactory = IceNetSdk.GetInProcRepositoryFactory();

pFactory.ImplFactories.Add(pFileFactory);

IRepository pRepository = pFactory.CreateRepository();
See Also