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.



58
59
60
61
62
63
64
65
# File 'lib/oflow/actor.rb', line 58

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.



55
56
57
# File 'lib/oflow/actor.rb', line 55

def op
  @op
end

#typeObject (readonly)

Returns the value of attribute type.



56
57
58
# File 'lib/oflow/actor.rb', line 56

def type
  @type
end

Instance Method Details

#to_sObject Also known as: inspect



69
70
71
# File 'lib/oflow/actor.rb', line 69

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