### In Files

- rumix/registry.rb

### Parent

Object

### Methods

- clear
- load
- load
- new
- save
- store

### Files

- wxruby2.lib

### Class Index

Quicksearch

- Wx
- Wx::AcceleratorTable
- Wx::Animation
- Wx::App
- Wx::ArtProvider
- Wx::AuiNotebook
- Wx::Bitmap
- Wx::BusyCursor
- Wx::CheckListBox
- Wx::Choice
- Wx::ClientDC
- Wx::Clipboard
- Wx::Colour
- Wx::ComboBox
- Wx::CommandEvent
- Wx::ControlWithItems
- Wx::DC
- Wx::Event
- Wx::EvtHandler
- Wx::Font
- Wx::Grid
- Wx::HelpController
- Wx::HelpControllerHelpProvider
- Wx::HelpProvider
- Wx::HtmlHelpController
- Wx::HtmlWindow
- Wx::Icon
- Wx::IconBundle
- Wx::Image
- Wx::ImageList
- Wx::KeywordConstructor
- Wx::KeywordConstructor::ClassMethods
- Wx::ListBox
- Wx::ListCtrl
- Wx::Locale
- Wx::MediaCtrl
- Wx::Menu
- Wx::MenuItem
- Wx::Notebook
- Wx::Object
- Wx::PaintDC
- Wx::Point
- Wx::PreviewFrame
- Wx::Rect
- Wx::RichTextCtrl
- Wx::SimpleHelpProvider
- Wx::Size
- Wx::Sizer
- Wx::Sound
- Wx::StandardPaths
- Wx::TextCtrl
- Wx::TextUrlEvent
- Wx::Timer
- Wx::ToolBar
- Wx::ToolBarTool
- Wx::TreeCtrl
- Wx::Window
- Wx::XmlResource
- Rumix
- Rumix::Application
- Rumix::Config
- Rumix::Registry
- Rumix::Widget
- Rumix::Widget::CheckOptionPanel
- Rumix::Widget::OptionItem
- Rumix::Widget::OptionPanel
- Rumix::Widget::RadioOptionPanel
- Rumix::Widget::TitleText
- ROpt
- ROpt::ArgumentParser
- ROpt::ParseResult
- Uconv
- Uconv::Error
- Enumerable
- File
- Ini
- Kernel
- Module
- Object
- Pathname
- WxConstructor
- WxRubyStyleAccessors

No matching classes.

# Rumix::Registry

### Constants

PRIMARY_KEY
  (Not documented)
SUB_KEY
  (Not documented)

### Attributes

install_path[RW]

(Not documented)

### Public Class Methods

load(sub_key = SUB_KEY) click to toggle source

(Not documented)

    # File rumix/registry.rb, line 12
                    def self.load(sub_key = SUB_KEY)
                            self.new(sub_key).load
                    end

new(sub_key = SUB_KEY) click to toggle source

(Not documented)

    # File rumix/registry.rb, line 16
                    def initialize(sub_key = SUB_KEY)
                            @sub_key = sub_key
                            clear
                    end

### Public Instance Methods

clear() click to toggle source

(Not documented)

    # File rumix/registry.rb, line 21
                    def clear
                            @install_path = nil
                            return self
                    end

load() click to toggle source

Try to load registry. If fail, clear itself. Return: self

    # File rumix/registry.rb, line 28
                    def load
                            begin
                                    PRIMARY_KEY.open(@sub_key) do |reg|
                                            @install_path = reg['InstallPath']
                                    end
                            rescue Win32::Registry::Error
                                    clear
                            end

                            return self
                    end

save() click to toggle source

Alias for store

store() click to toggle source

Return: success

    # File rumix/registry.rb, line 41
                    def store
                            if @install_path.kind_of?(String) then
                                    PRIMARY_KEY.create(@sub_key) do |reg|
                                            reg['InstallPath'] = @install_path
                                    end
                                    return true
                            else
                                    return false
                            end
                    end

Also aliased as: save

Disabled; run with $DEBUG to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.