Skip to content
This repository was archived by the owner on Oct 25, 2024. It is now read-only.

Commit 2721469

Browse files
authored
Merge pull request #97 from jianjunz/docs
Fix some documentation issues.
2 parents 2372a74 + 199c2c6 commit 2721469

File tree

6 files changed

+28
-16
lines changed

6 files changed

+28
-16
lines changed

src/sdk/base/codec.js

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@
44

55
'use strict';
66

7+
/**
8+
* @class AudioCodec
9+
* @memberOf Owt.Base
10+
* @classDesc Audio codec enumeration.
11+
* @hideconstructor
12+
*/
713
export const AudioCodec = {
814
PCMU: 'pcmu',
915
PCMA: 'pcma',
@@ -28,7 +34,7 @@ export class AudioCodecParameters {
2834
* @member {string} name
2935
* @memberof Owt.Base.AudioCodecParameters
3036
* @instance
31-
* @desc Name of a codec. Please a value in Owt.Base.AudioCodec. However, some functions do not support all the values in Owt.Base.AudioCodec.
37+
* @desc Name of a codec. Please use a value in Owt.Base.AudioCodec. However, some functions do not support all the values in Owt.Base.AudioCodec.
3238
*/
3339
this.name = name;
3440
/**
@@ -93,7 +99,7 @@ export class VideoCodecParameters {
9399
* @member {string} name
94100
* @memberof Owt.Base.VideoCodecParameters
95101
* @instance
96-
* @desc Name of a codec. Please a value in Owt.Base.AudioCodec. However, some functions do not support all the values in Owt.Base.AudioCodec.
102+
* @desc Name of a codec. Please use a value in Owt.Base.VideoCodec. However, some functions do not support all the values in Owt.Base.AudioCodec.
97103
*/
98104
this.name = name;
99105
/**

src/sdk/base/mediaformat.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44

55
'use strict';
66
/**
7-
* Source info about an audio track. Values: 'mic', 'screen-cast', 'file', 'mixed'.
7+
* @class AudioSourceInfo
8+
* @classDesc Source info about an audio track. Values: 'mic', 'screen-cast', 'file', 'mixed'.
89
* @memberOf Owt.Base
910
* @readonly
1011
* @enum {string}
@@ -17,7 +18,8 @@ export const AudioSourceInfo = {
1718
};
1819

1920
/**
20-
* Source info about a video track. Values: 'camera', 'screen-cast', 'file', 'mixed'.
21+
* @class VideoSourceInfo
22+
* @classDesc Source info about a video track. Values: 'camera', 'screen-cast', 'file', 'mixed'.
2123
* @memberOf Owt.Base
2224
* @readonly
2325
* @enum {string}
@@ -30,7 +32,8 @@ export const VideoSourceInfo = {
3032
};
3133

3234
/**
33-
* Kind of a track. Values: 'audio' for audio track, 'video' for video track, 'av' for both audio and video tracks.
35+
* @class TrackKind
36+
* @classDesc Kind of a track. Values: 'audio' for audio track, 'video' for video track, 'av' for both audio and video tracks.
3437
* @memberOf Owt.Base
3538
* @readonly
3639
* @enum {string}

src/sdk/base/publication.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ export class VideoPublicationSettings {
5050
/**
5151
* @member {?number} frameRates
5252
* @instance
53+
* @classDesc Frames per second.
5354
* @memberof Owt.Base.VideoPublicationSettings
5455
*/
5556
this.frameRate=frameRate;
@@ -62,6 +63,7 @@ export class VideoPublicationSettings {
6263
/**
6364
* @member {?number} keyFrameIntervals
6465
* @instance
66+
* @classDesc The time interval between key frames. Unit: second.
6567
* @memberof Owt.Base.VideoPublicationSettings
6668
*/
6769
this.keyFrameInterval=keyFrameInterval;
@@ -94,6 +96,7 @@ export class PublicationSettings {
9496

9597
/**
9698
* @class Publication
99+
* @extends Owt.Base.EventDispatcher
97100
* @memberOf Owt.Base
98101
* @classDesc Publication represents a sender for publishing a stream. It
99102
* handles the actions on a LocalStream published to a conference.

src/sdk/conference/mixedstream.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import {OwtEvent} from '../base/event.js';
1515
*
1616
* | Event Name | Argument Type | Fired when |
1717
* | -----------------------| ---------------- | ---------------- |
18-
* | activeaudioinputchange | Event | Audio activeness of input stream(of the mixed stream) is changed. |
18+
* | activeaudioinputchange | Event | Audio activeness of input stream (of the mixed stream) is changed. |
1919
* | layoutchange | Event | Video's layout has been changed. It usually happens when a new video is mixed into the target mixed stream or an existing video has been removed from mixed stream. |
2020
*
2121
* @memberOf Owt.Conference
@@ -40,7 +40,7 @@ export class RemoteMixedStream extends StreamModule.RemoteStream {
4040

4141
/**
4242
* @class ActiveAudioInputChangeEvent
43-
* @classDesc Class ActiveInputChangeEvent represents an active audio input change event.
43+
* @classDesc Class ActiveAudioInputChangeEvent represents an active audio input change event.
4444
* @memberof Owt.Conference
4545
* @hideconstructor
4646
*/

src/sdk/conference/subscription.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export class VideoSubscriptionCapabilities {
4343
*/
4444
this.codecs = codecs;
4545
/**
46-
* @member {Array.<Owt.Base.Resolution>} resolution
46+
* @member {Array.<Owt.Base.Resolution>} resolutions
4747
* @instance
4848
* @memberof Owt.Conference.VideoSubscriptionCapabilities
4949
*/
@@ -79,13 +79,13 @@ export class SubscriptionCapabilities {
7979
// eslint-disable-next-line require-jsdoc
8080
constructor(audio, video) {
8181
/**
82-
* @member {?AudioSubscriptionCapabilities} audio
82+
* @member {?Owt.Conference.AudioSubscriptionCapabilities} audio
8383
* @instance
8484
* @memberof Owt.Conference.SubscriptionCapabilities
8585
*/
8686
this.audio = audio;
8787
/**
88-
* @member {?VideoSubscriptionCapabilities} video
88+
* @member {?Owt.Conference.VideoSubscriptionCapabilities} video
8989
* @instance
9090
* @memberof Owt.Conference.SubscriptionCapabilities
9191
*/
@@ -133,28 +133,28 @@ export class VideoSubscriptionConstraints {
133133
* @member {?Owt.Base.Resolution} resolution
134134
* @instance
135135
* @memberof Owt.Conference.VideoSubscriptionConstraints
136-
* @desc Only resolutions listed in VideoSubscriptionCapabilities are allowed.
136+
* @desc Only resolutions listed in Owt.Conference.VideoSubscriptionCapabilities are allowed.
137137
*/
138138
this.resolution = resolution;
139139
/**
140140
* @member {?number} frameRate
141141
* @instance
142142
* @memberof Owt.Conference.VideoSubscriptionConstraints
143-
* @desc Only frameRates listed in VideoSubscriptionCapabilities are allowed.
143+
* @desc Only frameRates listed in Owt.Conference.VideoSubscriptionCapabilities are allowed.
144144
*/
145145
this.frameRate = frameRate;
146146
/**
147147
* @member {?number} bitrateMultiplier
148148
* @instance
149149
* @memberof Owt.Conference.VideoSubscriptionConstraints
150-
* @desc Only bitrateMultipliers listed in VideoSubscriptionCapabilities are allowed.
150+
* @desc Only bitrateMultipliers listed in Owt.Conference.VideoSubscriptionCapabilities are allowed.
151151
*/
152152
this.bitrateMultiplier = bitrateMultiplier;
153153
/**
154154
* @member {?number} keyFrameInterval
155155
* @instance
156156
* @memberof Owt.Conference.VideoSubscriptionConstraints
157-
* @desc Only keyFrameIntervals listed in VideoSubscriptionCapabilities are allowed.
157+
* @desc Only keyFrameIntervals listed in Owt.Conference.VideoSubscriptionCapabilities are allowed.
158158
*/
159159
this.keyFrameInterval = keyFrameInterval;
160160
}

src/sdk/p2p/p2pclient.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,8 @@ const P2PClient = function(configuration, signalingChannel) {
173173
* @desc Publish a stream to a remote endpoint.
174174
* @memberof Owt.P2P.P2PClient
175175
* @param {string} remoteId Remote endpoint's ID.
176-
* @param {LocalStream} stream A LocalStream to be published.
177-
* @return {Promise<Publication, Error>} A promised resolved when remote side received the certain stream. However, remote endpoint may not display this stream, or ignore it.
176+
* @param {Owt.Base.LocalStream} stream An Owt.Base.LocalStream to be published.
177+
* @return {Promise<Owt.Base.Publication, Error>} A promised that resolves when remote side received the certain stream. However, remote endpoint may not display this stream, or ignore it.
178178
*/
179179
this.publish = function(remoteId, stream) {
180180
if (state !== ConnectionState.CONNECTED) {

0 commit comments

Comments
 (0)