Class: Punchblock::Component::Asterisk::AGI::Command::Param

Inherits:
RayoNode
  • Object
show all
Defined in:
lib/punchblock/component/asterisk/agi/command.rb

Constant Summary

Constants inherited from RayoNode

RayoNode::InvalidNodeError

Instance Attribute Summary

Attributes inherited from RayoNode

#client, #component_id, #connection, #domain, #original_component, #target_call_id, #target_mixer_name

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from RayoNode

class_from_registration, #eql?, import, #inspect, register, #source

Class Method Details

.new(value) ⇒ Object

Parameters:

  • name (String)
  • value (String)


57
58
59
60
61
62
63
64
65
66
# File 'lib/punchblock/component/asterisk/agi/command.rb', line 57

def self.new(value)
  super(:param).tap do |new_node|
    case value
    when Nokogiri::XML::Node
      new_node.inherit value
    else
      new_node.value = value
    end
  end
end

Instance Method Details

#inspect_attributesObject

:nodoc:



80
81
82
# File 'lib/punchblock/component/asterisk/agi/command.rb', line 80

def inspect_attributes # :nodoc:
  [:value] + super
end

#valueString

The Header’s value

Returns:

  • (String)


70
71
72
# File 'lib/punchblock/component/asterisk/agi/command.rb', line 70

def value
  read_attr :value
end

#value=(value) ⇒ Object

Set the Header’s value

Parameters:

  • value (String)

    the new value for the param



76
77
78
# File 'lib/punchblock/component/asterisk/agi/command.rb', line 76

def value=(value)
  write_attr :value, value
end