emul/src/main/resources/org/apidesign/vm4brwsr/emul/java_lang_String.js
changeset 459 a2871a3fd4c5
parent 458 b157a354003f
child 479 34931e381886
     1.1 --- a/emul/src/main/resources/org/apidesign/vm4brwsr/emul/java_lang_String.js	Tue Jan 15 12:38:49 2013 +0100
     1.2 +++ b/emul/src/main/resources/org/apidesign/vm4brwsr/emul/java_lang_String.js	Tue Jan 15 12:44:33 2013 +0100
     1.3 @@ -7,12 +7,15 @@
     1.4    this.jvmName = sig;
     1.5    return this;
     1.6  };
     1.7 -Array.prototype.at = function(indx) {
     1.8 +Array.prototype.at = function(indx, value) {
     1.9    if (indx < 0 || indx > this.length) {
    1.10        var e = vm.java_lang_ArrayIndexOutOfBoundsException(true);
    1.11        e.constructor.cons__VLjava_lang_String_2.call(e, indx.toString());
    1.12        throw e;
    1.13    }
    1.14 +  if (arguments.length === 2) {
    1.15 +      this[indx] = value;
    1.16 +  }
    1.17    return this[indx];
    1.18  };
    1.19  Array.prototype.getClass__Ljava_lang_Class_2 = function() {