trunk/src/LythumOSL.Core/RegistryAccess.cs
/// <summary>
/// Return initialized key, in any system key case method return system (root level) key
/// except is current user or local machine key
/// </summary>
/// <param name="writeAccess"></param>
/// <returns></returns>
Return initialized key, in any system key case method return system (root level) key
except is current user or local machine key
Return initialized key in any system key case method return system ( root level ) key except is current user or local machine key
public RegistryKey GetKey(bool writable)
		{
			RegistryKey parentKey = GetSystemKey(_KeyType);
			switch (_KeyType)
			{
				default:
					return parentKey;
				case RegistrySettingsType.CurrentUser:
				case RegistrySettingsType.LocalMachine:
					string subName = BuildSubKeyName();
					RegistryKey retVal = parentKey.OpenSubKey(subName, writable);
					if (retVal == null)
					{
						retVal = parentKey.CreateSubKey(subName);
					}
					return retVal;
			}
		}
public RegistryKey GetKey ( bool writable ) { RegistryKey parentKey = GetSystemKey ( _KeyType ) ; switch ( _KeyType ) { default : return parentKey ; case RegistrySettingsType . CurrentUser : case RegistrySettingsType . LocalMachine : string subName = BuildSubKeyName ( ) ; RegistryKey retVal = parentKey . OpenSubKey ( subName , writable ) ; if ( retVal == null ) { retVal = parentKey . CreateSubKey ( subName ) ; } return retVal ; } }
Return initialized key, in any system key case method return system (root level) key
except is current user or local machine key
Return initialized key in any system key case method return system ( root level ) key except is current user or local machine key
// System
None
writable
bool
writeAccess
None