2018-04-26 15:33:47 +02:00
|
|
|
import { Event } from './Event';
|
2018-05-08 13:01:34 +02:00
|
|
|
import { Publisher } from '../../OpenVidu/Publisher';
|
|
|
|
import { Session } from '../../OpenVidu/Session';
|
|
|
|
import { Stream } from '../../OpenVidu/Stream';
|
2018-04-26 15:33:47 +02:00
|
|
|
/**
|
|
|
|
* Defines the following events:
|
|
|
|
* - `streamCreated`: dispatched by [[Session]] and [[Publisher]]
|
|
|
|
* - `streamDestroyed`: dispatched by [[Session]] and [[Publisher]]
|
|
|
|
*/
|
|
|
|
export declare class StreamEvent extends Event {
|
|
|
|
/**
|
|
|
|
* Stream object that was created or destroyed
|
|
|
|
*/
|
|
|
|
stream: Stream;
|
|
|
|
/**
|
|
|
|
* For 'streamDestroyed' event:
|
2018-05-08 10:40:46 +02:00
|
|
|
* - "unpublish": method `Session.unpublish()` has been called
|
|
|
|
* - "disconnect": method `Session.disconnect()` has been called
|
2018-07-11 11:47:53 +02:00
|
|
|
* - "forceUnpublishByUser": some user has called `Session.forceUnpublish()` over the Stream
|
|
|
|
* - "forceDisconnectByUser": some user has called `Session.forceDisconnect()` over the Stream
|
|
|
|
* - "forceUnpublishByServer": the user's stream has been unpublished from the Session by the application
|
|
|
|
* - "forceDisconnectByServer": the user has been evicted from the Session by the application
|
|
|
|
* - "sessionClosedByServer": the Session has been closed by the application
|
2018-05-08 10:40:46 +02:00
|
|
|
* - "networkDisconnect": the user's network connection has dropped
|
2018-04-26 15:33:47 +02:00
|
|
|
*
|
|
|
|
* For 'streamCreated' empty string
|
|
|
|
*/
|
|
|
|
reason: string;
|
|
|
|
/**
|
|
|
|
* @hidden
|
|
|
|
*/
|
|
|
|
constructor(cancelable: boolean, target: Session | Publisher, type: string, stream: Stream, reason: string);
|
|
|
|
/**
|
|
|
|
* @hidden
|
|
|
|
*/
|
2018-07-11 11:47:53 +02:00
|
|
|
callDefaultBehavior(): void;
|
2018-04-26 15:33:47 +02:00
|
|
|
}
|