code: public JSONWriter array() throws JSONException {
  
          if ((m_mode == 'i') || (m_mode == 'o') || (m_mode == 'a')) {
              push('a');
              append("[");
              m_comma = false;
              return this;
          }
          throw new JSONException("Misplaced array.");
      }
docs: Begin appending a new array.<p>
  
  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.<p>
  
  @return this
  @throws JSONException if the nesting is too deep, or if the object is
  started in the wrong place (for example as a key or after the end of the
  outermost array or object)