Class: Capistrano::Configuration::Server::Properties

### Home Classes Methods

### In Files

- lib/capistrano/configuration/server.rb

### Parent

Object

### Methods

- ::new
- #fetch
- #keys
- #method_missing
- #respond_to?
- #roles
- #set

### Files

- Capfile
- Capfile

### Class/Module Index

Quicksearch

- Capistrano
- Capistrano::Application
- Capistrano::Configuration
- Capistrano::Configuration::Filter
- Capistrano::Configuration::Question
- Capistrano::Configuration::Server
- Capistrano::Configuration::Server::Properties
- Capistrano::Configuration::Servers
- Capistrano::DSL
- Capistrano::DSL::Env
- Capistrano::DSL::Paths
- Capistrano::DSL::Stages
- Capistrano::Git
- Capistrano::Git::DefaultStrategy
- Capistrano::Hg
- Capistrano::Hg::DefaultStrategy
- Capistrano::SCM
- Capistrano::Svn
- Capistrano::Svn::DefaultStrategy
- Capistrano::TaskEnhancements
- Capistrano::UploadTask
- Capistrano::VersionValidator
- Object

No matching classes.

# Capistrano::Configuration::Server::Properties

### Public Class Methods

new() click to toggle source

    # File lib/capistrano/configuration/server.rb, line 80
    def initialize
      @properties = {}
    end

### Public Instance Methods

fetch(key) click to toggle source

    # File lib/capistrano/configuration/server.rb, line 97
    def fetch(key)
      @properties[key]
    end

keys() click to toggle source

    # File lib/capistrano/configuration/server.rb, line 109
    def keys
      @properties.keys
    end

method_missing(key, value=nil) click to toggle source

    # File lib/capistrano/configuration/server.rb, line 113
    def method_missing(key, value=nil)
      if value
        set(lvalue(key), value)
      else
        fetch(key)
      end
    end

respond_to?(method, include_all=false) click to toggle source

    # File lib/capistrano/configuration/server.rb, line 101
    def respond_to?(method, include_all=false)
      @properties.has_key?(method)
    end

roles() click to toggle source

    # File lib/capistrano/configuration/server.rb, line 105
    def roles
      @roles ||= Set.new
    end

set(key, value) click to toggle source

    # File lib/capistrano/configuration/server.rb, line 84
    def set(key, value)
      pval = @properties[key]
      if pval.is_a? Hash and value.is_a? Hash
        pval.merge!(value)
      elsif pval.is_a? Set and value.is_a? Set
        pval.merge(value)
      elsif pval.is_a? Array and value.is_a? Array
        pval.concat value
      else
        @properties[key] = value
      end
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.