Adds a string representation of the given long field.

@param name
the name of the field
@param value
the value of the field
@throws IllegalStateException
if the string representation has already been completed
429223
void addField(final String name, final long value)
            throws IllegalStateException {

        addField(name, Long.toString(value));

    }
656111
void addPasswordField(final String name, final String value)
            throws IllegalStateException {

        addField(name, (value == null) ? null : "*****");

    }
392894
public void addField(String name, Object value, Object type) {
        if (value == null) {
            this.fields.add(new Field(name, null, null));
        } else {
            this.fields.add(new Field(name, value.toString(), type.toString()));
        }
    }
583775
public function addField(string $name, string $value) : void
    {
        $this->fields[$name][] = $value;
    }
1149374
public void declareRequestedFieldname(String name) {
        if (name.endsWith(".*")) {
            stringSetValues.put(name, new HashMap<>());
            stringSetPrefixes.put(name.substring(0, name.length() - 1), name);
        }
    }
382714
public void setString(String value) {
    if (this.token == Token.STRING || this.token == Token.NAME) {
      throw new IllegalStateException(
          "String node not created with Node.newString");
    } else {
      throw new UnsupportedOperationException(this + " is not a string node");
    }
  }
802507
public ToStringHelper add(String name, Object value) {
    checkNotNull(name);
    addHolder(value).builder.append(name).append('=').append(value);
    return this;
  }
430723
@Override
	public final void setLongProperty(String name, long value) throws JMSException
    {
        setProperty(name,Long.valueOf(value));
    }
345222
public void add(String name, V value) {
        List<V> lo = get(name);
        if (lo == null) {
            lo = new ArrayList<>();
        }
        lo.add(value);
        super.put(name, lo);
    }
352513
public AmqpTable addLongString(String key, String value) {
        this.add(key, value, AmqpType.LONGSTRING);
        return this;
    }
943542
public void addDateHeader(String name, long value) 
    {
        try{_httpResponse.addDateField(name,value);}
        catch(IllegalStateException e){LogSupport.ignore(log,e);}
    }
313310
public void put(String name, String value) {
    List<String> list = new ArrayList<>();
    list.add(value);
    getMap().put(name, list);
  }
480608
public void writeStringField(String fieldName, String value)
        throws IOException, JsonGenerationException
    {
        writeFieldName(fieldName);
        writeString(value);
    }
1205299
public boolean add(String name, Object value)
    {
        if(name == null)
            throw new NullPointerException("name == null");
        add(name);
        add(value.toString());
        return true;
    }
1296081
public void addValue(String value) {
        if (value == null)
            return;

        StringBuffer buffer = new StringBuffer();

        int l = value.length();
        State state = State.VALUE;
        boolean quoted = false;
        boolean sloshed = false;
        int nws_length = 0;
        int last_length = 0;
        int value_length = -1;
        int param_name = -1;
        int param_value = -1;

        for (int i = 0; i <= l; i++) {
            char c = i == l ? 0 : value.charAt(i);

            // Handle quoting https://tools.ietf.org/html/rfc7230#section-3.2.6
            if (quoted && c != 0) {
                if (sloshed)
                    sloshed = false;
                else {
                    switch (c) {
                        case '\\':
                            sloshed = true;
                            if (!_keepQuotes)
                                continue;
                            break;
                        case '"':
                            quoted = false;
                            if (!_keepQuotes)
                                continue;
                            break;
                    }
                }

                buffer.append(c);
                nws_length = buffer.length();
                continue;
            }

            // Handle common cases
            switch (c) {
                case ' ':
                case '\t':
                    if (buffer.length() > last_length) // not leading OWS
                        buffer.append(c);
                    continue;

                case '"':
                    quoted = true;
                    if (_keepQuotes) {
                        if (state == State.PARAM_VALUE && param_value < 0)
                            param_value = nws_length;
                        buffer.append(c);
                    } else if (state == State.PARAM_VALUE && param_value < 0)
                        param_value = nws_length;
                    nws_length = buffer.length();
                    continue;

                case ';':
                    buffer.setLength(nws_length); // trim following OWS
                    if (state == State.VALUE) {
                        parsedValue(buffer);
                        value_length = buffer.length();
                    } else
                        parsedParam(buffer, value_length, param_name, param_value);
                    nws_length = buffer.length();
                    param_name = param_value = -1;
                    buffer.append(c);
                    last_length = ++nws_length;
                    state = State.PARAM_NAME;
                    continue;

                case ',':
                case 0:
                    if (nws_length > 0) {
                        buffer.setLength(nws_length); // trim following OWS
                        switch (state) {
                            case VALUE:
                                parsedValue(buffer);
//                                value_length = buffer.length();
                                break;
                            case PARAM_NAME:
                            case PARAM_VALUE:
                                parsedParam(buffer, value_length, param_name, param_value);
                                break;
                        }
                        _values.add(buffer.toString());
                    }
                    buffer.setLength(0);
                    last_length = 0;
                    nws_length = 0;
                    value_length = param_name = param_value = -1;
                    state = State.VALUE;
                    continue;

                case '=':
                    switch (state) {
                        case VALUE:
                            // It wasn't really a value, it was a param name
                            value_length = param_name = 0;
                            buffer.setLength(nws_length); // trim following OWS
                            String param = buffer.toString();
                            buffer.setLength(0);
                            parsedValue(buffer);
                            value_length = buffer.length();
                            buffer.append(param);
                            buffer.append(c);
                            last_length = ++nws_length;
                            state = State.PARAM_VALUE;
                            continue;

                        case PARAM_NAME:
                            buffer.setLength(nws_length); // trim following OWS
                            buffer.append(c);
                            last_length = ++nws_length;
                            state = State.PARAM_VALUE;
                            continue;

                        case PARAM_VALUE:
                            if (param_value < 0)
                                param_value = nws_length;
                            buffer.append(c);
                            nws_length = buffer.length();
                            continue;
                    }
                    continue;

                default: {
                    switch (state) {
                        case VALUE: {
                            buffer.append(c);
                            nws_length = buffer.length();
                            continue;
                        }

                        case PARAM_NAME: {
                            if (param_name < 0)
                                param_name = nws_length;
                            buffer.append(c);
                            nws_length = buffer.length();
                            continue;
                        }

                        case PARAM_VALUE: {
                            if (param_value < 0)
                                param_value = nws_length;
                            buffer.append(c);
                            nws_length = buffer.length();
                        }
                    }
                }
            }
        }
    }
1220372
public void add(String name, Object value) {
		if (value != null) {
			this.content.put(name, value);
		}
	}
494533
public void add(AsciiString name, String value){
        if(name==null || value==null)
            return;
        Header head = entry(name, true);
        if(head.value==null)
            head.value = value;
        else{
            Header newHeader = newHeader(name);
            newHeader.value = value;
            Header tail = head.samePrev;
            tail.sameNext = newHeader;
            newHeader.samePrev = tail;
            head.samePrev = newHeader;
        }
        assert validateLinks();
    }