client Class APE.PipeMulti

Summary

Extends:
File
<./src/Ape_Jsf/Source/Pipe/PipeMulti.js>

PipeMulti Class Detail

APE.PipeMulti ()
PipeMulti object
File:
<./src/Ape_Jsf/Source/Pipe/PipeMulti.js>
See:

Summary

Own
Attributes Type Name Description
<static>   APE.PipeMulti users A MooTools hash of user on the pipe.
Inherrited

<static> APE.PipeMulti users

A MooTools hash of user on the pipe.

If you use this variable in the multiPipeCreate events it will be empty.

If you want to access to all user on pipe in the multiPipeCreate event use the options.users (object) (second parameter passed to multiPipeCreate event)

See:
APE.multiPipeCreate

Summary

Own
Methods Attributes Methods Name Methods Description
<static>   APE.PipeMulti. addUser (pubid, updatedUser) Add another user to this pipe
<static>   APE.PipeMulti. delUser (pubid) Add another user to this pipe
<static>   APE.PipeMulti. getUser (pubid) Return an user object identified by his pubid.
<static>   APE.PipeMulti. getUserPipe (user) Return an user object identified by his pubid.
<static>   APE.PipeMulti. left () Force this user to leave this pipe
Inherrited

<static> {user} APE.PipeMulti. addUser (pubid, updatedUser)

Add another user to this pipe
Parameters:
{string} pubid A user's pubid
{object} updatedUser An updated user object
Returns:
{user} user object
See:

<static> {user} APE.PipeMulti. delUser (pubid)

Add another user to this pipe
Parameters:
{string} pubid A user's pubid
Returns:
{user}
See:

<static> {user} APE.PipeMulti. getUser (pubid)

Return an user object identified by his pubid.
Parameters:
{string} pubid A user's pubid
Returns:
{user} An user object (with pubid and properties) or null
See:

<static> {pipe} APE.PipeMulti. getUserPipe (user)

Return an user object identified by his pubid.
Parameters:
{string|user} user A user's pubid or a user object
Returns:
{pipe} An pipe to the other user
See:

<static> {void} APE.PipeMulti. left ()

Force this user to leave this pipe
Returns:
{void}
Example
//ape var is a reference to APE instance
//Join testchannel
ape.join('testchannel');
//Intercept pipeCreate event (this event is fired when you join a channel)
ape.addEvent('multiPipeCreate', function(pipe, options) {
	if (pipe.properties.name=='teschannel') {
		//If pipe is testchannel, left it :p
		pipe.left();
	}
});