//-----------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation.
//
//-----------------------------------------------------------------------
//
// Generated by params.pl
//
namespace Microsoft.Database.Isam
{
using System;
using Microsoft.Isam.Esent.Interop;
using Microsoft.Isam.Esent.Interop.Vista;
///
/// Properties for per-instance system parameters
///
public class IsamSystemParameters
{
///
/// The instance.
///
private readonly IsamInstance instance;
///
/// Initializes a new instance of the class.
///
/// The instance.
internal IsamSystemParameters(IsamInstance instance)
{
this.instance = instance;
}
///
/// Gets or sets system parameter which is a string.
///
public string SystemPath
{
get
{
int ignored = 0;
string val;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.SystemPath, ref ignored, out val, 1024);
return val;
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.SystemPath, 0, value);
}
}
///
/// Gets or sets system parameter which is a string.
///
public string TempPath
{
get
{
int ignored = 0;
string val;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.TempPath, ref ignored, out val, 1024);
return val;
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.TempPath, 0, value);
}
}
///
/// Gets or sets system parameter which is a string.
///
public string LogFilePath
{
get
{
int ignored = 0;
string val;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.LogFilePath, ref ignored, out val, 1024);
return val;
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.LogFilePath, 0, value);
}
}
///
/// Gets or sets system parameter which is a string.
///
public string BaseName
{
get
{
int ignored = 0;
string val;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.BaseName, ref ignored, out val, 1024);
return val;
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.BaseName, 0, value);
}
}
///
/// Gets or sets system parameter which is a string.
///
public string EventSource
{
get
{
int ignored = 0;
string val;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EventSource, ref ignored, out val, 1024);
return val;
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EventSource, 0, value);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int MaxSessions
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxSessions, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxSessions, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int MaxOpenTables
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxOpenTables, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxOpenTables, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int MaxCursors
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxCursors, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxCursors, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int MaxVerPages
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxVerPages, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxVerPages, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int MaxTemporaryTables
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxTemporaryTables, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxTemporaryTables, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int LogFileSize
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.LogFileSize, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.LogFileSize, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int LogBuffers
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.LogBuffers, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.LogBuffers, new IntPtr(value), null);
}
}
///
/// Gets or sets a value indicating whether the underlying system parameter is true.
///
public bool CircularLog
{
get
{
int val = 0;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CircularLog, ref val, out ignored, 0);
return 0 != val;
}
set
{
int val = value ? 1 : 0;
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CircularLog, val, null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int DbExtensionSize
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.DbExtensionSize, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.DbExtensionSize, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int PageTempDBMin
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.PageTempDBMin, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.PageTempDBMin, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int CacheSizeMax
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CacheSizeMax, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CacheSizeMax, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (long).
///
public long CheckpointDepthMax
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CheckpointDepthMax, ref val, out ignored, 0);
return unchecked((long)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CheckpointDepthMax, new IntPtr(value), null);
}
}
///
/// Gets a system parameter which is an integer type (int).
///
public int OutstandingIOMax
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.OutstandingIOMax, ref val, out ignored, 0);
return unchecked((int)val);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int StartFlushThreshold
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.StartFlushThreshold, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.StartFlushThreshold, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int StopFlushThreshold
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.StopFlushThreshold, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.StopFlushThreshold, new IntPtr(value), null);
}
}
///
/// Gets or sets system parameter which is a string.
///
public string Recovery
{
get
{
int ignored = 0;
string val;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.Recovery, ref ignored, out val, 1024);
return val;
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.Recovery, 0, value);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int EnableOnlineDefrag
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EnableOnlineDefrag, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EnableOnlineDefrag, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int CacheSize
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CacheSize, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CacheSize, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public bool EnableIndexChecking
{
get
{
int numericValue = 0;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EnableIndexChecking, ref numericValue, out ignored, 0);
return Convert.ToBoolean(numericValue);
}
set
{
// int numericValue = value ? 1 : 0;
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EnableIndexChecking, Convert.ToInt32(value), null);
}
}
///
/// Disables or enables all database engine callbacks to application provided functions.
///
public bool DisableCallbacks
{
get
{
int numericValue = 0;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.DisableCallbacks, ref numericValue, out ignored, 0);
return Convert.ToBoolean(numericValue);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.DisableCallbacks, Convert.ToInt32(value), null);
}
}
///
/// Gets or sets system parameter which is a string.
///
public string EventSourceKey
{
get
{
int ignored = 0;
string val;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EventSourceKey, ref ignored, out val, 1024);
return val;
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EventSourceKey, 0, value);
}
}
///
/// Gets or sets a value indicating whether the underlying system parameter is true.
///
public bool NoInformationEvent
{
get
{
int val = 0;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.NoInformationEvent, ref val, out ignored, 0);
return 0 != val;
}
set
{
int val = value ? 1 : 0;
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.NoInformationEvent, val, null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int EventLoggingLevel
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EventLoggingLevel, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EventLoggingLevel, new IntPtr(value), null);
}
}
///
/// Gets or sets a value indicating whether the underlying system parameter is true.
///
public bool DeleteOutOfRangeLogs
{
get
{
int val = 0;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.DeleteOutOfRangeLogs, ref val, out ignored, 0);
return 0 != val;
}
set
{
int val = value ? 1 : 0;
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.DeleteOutOfRangeLogs, val, null);
}
}
///
/// Gets or sets a value indicating whether the underlying system parameter is true.
///
public bool EnableIndexCleanup
{
get
{
int val = 0;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EnableIndexCleanup, ref val, out ignored, 0);
return 0 != val;
}
set
{
int val = value ? 1 : 0;
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.EnableIndexCleanup, val, null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int CacheSizeMin
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CacheSizeMin, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CacheSizeMin, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int PreferredVerPages
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.PreferredVerPages, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.PreferredVerPages, new IntPtr(value), null);
}
}
///
/// Gets a system parameter which is an integer type (int).
///
public int DatabasePageSize
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.DatabasePageSize, ref val, out ignored, 0);
return unchecked((int)val);
}
}
///
/// Gets or sets a value indicating whether the underlying system parameter is true.
///
public bool CleanupMismatchedLogFiles
{
get
{
int val = 0;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CleanupMismatchedLogFiles, ref val, out ignored, 0);
return 0 != val;
}
set
{
int val = value ? 1 : 0;
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CleanupMismatchedLogFiles, val, null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int ExceptionAction
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.ExceptionAction, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.ExceptionAction, new IntPtr(value), null);
}
}
///
/// Gets or sets a value indicating whether the underlying system parameter is true.
///
public bool CreatePathIfNotExist
{
get
{
int val = 0;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CreatePathIfNotExist, ref val, out ignored, 0);
return 0 != val;
}
set
{
int val = value ? 1 : 0;
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.CreatePathIfNotExist, val, null);
}
}
///
/// Gets or sets a value indicating whether the underlying system parameter is true.
///
public bool OneDatabasePerSession
{
get
{
int val = 0;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.OneDatabasePerSession, ref val, out ignored, 0);
return 0 != val;
}
set
{
int val = value ? 1 : 0;
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.OneDatabasePerSession, val, null);
}
}
///
/// Gets a system parameter which is an integer type (int).
///
public int MaxInstances
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.MaxInstances, ref val, out ignored, 0);
return unchecked((int)val);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int VersionStoreTaskQueueMax
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.VersionStoreTaskQueueMax, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, JET_param.VersionStoreTaskQueueMax, new IntPtr(value), null);
}
}
///
/// Gets or sets a system parameter which is an integer type (int).
///
public int Configuration
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, VistaParam.Configuration, ref val, out ignored, 0);
return unchecked((int)val);
}
set
{
Api.JetSetSystemParameter(this.instance.Inst, JET_SESID.Nil, VistaParam.Configuration, new IntPtr(value), null);
}
}
///
/// Gets a system parameter which is an integer type (long).
///
public long KeyMost
{
get
{
IntPtr val = IntPtr.Zero;
string ignored;
Api.JetGetSystemParameter(this.instance.Inst, JET_SESID.Nil, VistaParam.KeyMost, ref val, out ignored, 0);
return unchecked((long)val);
}
}
}
}