Class: RR::DoubleDefinitions::Strategies::Strategy
- Inherits:
-
Object
- Object
- RR::DoubleDefinitions::Strategies::Strategy
- Includes:
- Space::Reader
- Defined in:
- lib/rr/double_definitions/strategies/strategy.rb
Direct Known Subclasses
DoubleInjection::DoubleInjectionStrategy, Implementation::ImplementationStrategy, Verification::VerificationStrategy
Instance Attribute Summary collapse
-
#args ⇒ Object
readonly
Returns the value of attribute args.
-
#definition ⇒ Object
readonly
Returns the value of attribute definition.
-
#double_definition_create ⇒ Object
readonly
Returns the value of attribute double_definition_create.
-
#handler ⇒ Object
readonly
Returns the value of attribute handler.
-
#kwargs ⇒ Object
readonly
Returns the value of attribute kwargs.
-
#method_name ⇒ Object
readonly
Returns the value of attribute method_name.
Instance Method Summary collapse
- #call(definition, method_name, args, kwargs, handler) ⇒ Object
-
#initialize(double_definition_create) ⇒ Strategy
constructor
A new instance of Strategy.
- #verify_subject(subject) ⇒ Object
Methods included from Space::Reader
Constructor Details
#initialize(double_definition_create) ⇒ Strategy
Returns a new instance of Strategy.
14 15 16 |
# File 'lib/rr/double_definitions/strategies/strategy.rb', line 14 def initialize(double_definition_create) @double_definition_create = double_definition_create end |
Instance Attribute Details
#args ⇒ Object (readonly)
Returns the value of attribute args.
8 9 10 |
# File 'lib/rr/double_definitions/strategies/strategy.rb', line 8 def args @args end |
#definition ⇒ Object (readonly)
Returns the value of attribute definition.
6 7 8 |
# File 'lib/rr/double_definitions/strategies/strategy.rb', line 6 def definition @definition end |
#double_definition_create ⇒ Object (readonly)
Returns the value of attribute double_definition_create.
5 6 7 |
# File 'lib/rr/double_definitions/strategies/strategy.rb', line 5 def double_definition_create @double_definition_create end |
#handler ⇒ Object (readonly)
Returns the value of attribute handler.
10 11 12 |
# File 'lib/rr/double_definitions/strategies/strategy.rb', line 10 def handler @handler end |
#kwargs ⇒ Object (readonly)
Returns the value of attribute kwargs.
9 10 11 |
# File 'lib/rr/double_definitions/strategies/strategy.rb', line 9 def kwargs @kwargs end |
#method_name ⇒ Object (readonly)
Returns the value of attribute method_name.
7 8 9 |
# File 'lib/rr/double_definitions/strategies/strategy.rb', line 7 def method_name @method_name end |
Instance Method Details
#call(definition, method_name, args, kwargs, handler) ⇒ Object
18 19 20 21 22 23 24 25 |
# File 'lib/rr/double_definitions/strategies/strategy.rb', line 18 def call(definition, method_name, args, kwargs, handler) @definition = definition @method_name = method_name @args = args @kwargs = kwargs @handler = handler do_call end |
#verify_subject(subject) ⇒ Object
27 28 |
# File 'lib/rr/double_definitions/strategies/strategy.rb', line 27 def verify_subject(subject) end |