Hans Oesterholt > Config-Backend-INIREG-0.02 > Config::Backend::Registry

Download:
Config-Backend-INIREG-0.02.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Source  

NAME ^

Config::Backend::Registry - a registry backend for Config::Frontend.

ABSTRACT ^

Config::Backend::Registry is normally used through Config::Backend::INIREG. But it can also function alone. It provides a backend for Config::Frontend that uses the Windows Registry as configuration base.

Description ^

This module uses Win32::TieRegistry for reading and writing the windows registry. Each call to set() or del() will immediately result in a commit to the Windows registry.

new(appname) --> Config::Backend::Registry

Invoked with an application name, will return a Config::Backend::Registry object that is connected to the windows registry at location HKEY_CURRENT_USER/Software/appname.

DESTROY()

This function will untie from the registry.

set(var,value) --> void

Sets config key var to value.

get(var) --> string

Reads var from config. Returns undef, if var does not exist. Returns the value of configuration item var, otherwise.

del(var) --> void

Deletes variable var from the Configuration.

variables() --> list of strings

Returns all variables set through this backend in the windows registry at location HKEY_CURRENT_USER/Software/appname.

Important Note

The enumeration functions of Win32::TieRegistry turned out not to work on Win2K. I've programmed a workaround by keeping an administration of variables in the special variable '.vars'.

SEE ALSO ^

Config::Frontend, Win32::TieRegistry.

AUTHOR ^

Hans Oesterholt-Dijkema, <oesterhol@cpan.org>

COPYRIGHT AND LICENSE ^

Copyright 2004 by Hans Oesterholt-Dijkema

This library is free software; you can redistribute it and/or modify it under Artistic license.

syntax highlighting: