Class: Nayati::OperationImplementerBase

Inherits:
Object
  • Object
show all
Defined in:
app/models/nayati/operation_implementer_base.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(operation_context) ⇒ OperationImplementerBase

Returns a new instance of OperationImplementerBase.



4
5
6
# File 'app/models/nayati/operation_implementer_base.rb', line 4

def initialize(operation_context)
  @operation_context = operation_context
end

Instance Attribute Details

#operation_contextObject

Returns the value of attribute operation_context.



3
4
5
# File 'app/models/nayati/operation_implementer_base.rb', line 3

def operation_context
  @operation_context
end

Instance Method Details

#performObject



17
18
19
# File 'app/models/nayati/operation_implementer_base.rb', line 17

def perform
  puts "#{__callee__} called on #{self.class.name}"
end

#perform_failureObject



13
14
15
# File 'app/models/nayati/operation_implementer_base.rb', line 13

def perform_failure
  puts "#{__callee__} called on #{self.class.name}"
end

#to_fail?Boolean

Returns:

  • (Boolean)


8
9
10
11
# File 'app/models/nayati/operation_implementer_base.rb', line 8

def to_fail?
  puts "#{__callee__} called on #{self.class.name}"
  false
end