Class: OFlow::Actor::Spec

Inherits:
Object
  • Object
show all
Defined in:
lib/oflow/actor.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(op, type) ⇒ Spec

Returns a new instance of Spec.



55
56
57
58
59
60
61
62
# File 'lib/oflow/actor.rb', line 55

def initialize(op, type)
  if op.nil? || op.is_a?(Symbol)
    @op = op
  else
    @op = op.to_sym
  end
  @type = type
end

Instance Attribute Details

#opObject (readonly) Also known as: dest

Returns the value of attribute op.



52
53
54
# File 'lib/oflow/actor.rb', line 52

def op
  @op
end

#typeObject (readonly)

Returns the value of attribute type.



53
54
55
# File 'lib/oflow/actor.rb', line 53

def type
  @type
end

Instance Method Details

#to_sObject Also known as: inspect



66
67
68
# File 'lib/oflow/actor.rb', line 66

def to_s()
  "Spec{op: #{@op}, type: #{@type}}"
end