lib/punchblock/ref.rb in punchblock-0.5.1 vs lib/punchblock/ref.rb in punchblock-0.6.0
- old
+ new
@@ -3,9 +3,15 @@
# An rayo Ref message. This provides the command ID in response to execution of a command.
#
class Ref < RayoNode
register :ref, :core
+ def self.new(options = {})
+ super().tap do |new_node|
+ options.each_pair { |k,v| new_node.send :"#{k}=", v }
+ end
+ end
+
##
# @return [String] the command ID
#
def id
read_attr :id