PeerGroup:
Filter:
Classes (extension) | Utopia | External Control > OSC

PeerGroup : Array : ArrayedCollection : SequenceableCollection : Collection : Object
ExtensionExtension

A group of Peers

Description

PeerGroup is an Array subclass that spoofs a NetAddr. You can use it send messages to a group of Peers at the same time. PeerGroups can be constructed manually or using a PeerGroupManager which syncs groups across a Utopia. As well, AddrBook provides a number of convenience methods:

Class Methods

PeerGroup.new(name, peers)

Create a new PeerGroup.

Arguments:

name

A Symbol naming the group.

peers

A Collection of Peers to add to the new group.

Returns:

A new PeerGroup with the supplied Peers.

Inherited class methods

Instance Methods

.name

.name = value

Get or set the name of this group.

Returns:

.sendRaw(rawArray)

Send a raw message without timestamp to the Peers in this Group.

Arguments:

rawArray

An Int8Array containing the bytes of the OSC message to send.

.sendMsg( ... args)

Send a message without timestamp to the Peers in this Group.

Arguments:

 ... args

An OSC path and one or more OSC args.

.sendBundle(time ... args)

Send an OSC bundle with timestamp to the Peers in this Group.

Arguments:

time

A time offset from logical now in seconds.

 ... args

One or more Arrays consisting of an OSC path and one or more OSC args.

Inherited instance methods