Packages: move collections to kotlin.collections.
This commit is contained in:
+15
-15
@@ -254,7 +254,7 @@
|
||||
*/
|
||||
lazyInitClasses.ArrayIterator = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.MutableIterator];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.MutableIterator];
|
||||
},
|
||||
/** @constructs */
|
||||
function (array) {
|
||||
@@ -286,7 +286,7 @@
|
||||
*/
|
||||
lazyInitClasses.ListIterator = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.ListIterator]; // TODO: MutableListIterator
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.ListIterator]; // TODO: MutableListIterator
|
||||
},
|
||||
/** @constructs */
|
||||
function (list, index) {
|
||||
@@ -358,9 +358,9 @@
|
||||
|
||||
lazyInitClasses.AbstractCollection = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.MutableCollection];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.MutableCollection];
|
||||
}, null, {
|
||||
addAll_4fm7v2$: function (collection) {
|
||||
addAll_wtfk93$: function (collection) {
|
||||
var modified = false;
|
||||
var it = collection.iterator();
|
||||
while (it.hasNext()) {
|
||||
@@ -370,7 +370,7 @@
|
||||
}
|
||||
return modified
|
||||
},
|
||||
removeAll_4fm7v2$: function (c) {
|
||||
removeAll_wtfk93$: function (c) {
|
||||
var modified = false;
|
||||
var it = this.iterator();
|
||||
while (it.hasNext()) {
|
||||
@@ -381,7 +381,7 @@
|
||||
}
|
||||
return modified
|
||||
},
|
||||
retainAll_4fm7v2$: function (c) {
|
||||
retainAll_wtfk93$: function (c) {
|
||||
var modified = false;
|
||||
var it = this.iterator();
|
||||
while (it.hasNext()) {
|
||||
@@ -396,7 +396,7 @@
|
||||
// TODO: implement with mutable iterator
|
||||
throw new Kotlin.NotImplementedError("Not implemented yet, see KT-7809");
|
||||
},
|
||||
containsAll_4fm7v2$: function (c) {
|
||||
containsAll_wtfk93$: function (c) {
|
||||
var it = c.iterator();
|
||||
while (it.hasNext()) {
|
||||
if (!this.contains_za3rmp$(it.next())) return false;
|
||||
@@ -452,7 +452,7 @@
|
||||
*/
|
||||
lazyInitClasses.AbstractList = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.MutableList, Kotlin.AbstractCollection];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.MutableList, Kotlin.AbstractCollection];
|
||||
}, null, {
|
||||
iterator: function () {
|
||||
return new Kotlin.ListIterator(this);
|
||||
@@ -470,7 +470,7 @@
|
||||
this.add_vux3hl$(this.size, element);
|
||||
return true;
|
||||
},
|
||||
addAll_9cca64$: function (index, collection) {
|
||||
addAll_j97iir$: function (index, collection) {
|
||||
// TODO: implement
|
||||
throw new Kotlin.NotImplementedError("Not implemented yet, see KT-7809");
|
||||
},
|
||||
@@ -594,7 +594,7 @@
|
||||
add_vux3hl$: function (index, element) {
|
||||
this.array.splice(index, 0, element);
|
||||
},
|
||||
addAll_4fm7v2$: function (collection) {
|
||||
addAll_wtfk93$: function (collection) {
|
||||
if (collection.size == 0) {
|
||||
return false;
|
||||
}
|
||||
@@ -770,7 +770,7 @@
|
||||
|
||||
lazyInitClasses.RangeIterator = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.Iterator];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.Iterator];
|
||||
},
|
||||
function (start, end, step) {
|
||||
this.start = start;
|
||||
@@ -856,7 +856,7 @@
|
||||
|
||||
lazyInitClasses.NumberProgression = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.Iterable];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.Iterable];
|
||||
},
|
||||
function (start, end, step) {
|
||||
this.start = start;
|
||||
@@ -921,7 +921,7 @@
|
||||
|
||||
lazyInitClasses.LongRangeIterator = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.Iterator];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.Iterator];
|
||||
},
|
||||
function (start, end, step) {
|
||||
this.start = start;
|
||||
@@ -944,7 +944,7 @@
|
||||
|
||||
lazyInitClasses.LongProgression = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.Iterable];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.Iterable];
|
||||
},
|
||||
function (start, end, step) {
|
||||
this.start = start;
|
||||
@@ -1023,7 +1023,7 @@
|
||||
|
||||
lazyInitClasses.CharProgression = Kotlin.createClassNow(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.Iterable];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.Iterable];
|
||||
},
|
||||
function (start, end, step) {
|
||||
this.start = start;
|
||||
|
||||
Vendored
+14
-14
@@ -63,7 +63,7 @@
|
||||
function hashSetEquals(o) {
|
||||
if (o == null || this.size !== o.size) return false;
|
||||
|
||||
return this.containsAll_4fm7v2$(o);
|
||||
return this.containsAll_wtfk93$(o);
|
||||
}
|
||||
|
||||
function hashSetHashCode() {
|
||||
@@ -424,11 +424,11 @@
|
||||
/**
|
||||
* @param {Hashtable.<Key, Value>} hashtable
|
||||
*/
|
||||
this.putAll_48yl7j$ = hashMapPutAll;
|
||||
this.putAll_r12sna$ = hashMapPutAll;
|
||||
|
||||
this.clone = function () {
|
||||
var clone = new Hashtable(hashingFunctionParam, equalityFunctionParam);
|
||||
clone.putAll_48yl7j$(that);
|
||||
clone.putAll_r12sna$(that);
|
||||
return clone;
|
||||
};
|
||||
|
||||
@@ -515,7 +515,7 @@
|
||||
|
||||
lazyInitClasses.HashMap = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.MutableMap];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.MutableMap];
|
||||
},
|
||||
function () {
|
||||
Kotlin.HashTable.call(this);
|
||||
@@ -535,7 +535,7 @@
|
||||
*/
|
||||
lazyInitClasses.PrimitiveHashMapValuesIterator = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.Iterator];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.Iterator];
|
||||
},
|
||||
function (map, keys) {
|
||||
this.map = map;
|
||||
@@ -645,7 +645,7 @@
|
||||
this.$size = 0;
|
||||
this.map = {};
|
||||
},
|
||||
putAll_48yl7j$: hashMapPutAll,
|
||||
putAll_r12sna$: hashMapPutAll,
|
||||
entries: {
|
||||
get: function () {
|
||||
var result = new Kotlin.ComplexHashSet();
|
||||
@@ -840,7 +840,7 @@
|
||||
|
||||
lazyInitClasses.LinkedHashSet = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.MutableSet, Kotlin.HashSet];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.MutableSet, Kotlin.HashSet];
|
||||
},
|
||||
/** @constructs */
|
||||
function () {
|
||||
@@ -882,7 +882,7 @@
|
||||
*/
|
||||
lazyInitClasses.SetIterator = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.MutableIterator];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.MutableIterator];
|
||||
},
|
||||
function (set) {
|
||||
this.set = set;
|
||||
@@ -1027,10 +1027,10 @@
|
||||
function HashSet(hashingFunction, equalityFunction) {
|
||||
var hashTable = new Kotlin.HashTable(hashingFunction, equalityFunction);
|
||||
|
||||
this.addAll_4fm7v2$ = Kotlin.AbstractCollection.prototype.addAll_4fm7v2$;
|
||||
this.removeAll_4fm7v2$ = Kotlin.AbstractCollection.prototype.removeAll_4fm7v2$;
|
||||
this.retainAll_4fm7v2$ = Kotlin.AbstractCollection.prototype.retainAll_4fm7v2$;
|
||||
this.containsAll_4fm7v2$ = Kotlin.AbstractCollection.prototype.containsAll_4fm7v2$;
|
||||
this.addAll_wtfk93$ = Kotlin.AbstractCollection.prototype.addAll_wtfk93$;
|
||||
this.removeAll_wtfk93$ = Kotlin.AbstractCollection.prototype.removeAll_wtfk93$;
|
||||
this.retainAll_wtfk93$ = Kotlin.AbstractCollection.prototype.retainAll_wtfk93$;
|
||||
this.containsAll_wtfk93$ = Kotlin.AbstractCollection.prototype.containsAll_wtfk93$;
|
||||
|
||||
this.add_za3rmp$ = function (o) {
|
||||
return !hashTable.put_wn2jw4$(o, true);
|
||||
@@ -1067,7 +1067,7 @@
|
||||
|
||||
this.clone = function () {
|
||||
var h = new HashSet(hashingFunction, equalityFunction);
|
||||
h.addAll_4fm7v2$(hashTable.keys());
|
||||
h.addAll_wtfk93$(hashTable.keys());
|
||||
return h;
|
||||
};
|
||||
|
||||
@@ -1129,7 +1129,7 @@
|
||||
|
||||
lazyInitClasses.HashSet = Kotlin.createClass(
|
||||
function () {
|
||||
return [Kotlin.modules['builtins'].kotlin.MutableSet, Kotlin.AbstractCollection];
|
||||
return [Kotlin.modules['builtins'].kotlin.collections.MutableSet, Kotlin.AbstractCollection];
|
||||
},
|
||||
function () {
|
||||
HashSet.call(this);
|
||||
|
||||
Reference in New Issue
Block a user