MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / constructor

Method constructor

javascript/selenium-webdriver/bidi/networkTypes.js:99–105  ·  view source on GitHub ↗

* Creates a new Header instance. * @param {string} name - The name of the header. * @param {BytesValue} value - The value of the header. * @throws {Error} If the value is not an instance of BytesValue.

(name, value)

Source from the content-addressed store, hash-verified

97 * @throws {Error} If the value is not an instance of BytesValue.
98 */
99 constructor(name, value) {
100 this._name = name
101 if (!(value instanceof BytesValue)) {
102 throw new Error(`Value must be an instance of BytesValue. Received: '${value}'`)
103 }
104 this._value = value
105 }
106
107 /**
108 * Gets the name of the header.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected