BusDict 


A bus allocator that stores descriptive names of buses in a global dictionary. The dictionaries record each server for which a bus is allocated, pointing to another dictionary keyed by bus number. 


Use BusDict instead of Bus if you want names of your allocated buses to appear in MixingBoards that you create. 


*new(server) 


Adds the required dictionary entries for the given server. This does not return a Bus object! It only initializes BusDict for this server. Use one of the following three methods to create a new bus.


*alloc(rate, server, numChannels, name) 

*audio(server, numChannels, name)

*control(server, numChannels, name) 


Allocates a Bus. This works exactly like the corresponding methods in Bus, except for the name argument, which may be a string or a symbol. 


*at(rate, server, index) 


Looks up a bus object in the dictionary. If a bus was allocated using Bus and you try to use BusDict.at to look it up, you'll get nil. If you just want a pointer to a bus that's already been allocated, use Bus.new instead.


To look up the name of an individual bus, use BusDict.audioNames.at(server).at(index) or BusDict.controlNames.at(server).at(index). 


*free(bus) 

*freeAt(rate, server, index)

*freeAll(server) 


Frees previously allocated buses and removes their entries from the appropriate dictionary. 


*postServer(server) 


List all the names of the buses registered for the server.


*post

*postln 


List the names of the buses registered in all servers. This can be useful for debugging, to make sure the buses were allocated as you thought they were.


*menuItems(server, rate)


Returns an array giving the name of every bus, with an array item for each possible bus index. Multichannel buses are expanded into multiple items: a four-channel bus would appear as [..., quad bus, quad bus.1, quad bus.2, quad bus.3, ...]. This is so that the bus index and the array index can be identical. Used by MixingBoard.