class Posgra::DSL::Database::Role
Attributes
result[R]
Public Class Methods
new(context, role, options, &block)
click to toggle source
# File lib/posgra/dsl/database/role.rb, line 8 def initialize(context, role, options, &block) @role = role @options = options @context = context.merge(:role => role) @result = {} instance_eval(&block) end
Public Instance Methods
database(name, &block)
click to toggle source
# File lib/posgra/dsl/database/role.rb, line 16 def database(name, &block) name = name.to_s if matched?(name, @options[:include_database], @options[:exclude_database]) @result[name] = Posgra::DSL::Database::Role::Database.new(@context, name, @options, &block).result end end