Methods
Public Instance methods
inject_attributes( container )

Injects all injectable attributes of the instance’s class with the corresponding services from the given container. Each attribute is injected into an identically named instance variable of the object, from an identically named service in the container.

This returns the object itself.

    # File lib/needle/extras/attr-inject.rb, line 32
32:   def inject_attributes( container )
33:     self.class.injectable_attributes.each do |attribute|
34:       instance_variable_set "@#{attribute}", container.get( attribute )
35:     end
36:     self
37:   end