Class: Registry

Source Location: /libraries/vwp/sys/registry.php

Class Overview [line 81]

VType
   |
   --VObject
      |
      --Registry

VWP Registry Library

Author(s):

Version:

Copyright:

  • (c) Ralph Ritoch - All Rights Reserved

Variables

Constants

Methods


Inherited Variables

Inherited Constants

Inherited Methods

Class: VObject

VObject::__construct()
Class Constructor
VObject::bind()
Bind values to this object
VObject::delete()
Delete Object
VObject::get()
Get value
VObject::getAll()
Get all object values
VObject::getError()
Get error message
VObject::getErrors()
Get errors
VObject::getMethods()
Get object methods
VObject::getProperties()
Get object properties
VObject::save()
Save Object
VObject::set()
Set a value
VObject::setError()
Set error value
VObject::setProperties()
Set property values
VObject::setProperty()
Set property value
VObject::toString()
Convert object to string
VObject::__destruct()
Class Destructor
VObject::__get()
VObject::__isset()
VObject::__set()
VObject::__toString()
Return object as a string
VObject::__unset()


Class Details

VWP Registry Library

This is Registry API Interface class.

Tags:

[ Top ]


Class Variables


Class Methods

static ClassesRoot

static object HKEY_CLASSES_ROOT &ClassesRoot( )

[line 91]

Get instance of HKEY_CLASSES_ROOT Registry Key

Tags:

  • return - Registry Key
  • access - public

Parameters:

[ Top ]

static init_defines

static void init_defines( )

[line 912]

Initialize registry defines

Initializes defines such as Value data types note: This function should be called before any registry keys are accessed

Tags:

  • access - public

Parameters:

[ Top ]

static LocalMachine

static object HKEY_LOCAL_MACHINE &LocalMachine( )

[line 124]

Get instance of HKEY_LOCAL_MACHINE Registry Key

Tags:

  • return - Registry Key
  • access - public

Parameters:

[ Top ]

static RegCloseKey

static integer RegCloseKey( $hkey, object $hKey)

[line 154]

Closes a handle to the specified registry key.

Tags:

  • return - Returns error code or ERROR_SUCCESS if successful
  • access - public

Parameters:

  • object $hKey - A handle to the open key to be closed.
  • $hkey -

[ Top ]

static RegCreateKeyEx

static integer RegCreateKeyEx( object $hKey, string $lpSubKey, integer $Reserved, string $lpClass, integer $dwOptions, mixed $samDesired, mixed $lpSecurityAttributes, &$phkResult, &$lpdwDisposition, object $phkResult, integer $lpdwDisposition)

[line 232]

Creates the specified registry key.

If the key already exists, the function opens it. Note that key names are not case sensitive.

Possible Values for $dwOptions

REG_OPTION_BACKUP_RESTORE 0x00000004L

If this flag is set, the function ignores the samDesired parameter and attempts to open the key with the access required to backup or restore the key. If the calling thread has the SE_BACKUP_NAME privilege enabled, the key is opened with the ACCESS_SYSTEM_SECURITY and KEY_READ access rights. If the calling thread has the SE_RESTORE_NAME privilege enabled, the key is opened with the ACCESS_SYSTEM_SECURITY and KEY_WRITE access rights. If both privileges are enabled, the key has the combined access rights for both privileges. For more information, see Running with Special Privileges.

REG_OPTION_CREATE_LINK 0x00000002L

This key is a symbolic link. The target path is assigned to the L"SymbolicLinkValue" value of the key. The target path must be an absolute registry path.

Registry symbolic links should be used only when absolutely necessary for application compatibility.

REG_OPTION_NON_VOLATILE 0x00000000L

This key is not volatile; this is the default. The information is stored in a file and is preserved when the system is restarted. The RegSaveKey function saves keys that are not volatile.

REG_OPTION_VOLATILE 0x00000001L

All keys created by the function are volatile. The information is stored in memory and is not preserved when the corresponding registry hive is unloaded. For HKEY_LOCAL_MACHINE, this occurs when the system is shut down. For registry keys loaded by the RegLoadKey function, this occurs when the corresponding RegUnLoadKey is performed. The RegSaveKey function does not save volatile keys. This flag is ignored for keys that already exist.

Return values for $lpdwDisposition

REG_CREATED_NEW_KEY 0x00000001L The key did not exist and was created. REG_OPENED_EXISTING_KEY 0x00000002L The key existed and was simply opened without being changed.

Tags:

  • return - Returns ERROR_SUCCESS on success or error code otherwise
  • access - public

Parameters:

  • object $hKey - A handle to an open registry key. The calling process must have KEY_CREATE_SUB_KEY access to the key
  • string $lpSubKey - The name of a subkey that this function opens or creates. The subkey specified must be a subkey of the key identified by the hKey parameter; it can be up to 32 levels deep in the registry tree.
  • integer $Reserved - This parameter is reserved and must be zero
  • string $lpClass - The user-defined class type of this key. This parameter may be ignored. This parameter can be NULL
  • integer $dwOptions -
  • mixed $samDesired - A mask that specifies the access rights for the key.
  • mixed $lpSecurityAttributes -
  • object $phkResult - A pointer to a variable that receives a handle to the opened or created key. If the key is not one of the predefined registry keys, call the RegCloseKey function after you have finished using the handle.
  • integer $lpdwDisposition -
  • &$phkResult -
  • &$lpdwDisposition -

[ Top ]

static RegEnumKeyEx

static integer RegEnumKeyEx( object $hKey, integer $dwIndex, &$lpName, &$lpcName, mixed $lpReserved, &$lpClass, &$lpcClass, &$lpftLastWriteTime, string $lpName, string $lpClass, string $lpcClass, mixed $lpftLastWriteTime)

[line 439]

Enumerates the subkeys of the specified open registry key.

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • access - public

Parameters:

  • object $hKey - Registry Key
  • integer $dwIndex - Key index
  • string $lpName -
  • string $lpClass - Not implemented
  • mixed $lpReserved - Reserved
  • string $lpcClass - Not implemented
  • mixed $lpftLastWriteTime - Not implemented
  • &$lpName -
  • &$lpcName -
  • &$lpClass -
  • &$lpcClass -
  • &$lpftLastWriteTime -

[ Top ]

static RegEnumValue

static Error RegEnumValue( object $hKey, integer $dwIndex, &$lpValueName, &$lpcchValueName, integer $lpReserved, &$lpType, &$lpData, &$lpcbData, string $lpValueName, integer $lpcchValueName, integer $lpType, mixed $lpData, integer $lpcbData)

[line 480]

Enumerates the values for the specified open registry key.

Tags:

  • return - code or ERROR_SUCCESS on success
  • access - public

Parameters:

  • object $hKey - Registry Key
  • integer $dwIndex - Value index
  • string $lpValueName - Value name
  • integer $lpcchValueName - length of value name
  • integer $lpReserved - Reserved must be zero
  • integer $lpType - Value Type
  • mixed $lpData - Value data
  • integer $lpcbData - Value data length
  • &$lpValueName -
  • &$lpcchValueName -
  • &$lpType -
  • &$lpData -
  • &$lpcbData -

[ Top ]

static RegOpenKeyEx

static integer RegOpenKeyEx( object $hKey, string $lpSubKey, integer $ulOptions, mixed $samDesired, phkResult &$phkResult)

[line 643]

Opens the specified registry key.

Tags:

  • return - Error code on failure or ERROR_SUCCESS on success
  • access - public

Parameters:

  • object $hKey - - A handle to an open registry key.
  • string $lpSubKey - - The name of the registry subkey to be opened,
  • integer $ulOptions - - This parameter is reserved and must be zero.
  • mixed $samDesired - - A mask that specifies the desired access rights to the key
  • phkResult &$phkResult - - A pointer to a variable that receives a handle to the opened key.

[ Top ]

static RegSetValueEx

static integer RegSetValueEx( object $hKey, string $lpValueName, integer $Reserved, integer $dwType, mixed $lpData, integer $cbData)

[line 868]

Sets the data and type of a specified value under a registry key.

Tags:

  • return - Error code on failure or ERROR_SUCCESS on success
  • access - public

Parameters:

  • object $hKey - Registry Key
  • string $lpValueName - Value Name
  • integer $Reserved - Reserved must be zero
  • integer $dwType - Value data type
  • mixed $lpData - Value data
  • integer $cbData - Length of data

[ Top ]

CurrentUser

object HKEY_CURRENT_USER CurrentUser( )

[line 108]

Get instance of HKEY_CURRENT_USER Registry Key

Tags:

  • return - Registry Key
  • access - public

Parameters:

[ Top ]

GetSystemRegistryQuota

integer GetSystemRegistryQuota( )

[line 141]

Retrieves the current size of the registry and the maximum size that the registry is allowed to attain on the system.

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement GetSystemRegistryQuota()
  • access - public

Parameters:

[ Top ]

RegConnectRegistry

integer RegConnectRegistry( )

[line 170]

Establishes a connection to a predefined registry handle on another computer.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegConnectRegistry()
  • access - public

Parameters:

[ Top ]

RegCopyTree

integer RegCopyTree( )

[line 185]

Copies the specified registry key, along with its values and subkeys, to the specified destination key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegCopyTree()
  • access - public

Parameters:

[ Top ]

RegCreateKeyTransacted

integer RegCreateKeyTransacted( )

[line 267]

Create a transacted registry key

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegCreateKeyTransacted()
  • access - public

Parameters:

[ Top ]

RegDeleteKey

integer RegDeleteKey( )

[line 282]

Deletes a subkey and its values.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegDeleteKey()
  • access - public

Parameters:

[ Top ]

RegDeleteKeyEx

integer RegDeleteKeyEx( )

[line 297]

Deletes a subkey and its values from the specified platform-specific view of the registry.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegDeleteKeyEx()
  • access - public

Parameters:

[ Top ]

RegDeleteKeyTransacted

integer RegDeleteKeyTransacted( )

[line 312]

Deletes a subkey and its values from the specified platform-specific view of the registry as a transacted operation.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegDeleteKeyTransacted()
  • access - public

Parameters:

[ Top ]

RegDeleteKeyValue

integer RegDeleteKeyValue( )

[line 327]

Removes the specified value from the specified registry key and subkey.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegDeleteKeyValue()
  • access - public

Parameters:

[ Top ]

RegDeleteTree

integer RegDeleteTree( )

[line 342]

Deletes the subkeys and values of the specified key recursively.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegDeleteTree()
  • access - public

Parameters:

[ Top ]

RegDeleteValue

integer RegDeleteValue( )

[line 357]

Removes a named value from the specified registry key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegDeleteValue()
  • access - public

Parameters:

[ Top ]

RegDisablePredefinedCache

integer RegDisablePredefinedCache( )

[line 372]

Disables handle caching for the predefined registry handle for HKEY_CURRENT_USER for the current process.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegDisablePredefinedCache()
  • access - public

Parameters:

[ Top ]

RegDisablePredefinedCacheEx

integer RegDisablePredefinedCacheEx( )

[line 388]

Disables handle caching for all predefined registry handles for the current process.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegDisablePredefinedCacheEx
  • access - public

Parameters:

[ Top ]

RegDisableReflectionKey

integer RegDisableReflectionKey( )

[line 403]

Disables registry reflection for the specified key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegDisableReflectionKey()
  • access - public

Parameters:

[ Top ]

RegEnableReflectionKey

integer RegEnableReflectionKey( )

[line 418]

Enables registry reflection for the specified disabled key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegEnableReflectionKey()
  • access - public

Parameters:

[ Top ]

RegFlushKey

integer RegFlushKey( )

[line 536]

Writes all attributes of the specified open registry key into the registry.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegFlushKey()
  • access - public

Parameters:

[ Top ]

RegGetKeySecurity

integer RegGetKeySecurity( )

[line 551]

Retrieves a copy of the security descriptor protecting the specified open registry key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegGetKeySecurity()
  • access - public

Parameters:

[ Top ]

RegGetValue

integer RegGetValue( )

[line 566]

Retrieves the type and data for the specified registry value.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegGetValue()
  • access - public

Parameters:

[ Top ]

RegLoadKey

integer RegLoadKey( )

[line 581]

Creates a subkey under HKEY_USERS or HKEY_LOCAL_MACHINE and stores registration information from a specified file into that subkey.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegLoadKey()
  • access - public

Parameters:

[ Top ]

RegLoadMUIString

integer RegLoadMUIString( )

[line 596]

Loads the specified string from the specified key and subkey.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegLoadMUIString()
  • access - public

Parameters:

[ Top ]

RegNotifyChangeKeyValue

integer RegNotifyChangeKeyValue( )

[line 611]

Notifies the caller about changes to the attributes or contents of a specified registry key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegNotifyChangeKeyValue()
  • access - public

Parameters:

[ Top ]

RegOpenCurrentUser

integer RegOpenCurrentUser( )

[line 626]

Retrieves a handle to the HKEY_CURRENT_USER key for the user the current thread is impersonating.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegOpenCurrentUser()
  • access - public

Parameters:

[ Top ]

RegOpenKeyTransacted

integer RegOpenKeyTransacted( )

[line 671]

Opens the specified registry key and associates it with a transaction.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegOpenKeyTransacted()
  • access - public

Parameters:

[ Top ]

RegOpenUserClassesRoot

integer RegOpenUserClassesRoot( )

[line 686]

Retrieves a handle to the HKEY_CLASSES_ROOT key for the specified user.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegOpenUserClassesRoot()
  • access - public

Parameters:

[ Top ]

RegOverridePredefKey

integer RegOverridePredefKey( )

[line 701]

Maps a predefined registry key to a specified registry key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegOverridePredefKey()
  • access - public

Parameters:

[ Top ]

RegQueryInfoKey

integer RegQueryInfoKey( )

[line 716]

Retrieves information about the specified registry key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegQueryInfoKey()
  • access - public

Parameters:

[ Top ]

RegQueryMultipleValues

integer RegQueryMultipleValues( )

[line 731]

Retrieves the type and data for a list of value names associated with an open registry key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegQueryMultipleValues()
  • access - public

Parameters:

[ Top ]

RegQueryReflectionKey

integer RegQueryReflectionKey( )

[line 746]

Determines whether reflection has been disabled or enabled for the specified key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegQueryReflectionKey()
  • access - public

Parameters:

[ Top ]

RegQueryValueEx

integer RegQueryValueEx( )

[line 761]

Retrieves the type and data for a specified value name associated with an open registry key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Impelement RegQueryValueEx()
  • access - public

Parameters:

[ Top ]

RegReplaceKey

integer RegReplaceKey( )

[line 776]

Replaces the file backing a registry key and all its subkeys with another file.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegReplaceKey()
  • access - public

Parameters:

[ Top ]

RegRestoreKey

integer RegRestoreKey( )

[line 791]

Reads the registry information in a specified file and copies it over the specified key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegRestoreKey()
  • access - public

Parameters:

[ Top ]

RegSaveKey

integer RegSaveKey( )

[line 806]

Saves the specified key and all of its subkeys and values to a new file.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegSaveKey()
  • access - public

Parameters:

[ Top ]

RegSaveKeyEx

integer RegSaveKeyEx( )

[line 821]

Saves the specified key and all of its subkeys and values to a new file. You can specify the format for the saved key or hive.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegSaveKeyEx()
  • access - public

Parameters:

[ Top ]

RegSetKeySecurity

integer RegSetKeySecurity( )

[line 851]

Sets the security of an open registry key.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegSetKeySecurity()
  • access - public

Parameters:

[ Top ]

RegSetKeyValue

integer RegSetKeyValue( )

[line 836]

Sets the data for the specified value in the specified registry key and subkey.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegSetKeyValue()
  • access - public

Parameters:

[ Top ]

RegUnLoadKey

integer RegUnLoadKey( )

[line 899]

Unloads the specified registry key and its subkeys from the registry.

Reserved for future use!

Tags:

  • return - Error code, currently returns ERROR_UNSUPPORTED
  • todo - Implement RegUnLoadKey()
  • access - public

Parameters:

[ Top ]


Class Constants


Documentation generated on Sun, 06 Mar 2011 02:22:16 -0600 by phpDocumentor 1.4.3