class Ridley::NodeResource
Public Class Methods
new(connection_registry, options = {})
click to toggle source
@param [Celluloid::Registry] connection_registry
Calls superclass method
Ridley::Resource::new
# File lib/ridley/resources/node_resource.rb, line 9 def initialize(connection_registry, options = {}) super(connection_registry) end
Public Instance Methods
merge_data(target, options = {})
click to toggle source
Merges the given data with the the data of the target node on the remote
@param [Ridley::NodeResource, String] target
node or identifier of the node to merge
@option options [Array] :run_list
run list items to merge
@option options [Hash] :attributes
attributes of normal precedence to merge
@raise [Errors::ResourceNotFound]
if the target node is not found
@return [Ridley::NodeObject]
# File lib/ridley/resources/node_resource.rb, line 27 def merge_data(target, options = {}) unless node = find(target) abort Errors::ResourceNotFound.new end update(node.merge_data(options)) end