# File lib/facet/object/assign_with.rb, line 68 def assign_from(obj, *fields) fields.each do |k| var = k.to_s var = var.slice(0,1) == '@' ? var : "@#{var}" self.instance_variable_set( var, obj.instance_variable_get(var) ) if obj.instance_variables.include?(var) @__atttributes__ |= var # else # self.instance_variable_set( k, obj.instance_variable_get(k) ) if obj.instance_variables.include?(k) # #self.send( "#{k}=", obj.send("#{k}") ) if self.respond_to?("#{k}=") && obj.respond_to?("#{k}") # end end end