public JsonWriter name(String name) throws IOException {
    if (name == null) {
      throw new NullPointerException("name == null");
    }
    if (deferredName != null) {
      throw new IllegalStateException();
    }
    deferredName = name;
    return this;
  }
public JsonWriter name(String name) throws IOException {
    if (name == null) {
      throw new NullPointerException("name == null");
    }
    if (deferredName != null) {
      throw new IllegalStateException();
    }
    deferredName = name;
    return this;
  }
public JsonWriter name ( String name ) throws IOException { if ( name == null ) { throw new NullPointerException ( "name == null" ) ; } if ( deferredName != null ) { throw new IllegalStateException ( ) ; } deferredName = name ; return this ; }
Encodes the property name.

@param name the name of the forthcoming value. May not be null.
@return this writer.
Encodes the property name .