@flashphoner/websdk 2.0.216 → 2.0.217

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9682,717 +9682,926 @@ exports['WSPlayer'] = WSPlayer;
9682
9682
  * @see Session
9683
9683
  */
9684
9684
 
9685
- var sessionStatus = {};
9686
- /**
9687
- * Fires when {@link Session} ws socket opens.
9688
- * @event CONNECTED
9689
- * @memberof Flashphoner.constants.SESSION_STATUS
9690
- */
9685
+ var SESSION_STATUS = Object.freeze({
9686
+ /**
9687
+ * Fires when {@link Session} ws socket opens.
9688
+ * @event CONNECTED
9689
+ * @memberof Flashphoner.constants.SESSION_STATUS
9690
+ */
9691
+ CONNECTED: 'CONNECTED',
9691
9692
 
9692
- define(sessionStatus, 'CONNECTED', 'CONNECTED');
9693
- /**
9694
- * Fires when {@link Session} receives connect ack from REST App.
9695
- * @event ESTABLISHED
9696
- * @memberof Flashphoner.constants.SESSION_STATUS
9697
- */
9693
+ /**
9694
+ * Fires when {@link Session} receives connect ack from REST App.
9695
+ * @event ESTABLISHED
9696
+ * @memberof Flashphoner.constants.SESSION_STATUS
9697
+ */
9698
+ ESTABLISHED: 'ESTABLISHED',
9698
9699
 
9699
- define(sessionStatus, 'ESTABLISHED', 'ESTABLISHED');
9700
- /**
9701
- * Fires when {@link Session} disconnects.
9702
- * @event DISCONNECTED
9703
- * @memberof Flashphoner.constants.SESSION_STATUS
9704
- */
9700
+ /**
9701
+ * Fires when {@link Session} disconnects.
9702
+ * @event DISCONNECTED
9703
+ * @memberof Flashphoner.constants.SESSION_STATUS
9704
+ */
9705
+ DISCONNECTED: 'DISCONNECTED',
9705
9706
 
9706
- define(sessionStatus, 'DISCONNECTED', 'DISCONNECTED');
9707
- /**
9708
- * Fires if {@link Session} call of rest method error.
9709
- * @event WARN
9710
- * @memberof Flashphoner.constants.SESSION_STATUS
9711
- */
9707
+ /**
9708
+ * Fires if {@link Session} call of rest method error.
9709
+ * @event WARN
9710
+ * @memberof Flashphoner.constants.SESSION_STATUS
9711
+ */
9712
+ WARN: 'WARN',
9712
9713
 
9713
- define(sessionStatus, 'WARN', 'WARN');
9714
- /**
9715
- * Fires if {@link Session} connection failed.
9716
- * Some of the reasons can be network connection failed, REST App failed
9717
- * @event FAILED
9718
- * @memberof Flashphoner.constants.SESSION_STATUS
9719
- */
9714
+ /**
9715
+ * Fires if {@link Session} connection failed.
9716
+ * Some of the reasons can be network connection failed, REST App failed
9717
+ * @event FAILED
9718
+ * @memberof Flashphoner.constants.SESSION_STATUS
9719
+ */
9720
+ FAILED: 'FAILED',
9720
9721
 
9721
- define(sessionStatus, 'FAILED', 'FAILED');
9722
- /**
9723
- * Fires wneh {@link Session} receives debug event
9724
- * @event DEBUG
9725
- * @memberof Flashphoner.constants.SESSION_STATUS
9726
- */
9722
+ /**
9723
+ * Fires wneh {@link Session} receives debug event
9724
+ * @event DEBUG
9725
+ * @memberof Flashphoner.constants.SESSION_STATUS
9726
+ */
9727
+ DEBUG: 'DEBUG',
9727
9728
 
9728
- define(sessionStatus, 'DEBUG', 'DEBUG');
9729
- /**
9730
- * Fires when {@link Session} receives custom REST App message.
9731
- *
9732
- * @event APP_DATA
9733
- * @memberof Flashphoner.constants.SESSION_STATUS
9734
- */
9729
+ /**
9730
+ * Fires when {@link Session} receives custom REST App message.
9731
+ *
9732
+ * @event APP_DATA
9733
+ * @memberof Flashphoner.constants.SESSION_STATUS
9734
+ */
9735
+ APP_DATA: 'APP_DATA',
9735
9736
 
9736
- define(sessionStatus, 'APP_DATA', 'APP_DATA');
9737
- /**
9738
- * Fires when {@link Session} receives status of sendData operation.
9739
- *
9740
- * @event SEND_DATA_STATUS
9741
- * @memberof Flashphoner.constants.SESSION_STATUS
9742
- */
9737
+ /**
9738
+ * Fires when {@link Session} receives status of sendData operation.
9739
+ *
9740
+ * @event SEND_DATA_STATUS
9741
+ * @memberof Flashphoner.constants.SESSION_STATUS
9742
+ */
9743
+ SEND_DATA_STATUS: 'SEND_DATA_STATUS',
9743
9744
 
9744
- define(sessionStatus, 'SEND_DATA_STATUS', 'SEND_DATA_STATUS'); //State of newly created Session
9745
+ /**
9746
+ * State of newly created {@link Session}.
9747
+ *
9748
+ * @event PENDING
9749
+ * @memberof Flashphoner.constants.SESSION_STATUS
9750
+ */
9751
+ PENDING: 'PENDING',
9745
9752
 
9746
- define(sessionStatus, 'PENDING', 'PENDING');
9747
- /**
9748
- * Fires when {@link Session} registers as sip client.
9749
- *
9750
- * @event APP_DATA
9751
- * @memberof Flashphoner.constants.SESSION_STATUS
9752
- */
9753
+ /**
9754
+ * Fires when {@link Session} registers as sip client.
9755
+ *
9756
+ * @event REGISTERED
9757
+ * @memberof Flashphoner.constants.SESSION_STATUS
9758
+ */
9759
+ REGISTERED: 'REGISTERED',
9753
9760
 
9754
- define(sessionStatus, 'REGISTERED', 'REGISTERED');
9755
- /**
9756
- * Fires when {@link Session} unregisters as sip client.
9757
- *
9758
- * @event APP_DATA
9759
- * @memberof Flashphoner.constants.SESSION_STATUS
9760
- */
9761
+ /**
9762
+ * Fires when {@link Session} unregisters as sip client.
9763
+ *
9764
+ * @event UNREGISTERED
9765
+ * @memberof Flashphoner.constants.SESSION_STATUS
9766
+ */
9767
+ UNREGISTERED: 'UNREGISTERED',
9761
9768
 
9762
- define(sessionStatus, 'UNREGISTERED', 'UNREGISTERED');
9763
- define(sessionStatus, 'INCOMING_CALL', 'INCOMING_CALL');
9769
+ /**
9770
+ * Fires when {@link Session} receives an incoming call.
9771
+ *
9772
+ * @event INCOMING_CALL
9773
+ * @memberof Flashphoner.constants.SESSION_STATUS
9774
+ */
9775
+ INCOMING_CALL: 'INCOMING_CALL'
9776
+ });
9764
9777
  /**
9765
9778
  * @namespace Flashphoner.constants.STREAM_STATUS
9766
9779
  * @see Stream
9767
9780
  */
9768
9781
 
9769
- var streamStatus = {}; //State of newly created Stream
9770
-
9771
- define(streamStatus, 'NEW', 'NEW'); //State between publish/play and server response
9782
+ var STREAM_STATUS = Object.freeze({
9783
+ /**
9784
+ * State of newly created {@link Stream}.
9785
+ *
9786
+ * @event NEW
9787
+ * @memberof Flashphoner.constants.STREAM_STATUS
9788
+ */
9789
+ NEW: 'NEW',
9772
9790
 
9773
- define(streamStatus, 'PENDING', 'PENDING');
9774
- /**
9775
- * Fires when {@link Stream} starts publishing.
9776
- * @event PUBLISHING
9777
- * @memberof Flashphoner.constants.STREAM_STATUS
9778
- */
9791
+ /**
9792
+ * State before {@link Stream} publishing/playing.
9793
+ *
9794
+ * @event PENDING
9795
+ * @memberof Flashphoner.constants.STREAM_STATUS
9796
+ */
9797
+ PENDING: 'PENDING',
9779
9798
 
9780
- define(streamStatus, 'PUBLISHING', 'PUBLISHING');
9781
- /**
9782
- * Fires when {@link Stream} starts playing.
9783
- * @event PLAYING
9784
- * @memberof Flashphoner.constants.STREAM_STATUS
9785
- */
9799
+ /**
9800
+ * Fires when {@link Stream} starts publishing.
9801
+ * @event PUBLISHING
9802
+ * @memberof Flashphoner.constants.STREAM_STATUS
9803
+ */
9804
+ PUBLISHING: 'PUBLISHING',
9786
9805
 
9787
- define(streamStatus, 'PLAYING', 'PLAYING');
9788
- /**
9789
- * Fires if {@link Stream} paused.
9790
- * @event PAUSED
9791
- * @memberof Flashphoner.constants.STREAM_STATUS
9792
- */
9806
+ /**
9807
+ * Fires when {@link Stream} starts playing.
9808
+ * @event PLAYING
9809
+ * @memberof Flashphoner.constants.STREAM_STATUS
9810
+ */
9811
+ PLAYING: 'PLAYING',
9793
9812
 
9794
- define(streamStatus, 'PAUSED', 'PAUSED');
9795
- /**
9796
- * Fires if {@link Stream} was unpublished.
9797
- * @event UNPUBLISHING
9798
- * @memberof Flashphoner.constants.STREAM_STATUS
9799
- */
9813
+ /**
9814
+ * Fires if {@link Stream} paused.
9815
+ * @event PAUSED
9816
+ * @memberof Flashphoner.constants.STREAM_STATUS
9817
+ */
9818
+ PAUSED: 'PAUSED',
9800
9819
 
9801
- define(streamStatus, 'UNPUBLISHED', 'UNPUBLISHED');
9802
- /**
9803
- * Fires if {@link Stream} was stopped.
9804
- * @event STOPPED
9805
- * @memberof Flashphoner.constants.STREAM_STATUS
9806
- */
9820
+ /**
9821
+ * Fires if {@link Stream} was unpublished.
9822
+ * @event UNPUBLISHED
9823
+ * @memberof Flashphoner.constants.STREAM_STATUS
9824
+ */
9825
+ UNPUBLISHED: 'UNPUBLISHED',
9807
9826
 
9808
- define(streamStatus, 'STOPPED', 'STOPPED');
9809
- /**
9810
- * Fires if {@link Stream} failed.
9811
- * @event FAILED
9812
- * @memberof Flashphoner.constants.STREAM_STATUS
9813
- */
9827
+ /**
9828
+ * Fires if playing {@link Stream} was stopped.
9829
+ * @event STOPPED
9830
+ * @memberof Flashphoner.constants.STREAM_STATUS
9831
+ */
9832
+ STOPPED: 'STOPPED',
9814
9833
 
9815
- define(streamStatus, 'FAILED', 'FAILED');
9816
- /**
9817
- * Fires if {@link Stream} playback problem.
9818
- * @event PLAYBACK_PROBLEM
9819
- * @memberof Flashphoner.constants.STREAM_STATUS
9820
- */
9834
+ /**
9835
+ * Fires if {@link Stream} failed.
9836
+ * @event FAILED
9837
+ * @memberof Flashphoner.constants.STREAM_STATUS
9838
+ */
9839
+ FAILED: 'FAILED',
9821
9840
 
9822
- define(streamStatus, 'PLAYBACK_PROBLEM', 'PLAYBACK_PROBLEM');
9823
- /**
9824
- * Fires if {@link Stream} resize.
9825
- * @event RESIZE
9826
- * @memberof Flashphoner.constants.STREAM_STATUS
9827
- */
9841
+ /**
9842
+ * Fires if {@link Stream} playback problem.
9843
+ * @event PLAYBACK_PROBLEM
9844
+ * @memberof Flashphoner.constants.STREAM_STATUS
9845
+ */
9846
+ PLAYBACK_PROBLEM: 'PLAYBACK_PROBLEM',
9828
9847
 
9829
- define(streamStatus, 'RESIZE', 'RESIZE');
9830
- /**
9831
- * Fires when {@link Stream} snapshot becomes available.
9832
- * Snapshot is base64 encoded png available through {@link Stream.getInfo}
9833
- * @event SNAPSHOT_COMPLETE
9834
- * @memberof Flashphoner.constants.STREAM_STATUS
9835
- */
9848
+ /**
9849
+ * Fires if playing {@link Stream} picture resizing.
9850
+ * @event RESIZE
9851
+ * @memberof Flashphoner.constants.STREAM_STATUS
9852
+ */
9853
+ RESIZE: 'RESIZE',
9836
9854
 
9837
- define(streamStatus, 'SNAPSHOT_COMPLETE', 'SNAPSHOT_COMPLETE');
9838
- /**
9839
- * Fires on subscribe {@link Stream} if bitrate is higher than available network bandwidth.
9840
- * @event NOT_ENOUGH_BANDWIDTH
9841
- * @memberof Flashphoner.constants.NOT_ENOUGH_BANDWIDTH
9842
- */
9855
+ /**
9856
+ * Fires when {@link Stream} snapshot becomes available.
9857
+ * Snapshot is base64 encoded png available through {@link Stream.getInfo}
9858
+ * @event SNAPSHOT_COMPLETE
9859
+ * @memberof Flashphoner.constants.STREAM_STATUS
9860
+ */
9861
+ SNAPSHOT_COMPLETE: 'SNAPSHOT_COMPLETE',
9843
9862
 
9844
- define(streamStatus, 'NOT_ENOUGH_BANDWIDTH', 'NOT_ENOUGH_BANDWIDTH');
9863
+ /**
9864
+ * Fires on playing {@link Stream} if bitrate is higher than available network bandwidth.
9865
+ * @event NOT_ENOUGH_BANDWIDTH
9866
+ * @memberof Flashphoner.constants.NOT_ENOUGH_BANDWIDTH
9867
+ */
9868
+ NOT_ENOUGH_BANDWIDTH: 'NOT_ENOUGH_BANDWIDTH'
9869
+ });
9845
9870
  /**
9846
9871
  * @namespace Flashphoner.constants.CALL_STATUS
9847
9872
  * @see Call
9848
9873
  */
9849
9874
 
9850
- var callStatus = {}; //State of newly created Call
9851
-
9852
- define(callStatus, 'NEW', 'NEW');
9853
- define(callStatus, 'RING', 'RING');
9854
- define(callStatus, 'RING_MEDIA', 'RING_MEDIA');
9855
- define(callStatus, 'HOLD', 'HOLD');
9856
- define(callStatus, 'ESTABLISHED', 'ESTABLISHED');
9857
- define(callStatus, 'FINISH', 'FINISH');
9858
- define(callStatus, 'BUSY', 'BUSY');
9859
- define(callStatus, 'SESSION_PROGRESS', 'SESSION_PROGRESS');
9860
- define(callStatus, 'FAILED', 'FAILED');
9861
- define(callStatus, 'PENDING', 'PENDING');
9862
- define(callStatus, 'TRYING', 'TRYING');
9875
+ var CALL_STATUS = Object.freeze({
9876
+ /**
9877
+ * State of newly created {@link Call}
9878
+ * @event NEW
9879
+ * @memberof Flashphoner.constants.CALL_STATUS
9880
+ */
9881
+ NEW: 'NEW',
9882
+
9883
+ /**
9884
+ * The server is ringing to the callee
9885
+ * @event RING
9886
+ * @memberof Flashphoner.constants.CALL_STATUS
9887
+ */
9888
+ RING: 'RING',
9889
+ RING_MEDIA: 'RING_MEDIA',
9890
+
9891
+ /**
9892
+ * The {@link Call} was put on hold
9893
+ * @event HOLD
9894
+ * @memberof Flashphoner.constants.CALL_STATUS
9895
+ */
9896
+ HOLD: 'HOLD',
9897
+
9898
+ /**
9899
+ * The {@link Call} is established
9900
+ * @event ESTABLISHED
9901
+ * @memberof Flashphoner.constants.CALL_STATUS
9902
+ */
9903
+ ESTABLISHED: 'ESTABLISHED',
9904
+
9905
+ /**
9906
+ * The {@link Call} is finished
9907
+ * @event FINISH
9908
+ * @memberof Flashphoner.constants.CALL_STATUS
9909
+ */
9910
+ FINISH: 'FINISH',
9911
+
9912
+ /**
9913
+ * Callee is busy
9914
+ * @event BUSY
9915
+ * @memberof Flashphoner.constants.CALL_STATUS
9916
+ */
9917
+ BUSY: 'BUSY',
9918
+
9919
+ /**
9920
+ * SIP session is in progress
9921
+ * @event SESSION_PROGRESS
9922
+ * @memberof Flashphoner.constants.CALL_STATUS
9923
+ */
9924
+ SESSION_PROGRESS: 'SESSION_PROGRESS',
9925
+
9926
+ /**
9927
+ * The {@link Call} is failed
9928
+ * @event FAILED
9929
+ * @memberof Flashphoner.constants.CALL_STATUS
9930
+ */
9931
+ FAILED: 'FAILED',
9932
+
9933
+ /**
9934
+ * The {@link Call} state before ringing
9935
+ * @event PENDING
9936
+ * @memberof Flashphoner.constants.CALL_STATUS
9937
+ */
9938
+ PENDING: 'PENDING',
9939
+
9940
+ /**
9941
+ * The server trying to establish {@link Call}
9942
+ * @event TRYING
9943
+ * @memberof Flashphoner.constants.CALL_STATUS
9944
+ */
9945
+ TRYING: 'TRYING'
9946
+ });
9863
9947
  /**
9864
9948
  * @namespace Flashphoner.constants.STREAM_STATUS_INFO
9865
9949
  * @see Stream
9866
9950
  */
9867
9951
 
9868
- var streamStatusInfo = {};
9869
- /**
9870
- * Indicates general error during ICE negotiation. Usually occurs if client is behind some exotic nat/firewall.
9871
- * @event FAILED_BY_ICE_ERROR
9872
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9873
- */
9874
-
9875
- define(streamStatusInfo, 'FAILED_BY_ICE_ERROR', 'Failed by ICE error');
9876
- /**
9877
- * Timeout has been reached during ICE establishment.
9878
- * @event FAILED_BY_ICE_TIMEOUT
9879
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9880
- */
9952
+ var STREAM_STATUS_INFO = Object.freeze({
9953
+ /**
9954
+ * Indicates general error during ICE negotiation. Usually occurs if client is behind some exotic nat/firewall.
9955
+ * @event FAILED_BY_ICE_ERROR
9956
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9957
+ */
9958
+ FAILED_BY_ICE_ERROR: 'Failed by ICE error',
9881
9959
 
9882
- define(streamStatusInfo, 'FAILED_BY_ICE_TIMEOUT', 'Failed by ICE timeout');
9883
- /**
9884
- * ICE refresh failed on session.
9885
- * @event FAILED_BY_KEEP_ALIVE
9886
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9887
- */
9960
+ /**
9961
+ * Timeout has been reached during ICE establishment.
9962
+ * @event FAILED_BY_ICE_TIMEOUT
9963
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9964
+ */
9965
+ FAILED_BY_ICE_TIMEOUT: 'Failed by ICE timeout',
9888
9966
 
9889
- define(streamStatusInfo, 'FAILED_BY_KEEP_ALIVE', 'Failed by ICE keep alive');
9890
- /**
9891
- * DTLS has wrong fingerprint.
9892
- * @event FAILED_BY_DTLS_FINGERPRINT_ERROR
9893
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9894
- */
9967
+ /**
9968
+ * ICE refresh failed on session.
9969
+ * @event FAILED_BY_KEEP_ALIVE
9970
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9971
+ */
9972
+ FAILED_BY_KEEP_ALIVE: 'Failed by ICE keep alive',
9895
9973
 
9896
- define(streamStatusInfo, 'FAILED_BY_DTLS_FINGERPRINT_ERROR', 'Failed by DTLS fingerprint error');
9897
- /**
9898
- * Client did not send DTLS packets or packets were lost/corrupted during transmission.
9899
- * @event FAILED_BY_DTLS_ERROR
9900
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9901
- */
9974
+ /**
9975
+ * DTLS has wrong fingerprint.
9976
+ * @event FAILED_BY_DTLS_FINGERPRINT_ERROR
9977
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9978
+ */
9979
+ FAILED_BY_DTLS_FINGERPRINT_ERROR: 'Failed by DTLS fingerprint error',
9902
9980
 
9903
- define(streamStatusInfo, 'FAILED_BY_DTLS_ERROR', 'Failed by DTLS error');
9904
- /**
9905
- * Indicates general HLS packetizer error, can occur during initialization or packetization (wrong input or out of disk space).
9906
- * @event FAILED_BY_HLS_WRITER_ERROR
9907
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9908
- */
9981
+ /**
9982
+ * Client did not send DTLS packets or packets were lost/corrupted during transmission.
9983
+ * @event FAILED_BY_DTLS_ERROR
9984
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9985
+ */
9986
+ FAILED_BY_DTLS_ERROR: 'Failed by DTLS error',
9909
9987
 
9910
- define(streamStatusInfo, 'FAILED_BY_HLS_WRITER_ERROR', 'Failed by HLS writer error');
9911
- /**
9912
- * Indicates general RTMP republishing error, can occur during initialization or rtmp packetization.
9913
- * @event FAILED_BY_RTMP_WRITER_ERROR
9914
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9915
- */
9988
+ /**
9989
+ * Indicates general HLS packetizer error, can occur during initialization or packetization (wrong input or out of disk space).
9990
+ * @event FAILED_BY_HLS_WRITER_ERROR
9991
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9992
+ */
9993
+ FAILED_BY_HLS_WRITER_ERROR: 'Failed by HLS writer error',
9916
9994
 
9917
- define(streamStatusInfo, 'FAILED_BY_RTMP_WRITER_ERROR', 'Failed by RTMP writer error');
9918
- /**
9919
- * RTP session failed by RTP activity timer.
9920
- * @event FAILED_BY_RTP_ACTIVITY
9921
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9922
- */
9995
+ /**
9996
+ * Indicates general RTMP republishing error, can occur during initialization or rtmp packetization.
9997
+ * @event FAILED_BY_RTMP_WRITER_ERROR
9998
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9999
+ */
10000
+ FAILED_BY_RTMP_WRITER_ERROR: 'Failed by RTMP writer error',
9923
10001
 
9924
- define(streamStatusInfo, 'FAILED_BY_RTP_ACTIVITY', 'Failed by RTP activity');
9925
- /**
9926
- * Related session was disconnected.
9927
- * @event STOPPED_BY_SESSION_DISCONNECT
9928
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9929
- */
10002
+ /**
10003
+ * RTP session failed by RTP activity timer.
10004
+ * @event FAILED_BY_RTP_ACTIVITY
10005
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10006
+ */
10007
+ FAILED_BY_RTP_ACTIVITY: 'Failed by RTP activity',
9930
10008
 
9931
- define(streamStatusInfo, 'STOPPED_BY_SESSION_DISCONNECT', 'Stopped by session disconnect');
9932
- /**
9933
- * Stream was stopped by rest terminate request.
9934
- * @event STOPPED_BY_REST_TERMINATE
9935
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9936
- */
10009
+ /**
10010
+ * Related session was disconnected.
10011
+ * @event STOPPED_BY_SESSION_DISCONNECT
10012
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10013
+ */
10014
+ STOPPED_BY_SESSION_DISCONNECT: 'Stopped by session disconnect',
9937
10015
 
9938
- define(streamStatusInfo, 'STOPPED_BY_REST_TERMINATE', 'Stopped by rest /terminate');
9939
- /**
9940
- * Related publisher stopped its stream or lost connection.
9941
- * @event STOPPED_BY_PUBLISHER_STOP
9942
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9943
- */
10016
+ /**
10017
+ * Stream was stopped by rest terminate request.
10018
+ * @event STOPPED_BY_REST_TERMINATE
10019
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10020
+ */
10021
+ STOPPED_BY_REST_TERMINATE: 'Stopped by rest /terminate',
9944
10022
 
9945
- define(streamStatusInfo, 'STOPPED_BY_PUBLISHER_STOP', 'Stopped by publisher stop');
9946
- /**
9947
- * Stop the media session by user after call was finished or unpublish stream.
9948
- * @event STOPPED_BY_USER
9949
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9950
- */
10023
+ /**
10024
+ * Related publisher stopped its stream or lost connection.
10025
+ * @event STOPPED_BY_PUBLISHER_STOP
10026
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10027
+ */
10028
+ STOPPED_BY_PUBLISHER_STOP: 'Stopped by publisher stop',
9951
10029
 
9952
- define(streamStatusInfo, 'STOPPED_BY_USER', 'Stopped by user');
9953
- /**
9954
- * Error occurred on the stream.
9955
- * @event FAILED_BY_ERROR
9956
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9957
- */
10030
+ /**
10031
+ * Stop the media session by user after call was finished or unpublish stream.
10032
+ * @event STOPPED_BY_USER
10033
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10034
+ */
10035
+ STOPPED_BY_USER: 'Stopped by user',
9958
10036
 
9959
- define(streamStatusInfo, 'FAILED_BY_ERROR', 'Failed by error');
9960
- /**
9961
- * Indicates that error occurred during media session creation. This might be SDP parsing error, all ports are busy, wrong session related config etc.
9962
- * @event FAILED_TO_ADD_STREAM_TO_PROXY
9963
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9964
- */
10037
+ /**
10038
+ * Error occurred on the stream.
10039
+ * @event FAILED_BY_ERROR
10040
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10041
+ */
10042
+ FAILED_BY_ERROR: 'Failed by error',
9965
10043
 
9966
- define(streamStatusInfo, 'FAILED_TO_ADD_STREAM_TO_PROXY', 'Failed to add stream to proxy');
9967
- /**
9968
- * Stopped shapshot distributor.
9969
- * @event DISTRIBUTOR_STOPPED
9970
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9971
- */
10044
+ /**
10045
+ * Indicates that error occurred during media session creation. This might be SDP parsing error, all ports are busy, wrong session related config etc.
10046
+ * @event FAILED_TO_ADD_STREAM_TO_PROXY
10047
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10048
+ */
10049
+ FAILED_TO_ADD_STREAM_TO_PROXY: 'Failed to add stream to proxy',
9972
10050
 
9973
- define(streamStatusInfo, 'DISTRIBUTOR_STOPPED', 'Distributor stopped');
9974
- /**
9975
- * Publish stream is not ready, try again later.
9976
- * @event PUBLISH_STREAM_IS_NOT_READY
9977
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9978
- */
10051
+ /**
10052
+ * Stopped shapshot distributor.
10053
+ * @event DISTRIBUTOR_STOPPED
10054
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10055
+ */
10056
+ DISTRIBUTOR_STOPPED: 'Distributor stopped',
9979
10057
 
9980
- define(streamStatusInfo, 'PUBLISH_STREAM_IS_NOT_READY', 'Publish stream is not ready');
9981
- /**
9982
- * Stream with this name is not found, check the correct of the name.
9983
- * @event STREAM_NOT_FOUND
9984
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9985
- */
10058
+ /**
10059
+ * Publish stream is not ready, try again later.
10060
+ * @event PUBLISH_STREAM_IS_NOT_READY
10061
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10062
+ */
10063
+ PUBLISH_STREAM_IS_NOT_READY: 'Publish stream is not ready',
9986
10064
 
9987
- define(streamStatusInfo, 'STREAM_NOT_FOUND', 'Stream not found');
9988
- /**
9989
- * Server already has a publish stream with the same name, try using different one.
9990
- * @event STREAM_NAME_ALREADY_IN_USE
9991
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9992
- */
10065
+ /**
10066
+ * Stream with this name is not found, check the correct of the name.
10067
+ * @event STREAM_NOT_FOUND
10068
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10069
+ */
10070
+ STREAM_NOT_FOUND: 'Stream not found',
9993
10071
 
9994
- define(streamStatusInfo, 'STREAM_NAME_ALREADY_IN_USE', 'Stream name is already in use');
9995
- /**
9996
- * Error indicates that stream object received by server has empty mediaSessionId field.
9997
- * @event MEDIASESSION_ID_NULL
9998
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
9999
- */
10072
+ /**
10073
+ * Server already has a publish stream with the same name, try using different one.
10074
+ * @event STREAM_NAME_ALREADY_IN_USE
10075
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10076
+ */
10077
+ STREAM_NAME_ALREADY_IN_USE: 'Stream name is already in use',
10000
10078
 
10001
- define(streamStatusInfo, 'MEDIASESSION_ID_NULL', 'MediaSessionId is null');
10002
- /**
10003
- * Published or subscribed sessions used this MediaSessionId.
10004
- * @event MEDIASESSION_ID_ALREADY_IN_USE
10005
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10006
- */
10079
+ /**
10080
+ * Error indicates that stream object received by server has empty mediaSessionId field.
10081
+ * @event MEDIASESSION_ID_NULL
10082
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10083
+ */
10084
+ MEDIASESSION_ID_NULL: 'MediaSessionId is null',
10007
10085
 
10008
- define(streamStatusInfo, 'MEDIASESSION_ID_ALREADY_IN_USE', 'MediaSessionId is already in use');
10009
- /**
10010
- * Session is not initialized or terminated on play ordinary stream.
10011
- * @event SESSION_NOT_READY
10012
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10013
- */
10086
+ /**
10087
+ * Published or subscribed sessions used this MediaSessionId.
10088
+ * @event MEDIASESSION_ID_ALREADY_IN_USE
10089
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10090
+ */
10091
+ MEDIASESSION_ID_ALREADY_IN_USE: 'MediaSessionId is already in use',
10014
10092
 
10015
- define(streamStatusInfo, 'SESSION_NOT_READY', 'Session not ready');
10016
- /**
10017
- * Actual session does not exist.
10018
- * @event SESSION_DOES_NOT_EXIST
10019
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10020
- */
10093
+ /**
10094
+ * Session is not initialized or terminated on play ordinary stream.
10095
+ * @event SESSION_NOT_READY
10096
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10097
+ */
10098
+ SESSION_NOT_READY: 'Session not ready',
10021
10099
 
10022
- define(streamStatusInfo, 'SESSION_DOES_NOT_EXIST', 'Session does not exist');
10023
- /**
10024
- * RTSP has wrong format on play stream, check correct of the RTSP url.
10025
- * @event RTSP_HAS_WRONG_FORMAT
10026
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10027
- */
10100
+ /**
10101
+ * Actual session does not exist.
10102
+ * @event SESSION_DOES_NOT_EXIST
10103
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10104
+ */
10105
+ SESSION_DOES_NOT_EXIST: 'Session does not exist',
10028
10106
 
10029
- define(streamStatusInfo, 'RTSP_HAS_WRONG_FORMAT', 'Rtsp has wrong format');
10030
- /**
10031
- * Failed to play vod stream, this format is not supported.
10032
- * @event FILE_HAS_WRONG_FORMAT
10033
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10034
- */
10107
+ /**
10108
+ * RTSP has wrong format on play stream, check the RTSP url validity.
10109
+ * @event RTSP_HAS_WRONG_FORMAT
10110
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10111
+ */
10112
+ RTSP_HAS_WRONG_FORMAT: 'Rtsp has wrong format',
10035
10113
 
10036
- define(streamStatusInfo, 'FILE_HAS_WRONG_FORMAT', 'File has wrong format');
10037
- /**
10038
- * Failed to connect to rtsp stream.
10039
- * @event FAILED_TO_CONNECT_TO_RTSP_STREAM
10040
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10041
- */
10114
+ /**
10115
+ * Failed to play vod stream, this format is not supported.
10116
+ * @event FILE_HAS_WRONG_FORMAT
10117
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10118
+ */
10119
+ FILE_HAS_WRONG_FORMAT: 'File has wrong format',
10042
10120
 
10043
- define(streamStatusInfo, 'FAILED_TO_CONNECT_TO_RTSP_STREAM', 'Failed to connect to rtsp stream');
10044
- /**
10045
- * Rtsp stream is not found, agent received "404-Not Found".
10046
- * @event RTSP_STREAM_NOT_FOUND
10047
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10048
- */
10121
+ /**
10122
+ * Failed to connect to rtsp stream.
10123
+ * @event FAILED_TO_CONNECT_TO_RTSP_STREAM
10124
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10125
+ */
10126
+ FAILED_TO_CONNECT_TO_RTSP_STREAM: 'Failed to connect to rtsp stream',
10049
10127
 
10050
- define(streamStatusInfo, 'RTSP_STREAM_NOT_FOUND', 'Rtsp stream not found');
10051
- /**
10052
- * On shutdown RTSP agent.
10053
- * @event RTSPAGENT_SHUTDOWN
10054
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10055
- */
10128
+ /**
10129
+ * Rtsp stream is not found, agent received "404-Not Found".
10130
+ * @event RTSP_STREAM_NOT_FOUND
10131
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10132
+ */
10133
+ RTSP_STREAM_NOT_FOUND: 'Rtsp stream not found',
10056
10134
 
10057
- define(streamStatusInfo, 'RTSPAGENT_SHUTDOWN', 'RtspAgent shutdown');
10058
- /**
10059
- * Stream failed
10060
- * @event STREAM_FAILED
10061
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10062
- */
10135
+ /**
10136
+ * On shutdown RTSP agent.
10137
+ * @event RTSPAGENT_SHUTDOWN
10138
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10139
+ */
10140
+ RTSPAGENT_SHUTDOWN: 'RtspAgent shutdown',
10063
10141
 
10064
- define(streamStatusInfo, 'STREAM_FAILED', 'Stream failed');
10065
- /**
10066
- * No common codecs on setup track, did not found corresponding trackId->mediaPort.
10067
- * @event NO_COMMON_CODECS
10068
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10069
- */
10142
+ /**
10143
+ * Stream failed
10144
+ * @event STREAM_FAILED
10145
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10146
+ */
10147
+ STREAM_FAILED: 'Stream failed',
10070
10148
 
10071
- define(streamStatusInfo, 'NO_COMMON_CODECS', 'No common codecs');
10072
- /**
10073
- * Bad referenced rtsp link, check for correct, example: rtsp://user:b@d_password@127.0.0.1/stream.
10074
- * @event BAD_URI
10075
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10076
- */
10149
+ /**
10150
+ * No common codecs on setup track, did not found corresponding trackId->mediaPort.
10151
+ * @event NO_COMMON_CODECS
10152
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10153
+ */
10154
+ NO_COMMON_CODECS: 'No common codecs',
10077
10155
 
10078
- define(streamStatusInfo, 'BAD_URI', 'Bad URI');
10079
- /**
10080
- * General VOD error, indicates that Exception occurred while reading/processing media file.
10081
- * @event GOT_EXCEPTION_WHILE_STREAMING_FILE
10082
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10083
- */
10156
+ /**
10157
+ * Bad referenced rtsp link, check for correct, example: rtsp://user:b@d_password@127.0.0.1/stream.
10158
+ * @event BAD_URI
10159
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10160
+ */
10161
+ BAD_URI: 'Bad URI',
10084
10162
 
10085
- define(streamStatusInfo, 'GOT_EXCEPTION_WHILE_STREAMING_FILE', 'Got exception while streaming file');
10086
- /**
10087
- * Requested stream shutdown.
10088
- * @event REQUESTED_STREAM_SHUTDOWN
10089
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10090
- */
10163
+ /**
10164
+ * General VOD error, indicates that Exception occurred while reading/processing media file.
10165
+ * @event GOT_EXCEPTION_WHILE_STREAMING_FILE
10166
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10167
+ */
10168
+ GOT_EXCEPTION_WHILE_STREAMING_FILE: 'Got exception while streaming file',
10091
10169
 
10092
- define(streamStatusInfo, 'REQUESTED_STREAM_SHUTDOWN', 'Requested stream shutdown');
10093
- /**
10094
- * Failed to create movie, file can not be read.
10095
- * @event FAILED_TO_READ_FILE
10096
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10097
- */
10170
+ /**
10171
+ * Requested stream shutdown.
10172
+ * @event REQUESTED_STREAM_SHUTDOWN
10173
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10174
+ */
10175
+ REQUESTED_STREAM_SHUTDOWN: 'Requested stream shutdown',
10098
10176
 
10099
- define(streamStatusInfo, 'FAILED_TO_READ_FILE', 'Failed to read file');
10100
- /**
10101
- * File does not exist, check filename.
10102
- * @event FILE_NOT_FOUND
10103
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10104
- */
10177
+ /**
10178
+ * Failed to create movie, file can not be read.
10179
+ * @event FAILED_TO_READ_FILE
10180
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10181
+ */
10182
+ FAILED_TO_READ_FILE: 'Failed to read file',
10105
10183
 
10106
- define(streamStatusInfo, 'FILE_NOT_FOUND', 'File not found');
10107
- /**
10108
- * Server failed to establish websocket connection with origin server.
10109
- * @event FAILED_TO_CONNECT_TO_ORIGIN_STREAM
10110
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10111
- */
10184
+ /**
10185
+ * File does not exist, check filename.
10186
+ * @event FILE_NOT_FOUND
10187
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10188
+ */
10189
+ FILE_NOT_FOUND: 'File not found',
10112
10190
 
10113
- define(streamStatusInfo, 'FAILED_TO_CONNECT_TO_ORIGIN_STREAM', 'Failed to connect to origin stream');
10114
- /**
10115
- * CDN stream not found.
10116
- * @event CDN_STREAM_NOT_FOUND
10117
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10118
- */
10191
+ /**
10192
+ * Server failed to establish websocket connection with origin server.
10193
+ * @event FAILED_TO_CONNECT_TO_ORIGIN_STREAM
10194
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10195
+ */
10196
+ FAILED_TO_CONNECT_TO_ORIGIN_STREAM: 'Failed to connect to origin stream',
10119
10197
 
10120
- define(streamStatusInfo, 'CDN_STREAM_NOT_FOUND', 'CDN stream not found');
10121
- /**
10122
- * Indicates that provided URL protocol in stream name is invalid.
10123
- * Valid: vod://file.mp4
10124
- * Invalid: dov://file.mp4
10125
- * @event FAILED_TO_GET_AGENT_STORAGE
10126
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10127
- */
10198
+ /**
10199
+ * CDN stream not found.
10200
+ * @event CDN_STREAM_NOT_FOUND
10201
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10202
+ */
10203
+ CDN_STREAM_NOT_FOUND: 'CDN stream not found',
10128
10204
 
10129
- define(streamStatusInfo, 'FAILED_TO_GET_AGENT_STORAGE', 'Failed to get agent storage');
10130
- /**
10131
- * Shutdown agent servicing origin stream.
10132
- * @event AGENT_SERVICING_ORIGIN_STREAM_IS_SHUTTING_DOWN
10133
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10134
- */
10205
+ /**
10206
+ * Indicates that provided URL protocol in stream name is invalid.
10207
+ * Valid: vod://file.mp4
10208
+ * Invalid: dov://file.mp4
10209
+ * @event FAILED_TO_GET_AGENT_STORAGE
10210
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10211
+ */
10212
+ FAILED_TO_GET_AGENT_STORAGE: 'Failed to get agent storage',
10135
10213
 
10136
- define(streamStatusInfo, 'AGENT_SERVICING_ORIGIN_STREAM_IS_SHUTTING_DOWN', 'Agent servicing origin stream is shutting down');
10137
- /**
10138
- * Terminated by keep-alive on walk through subscribers.
10139
- * @event TERMINATED_BY_KEEP_ALIVE
10140
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10141
- */
10214
+ /**
10215
+ * Shutdown agent servicing origin stream.
10216
+ * @event AGENT_SERVICING_ORIGIN_STREAM_IS_SHUTTING_DOWN
10217
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10218
+ */
10219
+ AGENT_SERVICING_ORIGIN_STREAM_IS_SHUTTING_DOWN: 'Agent servicing origin stream is shutting down',
10142
10220
 
10143
- define(streamStatusInfo, 'TERMINATED_BY_KEEP_ALIVE', 'Terminated by keep-alive');
10144
- /**
10145
- * Transcoding required, but disabled in settings
10146
- * @event TRANSCODING_REQUIRED_BUT_DISABLED
10147
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10148
- */
10221
+ /**
10222
+ * Terminated by keep-alive on walk through subscribers.
10223
+ * @event TERMINATED_BY_KEEP_ALIVE
10224
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10225
+ */
10226
+ TERMINATED_BY_KEEP_ALIVE: 'Terminated by keep-alive',
10149
10227
 
10150
- define(streamStatusInfo, 'TRANSCODING_REQUIRED_BUT_DISABLED', 'Transcoding required, but disabled');
10151
- /**
10152
- * Access restricted by access list
10153
- * @event RESTRICTED_ACCESS
10154
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10155
- */
10228
+ /**
10229
+ * Transcoding required, but disabled in server settings
10230
+ * @event TRANSCODING_REQUIRED_BUT_DISABLED
10231
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10232
+ */
10233
+ TRANSCODING_REQUIRED_BUT_DISABLED: 'Transcoding required, but disabled',
10156
10234
 
10157
- define(streamStatusInfo, 'RESTRICTED_ACCESS', 'Restricted access');
10158
- /**
10159
- * No available transcoders for stream
10160
- * @event RESTRICTED_ACCESS
10161
- * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10162
- */
10235
+ /**
10236
+ * Access restricted by access list
10237
+ * @event RESTRICTED_ACCESS
10238
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10239
+ */
10240
+ RESTRICTED_ACCESS: 'Restricted access',
10163
10241
 
10164
- define(streamStatusInfo, 'NO_AVAILABLE_TRANSCODERS', 'No available transcoders');
10242
+ /**
10243
+ * No available transcoders for stream
10244
+ * @event NO_AVAILABLE_TRANSCODERS
10245
+ * @memberof Flashphoner.constants.STREAM_STATUS_INFO
10246
+ */
10247
+ NO_AVAILABLE_TRANSCODERS: 'No available transcoders'
10248
+ });
10165
10249
  /**
10166
10250
  * @namespace Flashphoner.constants.CALL_STATUS_INFO
10167
10251
  * @see Call
10168
10252
  */
10169
10253
 
10170
- var callStatusInfo = {};
10171
- /**
10172
- * Normal call hangup.
10173
- * @event NORMAL_CALL_CLEARING
10174
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10175
- */
10176
-
10177
- define(callStatusInfo, 'NORMAL_CALL_CLEARING', 'Normal call clearing');
10178
- /**
10179
- * Error occurred on session creation.
10180
- * @event FAILED_BY_SESSION_CREATION
10181
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10182
- */
10254
+ var CALL_STATUS_INFO = Object.freeze({
10255
+ /**
10256
+ * Normal call hangup.
10257
+ * @event NORMAL_CALL_CLEARING
10258
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10259
+ */
10260
+ NORMAL_CALL_CLEARING: 'Normal call clearing',
10183
10261
 
10184
- define(callStatusInfo, 'FAILED_BY_SESSION_CREATION', 'Failed by session creation');
10185
- /**
10186
- * Failed by error during ICE establishment.
10187
- * @event FAILED_BY_ICE_ERROR
10188
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10189
- */
10262
+ /**
10263
+ * Error occurred while creating a session
10264
+ * @event FAILED_BY_SESSION_CREATION
10265
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10266
+ */
10267
+ FAILED_BY_SESSION_CREATION: 'Failed by session creation',
10190
10268
 
10191
- define(callStatusInfo, 'FAILED_BY_ICE_ERROR', 'Failed by ICE error');
10192
- /**
10193
- * RTP session failed by RTP activity timer.
10194
- * @event FAILED_BY_RTP_ACTIVITY
10195
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10196
- */
10269
+ /**
10270
+ * Failed by error during ICE establishment.
10271
+ * @event FAILED_BY_ICE_ERROR
10272
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10273
+ */
10274
+ FAILED_BY_ICE_ERROR: 'Failed by ICE error',
10197
10275
 
10198
- define(callStatusInfo, 'FAILED_BY_RTP_ACTIVITY', 'Failed by RTP activity');
10199
- /**
10200
- * FF writer was failed on RTMP.
10201
- * @event FAILED_BY_RTMP_WRITER_ERROR
10202
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10203
- */
10276
+ /**
10277
+ * RTP session failed by RTP activity timer.
10278
+ * @event FAILED_BY_RTP_ACTIVITY
10279
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10280
+ */
10281
+ FAILED_BY_RTP_ACTIVITY: 'Failed by RTP activity',
10204
10282
 
10205
- define(callStatusInfo, 'FAILED_BY_RTMP_WRITER_ERROR', 'Failed by RTMP writer error');
10206
- /**
10207
- * DTLS wrong fingerprint.
10208
- * @event FAILED_BY_DTLS_FINGERPRINT_ERROR
10209
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10210
- */
10283
+ /**
10284
+ * FF writer was failed on RTMP.
10285
+ * @event FAILED_BY_RTMP_WRITER_ERROR
10286
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10287
+ */
10288
+ FAILED_BY_RTMP_WRITER_ERROR: 'Failed by RTMP writer error',
10211
10289
 
10212
- define(callStatusInfo, 'FAILED_BY_DTLS_FINGERPRINT_ERROR', 'Failed by DTLS fingerprint error');
10213
- /**
10214
- * No common codecs in sdp
10215
- * @event NO_COMMON_CODECS
10216
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10217
- */
10290
+ /**
10291
+ * DTLS wrong fingerprint.
10292
+ * @event FAILED_BY_DTLS_FINGERPRINT_ERROR
10293
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10294
+ */
10295
+ FAILED_BY_DTLS_FINGERPRINT_ERROR: 'Failed by DTLS fingerprint error',
10218
10296
 
10219
- define(callStatusInfo, 'NO_COMMON_CODECS', 'No common codecs');
10220
- /**
10221
- * Client did not send DTLS packets or packets were lost/corrupted during transmission.
10222
- * @event FAILED_BY_DTLS_ERROR
10223
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10224
- */
10297
+ /**
10298
+ * No common codecs in sdp
10299
+ * @event NO_COMMON_CODECS
10300
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10301
+ */
10302
+ NO_COMMON_CODECS: 'No common codecs',
10225
10303
 
10226
- define(callStatusInfo, 'FAILED_BY_DTLS_ERROR', 'Failed by DTLS error');
10227
- /**
10228
- * Error occurred during call
10229
- * @event FAILED_BY_ERROR
10230
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10231
- */
10304
+ /**
10305
+ * Client did not send DTLS packets or packets were lost/corrupted during transmission.
10306
+ * @event FAILED_BY_DTLS_ERROR
10307
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10308
+ */
10309
+ FAILED_BY_DTLS_ERROR: 'Failed by DTLS error',
10232
10310
 
10233
- define(callStatusInfo, 'FAILED_BY_ERROR', 'Failed by error');
10234
- /**
10235
- * Call failed by request timeout
10236
- * @event FAILED_BY_REQUEST_TIMEOUT
10237
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10238
- */
10311
+ /**
10312
+ * Error occurred during the call
10313
+ * @event FAILED_BY_ERROR
10314
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10315
+ */
10316
+ FAILED_BY_ERROR: 'Failed by error',
10239
10317
 
10240
- define(callStatusInfo, 'FAILED_BY_REQUEST_TIMEOUT', 'Failed by request timeout');
10241
- /**
10242
- * Transcoding required, but disabled in settings
10243
- * @event TRANSCODING_REQUIRED_BUT_DISABLED
10244
- * @memberof Flashphoner.constants.CALL_STATUS_INFO
10245
- */
10318
+ /**
10319
+ * Call failed by request timeout
10320
+ * @event FAILED_BY_REQUEST_TIMEOUT
10321
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10322
+ */
10323
+ FAILED_BY_REQUEST_TIMEOUT: 'Failed by request timeout',
10246
10324
 
10247
- define(callStatusInfo, 'TRANSCODING_REQUIRED_BUT_DISABLED', 'Transcoding required, but disabled');
10325
+ /**
10326
+ * Transcoding required, but disabled in settings
10327
+ * @event TRANSCODING_REQUIRED_BUT_DISABLED
10328
+ * @memberof Flashphoner.constants.CALL_STATUS_INFO
10329
+ */
10330
+ TRANSCODING_REQUIRED_BUT_DISABLED: 'Transcoding required, but disabled'
10331
+ });
10248
10332
  /**
10249
10333
  * @namespace Flashphoner.constants.ERROR_INFO
10250
10334
  */
10251
10335
 
10252
- var errorInfo = {};
10253
- /**
10254
- * Error if none of MediaProviders available
10255
- * @event NONE_OF_MEDIAPROVIDERS_AVAILABLE
10256
- * @memberof Flashphoner.constants.ERROR_INFO
10257
- */
10336
+ var ERROR_INFO = Object.freeze({
10337
+ /**
10338
+ * Error if none of MediaProviders available
10339
+ * @event NONE_OF_MEDIAPROVIDERS_AVAILABLE
10340
+ * @memberof Flashphoner.constants.ERROR_INFO
10341
+ */
10342
+ NONE_OF_MEDIAPROVIDERS_AVAILABLE: 'None of MediaProviders available',
10258
10343
 
10259
- define(errorInfo, 'NONE_OF_MEDIAPROVIDERS_AVAILABLE', 'None of MediaProviders available');
10260
- /**
10261
- * Error if none of preferred MediaProviders available
10262
- * @event NONE_OF_PREFERRED_MEDIAPROVIDERS_AVAILABLE
10263
- * @memberof Flashphoner.constants.ERROR_INFO
10264
- */
10344
+ /**
10345
+ * Error if none of preferred MediaProviders available
10346
+ * @event NONE_OF_PREFERRED_MEDIAPROVIDERS_AVAILABLE
10347
+ * @memberof Flashphoner.constants.ERROR_INFO
10348
+ */
10349
+ NONE_OF_PREFERRED_MEDIAPROVIDERS_AVAILABLE: 'None of preferred MediaProviders available',
10265
10350
 
10266
- define(errorInfo, 'NONE_OF_PREFERRED_MEDIAPROVIDERS_AVAILABLE', 'None of preferred MediaProviders available');
10267
- /**
10268
- * Error if API is not initialized
10269
- * @event FLASHPHONER_API_NOT_INITIALIZED
10270
- * @memberof Flashphoner.constants.ERROR_INFO
10271
- */
10351
+ /**
10352
+ * Error if API is not initialized
10353
+ * @event FLASHPHONER_API_NOT_INITIALIZED
10354
+ * @memberof Flashphoner.constants.ERROR_INFO
10355
+ */
10356
+ FLASHPHONER_API_NOT_INITIALIZED: 'Flashphoner API is not initialized',
10272
10357
 
10273
- define(errorInfo, 'FLASHPHONER_API_NOT_INITIALIZED', 'Flashphoner API is not initialized');
10274
- /**
10275
- * Error if options.urlServer is not specified
10276
- * @event OPTIONS_URLSERVER_MUST_BE_PROVIDED
10277
- * @memberof Flashphoner.constants.ERROR_INFO
10278
- */
10358
+ /**
10359
+ * Error if options.urlServer is not specified
10360
+ * @event OPTIONS_URLSERVER_MUST_BE_PROVIDED
10361
+ * @memberof Flashphoner.constants.ERROR_INFO
10362
+ */
10363
+ OPTIONS_URLSERVER_MUST_BE_PROVIDED: 'options.urlServer must be provided',
10279
10364
 
10280
- define(errorInfo, 'OPTIONS_URLSERVER_MUST_BE_PROVIDED', 'options.urlServer must be provided');
10281
- /**
10282
- * Error if session state is not REGISTERED
10283
- * @event INVALID_SESSION_STATE
10284
- * @memberof Flashphoner.constants.ERROR_INFO
10285
- */
10365
+ /**
10366
+ * Error if session state is not valid
10367
+ * @event INVALID_SESSION_STATE
10368
+ * @memberof Flashphoner.constants.ERROR_INFO
10369
+ */
10370
+ INVALID_SESSION_STATE: 'Invalid session state',
10286
10371
 
10287
- define(errorInfo, 'INVALID_SESSION_STATE', 'Invalid session state');
10288
- /**
10289
- * Error if no options provided
10290
- * @event OPTIONS_MUST_BE_PROVIDED
10291
- * @memberof Flashphoner.constants.ERROR_INFO
10292
- */
10372
+ /**
10373
+ * Error if no options provided
10374
+ * @event OPTIONS_MUST_BE_PROVIDED
10375
+ * @memberof Flashphoner.constants.ERROR_INFO
10376
+ */
10377
+ OPTIONS_MUST_BE_PROVIDED: 'options must be provided',
10293
10378
 
10294
- define(errorInfo, 'OPTIONS_MUST_BE_PROVIDED', 'options must be provided');
10295
- /**
10296
- * Error if call status is not {@link Flashphoner.constants.CALL_STATUS.NEW}
10297
- * @event INVALID_CALL_STATE
10298
- * @memberof Flashphoner.constants.ERROR_INFO
10299
- */
10379
+ /**
10380
+ * Error if call status is not {@link Flashphoner.constants.CALL_STATUS.NEW}
10381
+ * @event INVALID_CALL_STATE
10382
+ * @memberof Flashphoner.constants.ERROR_INFO
10383
+ */
10384
+ INVALID_CALL_STATE: 'Invalid call state',
10300
10385
 
10301
- define(errorInfo, 'INVALID_CALL_STATE', 'Invalid call state');
10302
- /**
10303
- * Error if event is not specified
10304
- * @event EVENT_CANT_BE_NULL
10305
- * @memberof Flashphoner.constants.ERROR_INFO
10306
- */
10386
+ /**
10387
+ * Error if event is not specified
10388
+ * @event EVENT_CANT_BE_NULL
10389
+ * @memberof Flashphoner.constants.ERROR_INFO
10390
+ */
10391
+ EVENT_CANT_BE_NULL: 'Event can\'t be null',
10392
+
10393
+ /**
10394
+ * Error if callback is not a valid function
10395
+ * @event CALLBACK_NEEDS_TO_BE_A_VALID_FUNCTION
10396
+ * @memberof Flashphoner.constants.ERROR_INFO
10397
+ */
10398
+ CALLBACK_NEEDS_TO_BE_A_VALID_FUNCTION: 'Callback needs to be a valid function',
10307
10399
 
10308
- define(errorInfo, 'EVENT_CANT_BE_NULL', 'Event can\'t be null');
10400
+ /**
10401
+ * Error if options.name is not specified
10402
+ * @event OPTIONS_NAME_MUST_BE_PROVIDED
10403
+ * @memberof Flashphoner.constants.ERROR_INFO
10404
+ */
10405
+ OPTIONS_NAME_MUST_BE_PROVIDED: 'options.name must be provided',
10406
+
10407
+ /**
10408
+ * Error if number of cams is less than 2 or camera is already used by other application
10409
+ * @event CAN_NOT_SWITCH_CAM
10410
+ * @memberOf Flashphoner.constants.ERROR_INFO
10411
+ */
10412
+ CAN_NOT_SWITCH_CAM: 'Number of cams is less than 2 or camera is already used by other application',
10413
+
10414
+ /**
10415
+ * Error if number of mics is less than 2 or microphone is already used by other application
10416
+ * @event CAN_NOT_SWITCH_MIC
10417
+ * @memberOf Flashphoner.constants.ERROR_INFO
10418
+ */
10419
+ CAN_NOT_SWITCH_MIC: 'Number of mics is less than 2 or microphone is already used by other application',
10420
+
10421
+ /**
10422
+ * Local browser error detected
10423
+ * @event LOCAL_ERROR
10424
+ * @memberOf Flashphoner.constants.ERROR_INFO
10425
+ */
10426
+ LOCAL_ERROR: 'Local error'
10427
+ });
10309
10428
  /**
10310
- * Error if callback is not a valid function
10311
- * @event CALLBACK_NEEDS_TO_BE_A_VALID_FUNCTION
10312
- * @memberof Flashphoner.constants.ERROR_INFO
10429
+ * Local media devices type
10430
+ * @namespace Flashphoner.constants.MEDIA_DEVICE_KIND
10313
10431
  */
10314
10432
 
10315
- define(errorInfo, 'CALLBACK_NEEDS_TO_BE_A_VALID_FUNCTION', 'Callback needs to be a valid function');
10433
+ var MEDIA_DEVICE_KIND = Object.freeze({
10434
+ /**
10435
+ * List local media output devices
10436
+ * @see Flashphoner.getMediaDevices
10437
+ * @memberOf Flashphoner.constants.MEDIA_DEVICE_KIND
10438
+ */
10439
+ OUTPUT: 'output',
10440
+
10441
+ /**
10442
+ * List local media input devices
10443
+ * @see Flashphoner.getMediaDevices
10444
+ * @memberOf Flashphoner.constants.MEDIA_DEVICE_KIND
10445
+ */
10446
+ INPUT: 'input',
10447
+
10448
+ /**
10449
+ * List local media devices
10450
+ * @see Flashphoner.getMediaDevices
10451
+ * @memberOf Flashphoner.constants.MEDIA_DEVICE_KIND
10452
+ */
10453
+ ALL: 'all'
10454
+ });
10316
10455
  /**
10317
- * Error if session state is not ESTABLISHED
10318
- * @event INVALID_SESSION_STATE
10319
- * @memberof Flashphoner.constants.ERROR_INFO
10456
+ * WebRTC transport type
10457
+ * @namespace Flashphoner.constants.TRANSPORT_TYPE
10320
10458
  */
10321
10459
 
10322
- define(errorInfo, 'INVALID_SESSION_STATE', 'Invalid session state');
10460
+ var TRANSPORT_TYPE = Object.freeze({
10461
+ /**
10462
+ * WebRTC RTP traffic goes over UDP (default)
10463
+ * @see Stream
10464
+ * @memberOf Flashphoner.constants.TRANSPORT_TYPE
10465
+ */
10466
+ UDP: 'UDP',
10467
+
10468
+ /**
10469
+ * WebRTC RTP traffic goes over TCP
10470
+ * @see Stream
10471
+ * @memberOf Flashphoner.constants.TRANSPORT_TYPE
10472
+ */
10473
+ TCP: 'TCP'
10474
+ });
10323
10475
  /**
10324
- * Error if options.name is not specified
10325
- * @event OPTIONS_NAME_MUST_BE_PROVIDED
10326
- * @memberof Flashphoner.constants.ERROR_INFO
10476
+ * WebRTC connection quality type
10477
+ * @namespace Flashphoner.constants.CONNECTION_QUALITY
10327
10478
  */
10328
10479
 
10329
- define(errorInfo, 'OPTIONS_NAME_MUST_BE_PROVIDED', 'options.name must be provided');
10480
+ var CONNECTION_QUALITY = Object.freeze({
10481
+ /**
10482
+ * Channel bandwidth is perfect
10483
+ * @see Stream
10484
+ * @memberOf Flashphoner.constants.CONNECTION_QUALITY
10485
+ */
10486
+ PERFECT: 'PERFECT',
10487
+
10488
+ /**
10489
+ * Channel bandwidth is good
10490
+ * @see Stream
10491
+ * @memberOf Flashphoner.constants.CONNECTION_QUALITY
10492
+ */
10493
+ GOOD: 'GOOD',
10494
+
10495
+ /**
10496
+ * Channel bandwidth is bad
10497
+ * @see Stream
10498
+ * @memberOf Flashphoner.constants.CONNECTION_QUALITY
10499
+ */
10500
+ BAD: 'BAD',
10501
+
10502
+ /**
10503
+ * Channel bandwidth is unknown (initial state)
10504
+ * @see Stream
10505
+ * @memberOf Flashphoner.constants.CONNECTION_QUALITY
10506
+ */
10507
+ UNKNOWN: 'UNKNOWN',
10508
+
10509
+ /**
10510
+ * Channel bandwidth is updating
10511
+ * @see Stream
10512
+ * @memberOf Flashphoner.constants.CONNECTION_QUALITY
10513
+ */
10514
+ UPDATE: 'UPDATE'
10515
+ });
10330
10516
  /**
10331
- * Error if number of cams is less than 2 or already used custom stream
10332
- * @event CAN_NOT_SWITCH_CAM
10333
- * @memberOf Flashphoner.constants.ERROR_INFO
10517
+ * Websocket signaling stream event
10518
+ * @see Stream
10519
+ * @memberOf Flashphoner.constants
10334
10520
  */
10335
10521
 
10336
- define(errorInfo, 'CAN_NOT_SWITCH_CAM', 'Number of cams is less than 2 or already used custom stream');
10522
+ var STREAM_EVENT = 'STREAM_EVENT';
10337
10523
  /**
10338
- * Error if number of mics is less than 2 or already used custom stream
10339
- * @event CAN_NOT_SWITCH_MIC
10340
- * @memberOf Flashphoner.constants.ERROR_INFO
10524
+ * Websocket signaling stream event type
10525
+ * @namespace Flashphoner.constants.STREAM_EVENT_TYPE
10341
10526
  */
10342
10527
 
10343
- define(errorInfo, 'CAN_NOT_SWITCH_MIC', 'Number of mics is less than 2 or already used custom stream');
10528
+ var STREAM_EVENT_TYPE = Object.freeze({
10529
+ /**
10530
+ * Stream audio is muted
10531
+ * @see Stream
10532
+ * @memberOf Flashphoner.constants.STREAM_EVENT_TYPE
10533
+ */
10534
+ AUDIO_MUTED: 'audioMuted',
10535
+
10536
+ /**
10537
+ * Stream audio is unmuted
10538
+ * @see Stream
10539
+ * @memberOf Flashphoner.constants.STREAM_EVENT_TYPE
10540
+ */
10541
+ AUDIO_UNMUTED: 'audioUnmuted',
10542
+
10543
+ /**
10544
+ * Stream video is muted
10545
+ * @see Stream
10546
+ * @memberOf Flashphoner.constants.STREAM_EVENT_TYPE
10547
+ */
10548
+ VIDEO_MUTED: 'videoMuted',
10549
+
10550
+ /**
10551
+ * Stream videoo is unmuted
10552
+ * @see Stream
10553
+ * @memberOf Flashphoner.constants.STREAM_EVENT_TYPE
10554
+ */
10555
+ VIDEO_UNMUTED: 'videoUnmuted',
10556
+
10557
+ /**
10558
+ * Data bound to the stream are received
10559
+ * @see Stream
10560
+ * @memberOf Flashphoner.constants.STREAM_EVENT_TYPE
10561
+ */
10562
+ DATA: 'data'
10563
+ });
10344
10564
  /**
10345
- * Error if recived local error
10346
- * @event CAN_NOT_SWITCH_MIC
10347
- * @memberOf Flashphoner.constants.ERROR_INFO
10565
+ * WebRTC video content hint type
10566
+ * @namespace Flashphoner.constants.CONTENT_HINT_TYPE
10348
10567
  */
10349
10568
 
10350
- define(errorInfo, 'LOCAL_ERROR', 'Local error');
10351
- var mediaDeviceKind = {};
10352
- define(mediaDeviceKind, 'OUTPUT', 'output');
10353
- define(mediaDeviceKind, 'INPUT', 'input');
10354
- define(mediaDeviceKind, 'ALL', 'all');
10355
- var transportType = {};
10356
- define(transportType, 'UDP', 'UDP');
10357
- define(transportType, 'TCP', 'TCP');
10358
- var connectionQuality = {};
10359
- define(connectionQuality, 'PERFECT', 'PERFECT');
10360
- define(connectionQuality, 'GOOD', 'GOOD');
10361
- define(connectionQuality, 'BAD', 'BAD');
10362
- define(connectionQuality, 'UNKNOWN', 'UNKNOWN');
10363
- define(connectionQuality, 'UPDATE', 'UPDATE');
10364
- var streamEventType = {};
10365
- define(streamEventType, 'AUDIO_MUTED', 'audioMuted');
10366
- define(streamEventType, 'AUDIO_UNMUTED', 'audioUnmuted');
10367
- define(streamEventType, 'VIDEO_MUTED', 'videoMuted');
10368
- define(streamEventType, 'VIDEO_UNMUTED', 'videoUnmuted');
10369
- define(streamEventType, 'DATA', 'data');
10370
- var contentHintType = {};
10371
- define(contentHintType, 'MOTION', 'motion');
10372
- define(contentHintType, 'DETAIL', 'detail');
10373
- define(contentHintType, 'TEXT', 'text');
10374
- var constants = {};
10375
- define(constants, 'SESSION_STATUS', sessionStatus);
10376
- define(constants, 'STREAM_EVENT_TYPE', streamEventType);
10377
- define(constants, 'STREAM_EVENT', 'STREAM_EVENT');
10378
- define(constants, 'STREAM_STATUS', streamStatus);
10379
- define(constants, 'CALL_STATUS', callStatus);
10380
- define(constants, 'STREAM_STATUS_INFO', streamStatusInfo);
10381
- define(constants, 'CALL_STATUS_INFO', callStatusInfo);
10382
- define(constants, 'ERROR_INFO', errorInfo);
10383
- define(constants, 'MEDIA_DEVICE_KIND', mediaDeviceKind);
10384
- define(constants, 'TRANSPORT_TYPE', transportType);
10385
- define(constants, 'CONNECTION_QUALITY', connectionQuality);
10386
- define(constants, 'CONTENT_HINT_TYPE', contentHintType); //define helper
10387
-
10388
- function define(obj, name, value) {
10389
- Object.defineProperty(obj, name, {
10390
- value: value,
10391
- enumerable: true
10392
- });
10393
- }
10569
+ var CONTENT_HINT_TYPE = Object.freeze({
10570
+ /**
10571
+ * Video content is motion (webcam case): keep FPS, resolution and bitrate may change
10572
+ * @see Stream
10573
+ * @memberOf Flashphoner.constants.CONTENT_HINT_TYPE
10574
+ */
10575
+ MOTION: 'motion',
10576
+
10577
+ /**
10578
+ * Video content is detail (sreen sharing case): keep resolution, bitrate may change, FPS may drop
10579
+ * @see Stream
10580
+ * @memberOf Flashphoner.constants.CONTENT_HINT_TYPE
10581
+ */
10582
+ DETAIL: 'detail',
10394
10583
 
10395
- module.exports = constants;
10584
+ /**
10585
+ * Video content is text (sreen sharing case): keep resolution and bitrate, FPS may drop
10586
+ * @see Stream
10587
+ * @memberOf Flashphoner.constants.CONTENT_HINT_TYPE
10588
+ */
10589
+ TEXT: 'text'
10590
+ });
10591
+ module.exports = {
10592
+ SESSION_STATUS: SESSION_STATUS,
10593
+ STREAM_STATUS: STREAM_STATUS,
10594
+ CALL_STATUS: CALL_STATUS,
10595
+ STREAM_STATUS_INFO: STREAM_STATUS_INFO,
10596
+ CALL_STATUS_INFO: CALL_STATUS_INFO,
10597
+ ERROR_INFO: ERROR_INFO,
10598
+ MEDIA_DEVICE_KIND: MEDIA_DEVICE_KIND,
10599
+ TRANSPORT_TYPE: TRANSPORT_TYPE,
10600
+ CONNECTION_QUALITY: CONNECTION_QUALITY,
10601
+ STREAM_EVENT: STREAM_EVENT,
10602
+ STREAM_EVENT_TYPE: STREAM_EVENT_TYPE,
10603
+ CONTENT_HINT_TYPE: CONTENT_HINT_TYPE
10604
+ };
10396
10605
 
10397
10606
  },{}],41:[function(require,module,exports){
10398
10607
  'use strict';
@@ -11665,7 +11874,7 @@ var createSession = function createSession(options) {
11665
11874
  mediaProviders: Object.keys(MediaProvider),
11666
11875
  keepAlive: keepAlive,
11667
11876
  authToken: authToken,
11668
- clientVersion: "2.0.216",
11877
+ clientVersion: "2.0.217",
11669
11878
  clientOSVersion: window.navigator.appVersion,
11670
11879
  clientBrowserVersion: window.navigator.userAgent,
11671
11880
  msePacketizationVersion: 2,