# File lib/puppet/type/file.rb, line 412 412: def newchild(path) 413: full_path = File.join(self[:path], path) 414: 415: # Add some new values to our original arguments -- these are the ones 416: # set at initialization. We specifically want to exclude any param 417: # values set by the :source property or any default values. 418: # LAK:NOTE This is kind of silly, because the whole point here is that 419: # the values set at initialization should live as long as the resource 420: # but values set by default or by :source should only live for the transaction 421: # or so. Unfortunately, we don't have a straightforward way to manage 422: # the different lifetimes of this data, so we kludge it like this. 423: # The right-side hash wins in the merge. 424: options = @original_parameters.merge(:path => full_path).reject { |param, value| value.nil? } 425: 426: # These should never be passed to our children. 427: [:parent, :ensure, :recurse, :recurselimit, :target, :alias, :source].each do |param| 428: options.delete(param) if options.include?(param) 429: end 430: 431: self.class.new(options) 432: end