Class: Wave::Participant

Inherits:
Object
  • Object
show all
Defined in:
lib/wave/participant.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options = {}) ⇒ Participant

Returns a new instance of Participant.

Raises:



15
16
17
18
19
20
21
# File 'lib/wave/participant.rb', line 15

def initialize(options = {})
  @wavelet = options[:wavelet]
  raise Wave::WaveError, "Participant requires wavelet" unless @wavelet
  @wavelet.participants << self
  @id = options[:id]
  raise Wave::WaveError, "Participant requires id" unless @id
end

Instance Attribute Details

#idObject (readonly)

Returns the value of attribute id.



12
13
14
# File 'lib/wave/participant.rb', line 12

def id
  @id
end

#waveletObject (readonly)

Returns the value of attribute wavelet.



12
13
14
# File 'lib/wave/participant.rb', line 12

def wavelet
  @wavelet
end