code: public JSONWriter array() {
          if (this.mode == INIT || this.mode == OBJECT || this.mode == ARRAY) {
              this.push(ARRAY);
              this.append("[");
              this.comma = false;
              return this;
          }
          throw new JSONException("Misplaced array: expected mode of INIT, OBJECT or ARRAY but was " + this.mode);
      }
docs: Begin appending a new array. All values until the balancing
  <code>endArray</code> will be appended to this array. The
  <code>endArray</code> method must be called to mark the array's end.
  
  @return this