lib/turntabler/room_directory.rb
def find(query, options = {})
      assert_valid_keys(options, :limit, :skip)
      options = {:limit => 20, :skip => 0}.merge(options)

      data = api('room.search', :query => query, :skip => options[:skip])
      data['rooms'].map {|(attrs, *)| Room.new(client, attrs)}
    end
def find(query, options = {})
      assert_valid_keys(options, :limit, :skip)
      options = {:limit => 20, :skip => 0}.merge(options)

      data = api('room.search', :query => query, :skip => options[:skip])
      data['rooms'].map {|(attrs, *)| Room.new(client, attrs)}
    end
def find ( query , options = { } ) assert_valid_keys ( options , :limit , :skip ) options = { :limit => 20 , :skip => 0 } . merge ( options ) data = api ( 'room.search' , :query => query , :skip => options [ :skip ] ) data [ 'rooms' ] . map { | ( attrs , * ) | Room . new ( client , attrs ) } end
Finds rooms that match the given query string.

 @param [String] query The query string to search with
 @param [Hash] options The search options
 @option options [Fixnum] :limit (20) The maximum number of rooms to query for
 @option options [Fixnum] :skip (0) The number of rooms to skip when loading the results
 @return [Array<Turntabler::Room>]
 @raise [ArgumentError] if an invalid option is specified
 @raise [Turntabler::Error] if the command fails
   rooms.find('indie')   # => [#<Turntabler::Room ...>, ...]
Finds rooms that match the given query string .