Class: Hiptest::Nodes::Parameter

Inherits:
Node
  • Object
show all
Defined in:
lib/hiptest-publisher/nodes.rb

Instance Attribute Summary

Attributes inherited from Node

#children, #parent

Instance Method Summary collapse

Methods inherited from Node

#==, #each_direct_children, #each_sub_nodes, #kind, #pretty_print_instance_variables, #project, #render

Constructor Details

#initialize(name, default = nil) ⇒ Parameter

Returns a new instance of Parameter.



223
224
225
226
# File 'lib/hiptest-publisher/nodes.rb', line 223

def initialize(name, default = nil)
  super()
  @children = {:name => name, :default => default}
end

Instance Method Details

#typeObject



228
229
230
231
232
233
234
# File 'lib/hiptest-publisher/nodes.rb', line 228

def type
  if @children[:type].nil?
    'String'
  else
    @children[:type].to_s
  end
end