Class: OpenTok::BroadcastList

Inherits:
Array
  • Object
show all
Defined in:
lib/opentok/broadcast_list.rb

Overview

A class for accessing an array of Broadcast objects.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(interface, json) ⇒ BroadcastList

Returns a new instance of BroadcastList.



9
10
11
12
# File 'lib/opentok/broadcast_list.rb', line 9

def initialize(interface, json)
  @total = json["count"]
  super json["items"].map { |item| ::OpenTok::Broadcast.new interface, item }
end

Instance Attribute Details

#totalObject (readonly)

The total number of broadcasts.



7
8
9
# File 'lib/opentok/broadcast_list.rb', line 7

def total
  @total
end