String value(
String name
)

Convenience method for the value for a single valued header. If there is no header with the provided name, null will be returned. If the header has more than one value an exception is thrown.

Source

/**
 * Convenience method for the value for a single valued header. If
 * there is no header with the provided name, [:null:] will be
 * returned. If the header has more than one value an exception is
 * thrown.
 */
String value(String name);