mirror of https://github.com/OpenVidu/openvidu.git
openvidu-browser: Stream is not a public EventDispatcher
parent
2cef860128
commit
4219c6dbc7
|
@ -16,12 +16,10 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import { Connection } from './Connection';
|
import { Connection } from './Connection';
|
||||||
import { Event } from '../OpenViduInternal/Events/Event';
|
|
||||||
import { Filter } from './Filter';
|
import { Filter } from './Filter';
|
||||||
import { Session } from './Session';
|
import { Session } from './Session';
|
||||||
import { StreamManager } from './StreamManager';
|
import { StreamManager } from './StreamManager';
|
||||||
import { Subscriber } from './Subscriber';
|
import { Subscriber } from './Subscriber';
|
||||||
import { EventDispatcher } from './EventDispatcher';
|
|
||||||
import { InboundStreamOptions } from '../OpenViduInternal/Interfaces/Private/InboundStreamOptions';
|
import { InboundStreamOptions } from '../OpenViduInternal/Interfaces/Private/InboundStreamOptions';
|
||||||
import { OutboundStreamOptions } from '../OpenViduInternal/Interfaces/Private/OutboundStreamOptions';
|
import { OutboundStreamOptions } from '../OpenViduInternal/Interfaces/Private/OutboundStreamOptions';
|
||||||
import { WebRtcPeer, WebRtcPeerSendonly, WebRtcPeerRecvonly, WebRtcPeerSendrecv } from '../OpenViduInternal/WebRtcPeer/WebRtcPeer';
|
import { WebRtcPeer, WebRtcPeerSendonly, WebRtcPeerRecvonly, WebRtcPeerSendrecv } from '../OpenViduInternal/WebRtcPeer/WebRtcPeer';
|
||||||
|
@ -37,6 +35,10 @@ import { PlatformUtils } from '../OpenViduInternal/Utils/Platform';
|
||||||
* @hidden
|
* @hidden
|
||||||
*/
|
*/
|
||||||
import hark = require('hark');
|
import hark = require('hark');
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
import EventEmitter = require('wolfy87-eventemitter');
|
||||||
/**
|
/**
|
||||||
* @hidden
|
* @hidden
|
||||||
*/
|
*/
|
||||||
|
@ -52,7 +54,7 @@ let platform: PlatformUtils;
|
||||||
* Each [[Publisher]] and [[Subscriber]] has an attribute of type Stream, as they give access
|
* Each [[Publisher]] and [[Subscriber]] has an attribute of type Stream, as they give access
|
||||||
* to one of them (sending and receiving it, respectively)
|
* to one of them (sending and receiving it, respectively)
|
||||||
*/
|
*/
|
||||||
export class Stream extends EventDispatcher {
|
export class Stream {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The Connection object that is publishing the stream
|
* The Connection object that is publishing the stream
|
||||||
|
@ -207,6 +209,10 @@ export class Stream extends EventDispatcher {
|
||||||
* @hidden
|
* @hidden
|
||||||
*/
|
*/
|
||||||
localMediaStreamWhenSubscribedToRemote?: MediaStream;
|
localMediaStreamWhenSubscribedToRemote?: MediaStream;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
ee = new EventEmitter();
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -214,7 +220,6 @@ export class Stream extends EventDispatcher {
|
||||||
*/
|
*/
|
||||||
constructor(session: Session, options: InboundStreamOptions | OutboundStreamOptions | {}) {
|
constructor(session: Session, options: InboundStreamOptions | OutboundStreamOptions | {}) {
|
||||||
|
|
||||||
super();
|
|
||||||
platform = PlatformUtils.getInstance();
|
platform = PlatformUtils.getInstance();
|
||||||
this.session = session;
|
this.session = session;
|
||||||
|
|
||||||
|
@ -271,33 +276,6 @@ export class Stream extends EventDispatcher {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* See [[EventDispatcher.on]]
|
|
||||||
*/
|
|
||||||
on(type: string, handler: (event: Event) => void): EventDispatcher {
|
|
||||||
super.onAux(type, "Event '" + type + "' triggered by stream '" + this.streamId + "'", handler);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* See [[EventDispatcher.once]]
|
|
||||||
*/
|
|
||||||
once(type: string, handler: (event: Event) => void): EventDispatcher {
|
|
||||||
super.onceAux(type, "Event '" + type + "' triggered once by stream '" + this.streamId + "'", handler);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* See [[EventDispatcher.off]]
|
|
||||||
*/
|
|
||||||
off(type: string, handler?: (event: Event) => void): EventDispatcher {
|
|
||||||
super.off(type, handler);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Applies an audio/video filter to the stream.
|
* Applies an audio/video filter to the stream.
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in New Issue