Class: PluginBuilder

Inherits:
Object
  • Object
show all
Defined in:
lib/zmb/plugin.rb

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Constructor Details

- (PluginBuilder) initialize(&block)



67
68
69
70
# File 'lib/zmb/plugin.rb', line 67

def initialize(&block)
  @plugin = Plugin.new
  @block = block
end

Instance Attribute Details

- (Object) plugin

Returns the value of attribute plugin



65
66
67
# File 'lib/zmb/plugin.rb', line 65

def plugin
  @plugin
end

Instance Method Details

- (Object) build



72
73
74
# File 'lib/zmb/plugin.rb', line 72

def build
  instance_eval(&@block)
end

- (Object) description(value)



80
81
82
# File 'lib/zmb/plugin.rb', line 80

def description(value)
  @plugin.description = value
end

- (Object) multi_instances(value)



88
89
90
# File 'lib/zmb/plugin.rb', line 88

def multi_instances(value)
  @plugin.multi_instances = value
end

- (Object) name(value)



76
77
78
# File 'lib/zmb/plugin.rb', line 76

def name(value)
  @plugin.name = value
end

- (Object) object(value)



84
85
86
# File 'lib/zmb/plugin.rb', line 84

def object(value)
  @plugin.object = value
end