Package org.springframework.security.web.header

# Class Header

java.lang.Object
org.springframework.security.web.header.Header

public final class Header extends Object
Represents a Header to be added to the `HttpServletResponse`

## Constructor Summary

Constructors
Constructor
Description
`Header(String headerName, String... headerValues)`
Creates a new instance

## Method Summary

Modifier and Type
Method
Description
`boolean`
`equals(Object obj)`
`String`
`getName()`
Gets the name of the header.
`List<String>`
`getValues()`
Gets the values of the header.
`int`
`hashCode()`
`String`
`toString()`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

## Constructor Details

### Header

public Header(String headerName, String... headerValues)
Creates a new instance

Parameters:
  `headerName` - the name of the header
  `headerValues` - the values of the header

## Method Details

### getName

public String getName()
Gets the name of the header. Cannot be `null`.

Returns:
  the name of the header.

### getValues

public List<String> getValues()
Gets the values of the header. Cannot be null, empty, or contain null values.

Returns:
  the values of the header

### equals

public boolean equals(Object obj)

Overrides:
  `equals` in class `Object`

### hashCode

public int hashCode()

Overrides:
  `hashCode` in class `Object`

### toString

public String toString()

Overrides:
  `toString` in class `Object`