ソースを参照

Merge branch 'master' into t/ckeditor5/645

Aleksander Nowodzinski 8 年 前
コミット
bf94bcba64

+ 7 - 3
packages/ckeditor5-core/src/commandcollection.js

@@ -70,7 +70,7 @@ export default class CommandCollection {
 	/**
 	 * Returns iterator of command names.
 	 *
-	 * @returns {Iterator.<String>}
+	 * @returns {Iterable.<String>}
 	 */
 	* names() {
 		yield* this._commands.keys();
@@ -79,14 +79,18 @@ export default class CommandCollection {
 	/**
 	 * Returns iterator of command instances.
 	 *
-	 * @returns {Iterator.<module:core/command~Command>}
+	 * @returns {Iterable.<module:core/command~Command>}
 	 */
 	* commands() {
 		yield* this._commands.values();
 	}
 
 	/**
-	 * Collection iterator.
+	 * Iterable interface.
+	 *
+	 * Returns `[ commandName, commandInstance ]` pairs.
+	 *
+	 * @returns {Iterable.<Array>}
 	 */
 	[ Symbol.iterator ]() {
 		return this._commands[ Symbol.iterator ]();

+ 5 - 1
packages/ckeditor5-core/src/plugincollection.js

@@ -55,7 +55,11 @@ export default class PluginCollection {
 	}
 
 	/**
-	 * Collection iterator. Returns `[ PluginConstructor, pluginInstance ]` pairs.
+	 * Iterable interface.
+	 *
+	 * Returns `[ PluginConstructor, pluginInstance ]` pairs.
+	 *
+	 * @returns {Iterable.<Array>}
 	 */
 	* [ Symbol.iterator ]() {
 		for ( const entry of this._plugins ) {