@alterior/http 3.13.3 → 3.13.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/backend.d.ts +38 -38
- package/dist/backend.js +38 -38
- package/dist/client.d.ts +2108 -2108
- package/dist/client.js +265 -265
- package/dist/client.js.map +1 -1
- package/dist/headers.d.ts +57 -57
- package/dist/headers.js +187 -187
- package/dist/headers.js.map +1 -1
- package/dist/index.d.ts +18 -18
- package/dist/index.js +42 -42
- package/dist/interceptor.d.ts +63 -63
- package/dist/interceptor.js +43 -43
- package/dist/interceptor.js.map +1 -1
- package/dist/module.d.ts +101 -101
- package/dist/module.js +188 -188
- package/dist/module.js.map +1 -1
- package/dist/params.d.ts +98 -98
- package/dist/params.js +184 -184
- package/dist/params.js.map +1 -1
- package/dist/request.d.ts +130 -130
- package/dist/request.js +260 -260
- package/dist/request.js.map +1 -1
- package/dist/response.d.ts +267 -267
- package/dist/response.js +165 -165
- package/dist/response.js.map +1 -1
- package/dist/server.d.ts +28 -28
- package/dist/server.js +119 -119
- package/dist/server.js.map +1 -1
- package/dist/test/client.test.d.ts +8 -8
- package/dist/test/client.test.js +163 -163
- package/dist/test/client.test.js.map +1 -1
- package/dist/test/headers.test.d.ts +1 -1
- package/dist/test/headers.test.js +126 -126
- package/dist/test/module.test.d.ts +1 -1
- package/dist/test/module.test.js +117 -117
- package/dist/test/module.test.js.map +1 -1
- package/dist/test/params.test.d.ts +1 -1
- package/dist/test/params.test.js +63 -63
- package/dist/test/request.test.d.ts +8 -8
- package/dist/test/request.test.js +159 -159
- package/dist/test/request.test.js.map +1 -1
- package/dist/test/response.test.d.ts +1 -1
- package/dist/test/response.test.js +79 -79
- package/dist/test/response.test.js.map +1 -1
- package/dist/test/test.d.ts +1 -1
- package/dist/test/test.js +16 -16
- package/dist/test/xhr.mock.d.ts +48 -48
- package/dist/test/xhr.mock.js +94 -94
- package/dist/test/xhr.mock.js.map +1 -1
- package/dist/test/xhr.test.d.ts +1 -1
- package/dist/test/xhr.test.js +344 -344
- package/dist/test/xhr.test.js.map +1 -1
- package/dist/test/xsrf.test.d.ts +1 -1
- package/dist/test/xsrf.test.js +63 -63
- package/dist/test/xsrf.test.js.map +1 -1
- package/dist/testing/api.d.ts +102 -102
- package/dist/testing/api.js +19 -19
- package/dist/testing/backend.d.ts +63 -63
- package/dist/testing/backend.js +141 -141
- package/dist/testing/backend.js.map +1 -1
- package/dist/testing/index.d.ts +10 -10
- package/dist/testing/index.js +16 -16
- package/dist/testing/module.d.ts +16 -16
- package/dist/testing/module.js +38 -38
- package/dist/testing/module.js.map +1 -1
- package/dist/testing/request.d.ts +56 -56
- package/dist/testing/request.js +177 -177
- package/dist/testing/request.js.map +1 -1
- package/dist/testing/request.test.d.ts +8 -8
- package/dist/testing/request.test.js +24 -24
- package/dist/xhr.d.ts +42 -42
- package/dist/xhr.js +298 -298
- package/dist/xhr.js.map +1 -1
- package/dist/xsrf.d.ts +37 -37
- package/dist/xsrf.js +55 -55
- package/dist/xsrf.js.map +1 -1
- package/dist.esm/backend.d.ts +38 -38
- package/dist.esm/backend.js +33 -33
- package/dist.esm/client.d.ts +2108 -2108
- package/dist.esm/client.js +262 -262
- package/dist.esm/client.js.map +1 -1
- package/dist.esm/headers.d.ts +57 -57
- package/dist.esm/headers.js +183 -183
- package/dist.esm/headers.js.map +1 -1
- package/dist.esm/index.d.ts +18 -18
- package/dist.esm/index.js +18 -18
- package/dist.esm/interceptor.d.ts +63 -63
- package/dist.esm/interceptor.js +39 -39
- package/dist.esm/interceptor.js.map +1 -1
- package/dist.esm/module.d.ts +101 -101
- package/dist.esm/module.js +183 -183
- package/dist.esm/module.js.map +1 -1
- package/dist.esm/params.d.ts +98 -98
- package/dist.esm/params.js +179 -179
- package/dist.esm/params.js.map +1 -1
- package/dist.esm/request.d.ts +130 -130
- package/dist.esm/request.js +256 -256
- package/dist.esm/request.js.map +1 -1
- package/dist.esm/response.d.ts +267 -267
- package/dist.esm/response.js +158 -158
- package/dist.esm/response.js.map +1 -1
- package/dist.esm/server.d.ts +28 -28
- package/dist.esm/server.js +113 -113
- package/dist.esm/server.js.map +1 -1
- package/dist.esm/test/client.test.d.ts +8 -8
- package/dist.esm/test/client.test.js +161 -161
- package/dist.esm/test/client.test.js.map +1 -1
- package/dist.esm/test/headers.test.d.ts +1 -1
- package/dist.esm/test/headers.test.js +124 -124
- package/dist.esm/test/module.test.d.ts +1 -1
- package/dist.esm/test/module.test.js +115 -115
- package/dist.esm/test/module.test.js.map +1 -1
- package/dist.esm/test/params.test.d.ts +1 -1
- package/dist.esm/test/params.test.js +61 -61
- package/dist.esm/test/request.test.d.ts +8 -8
- package/dist.esm/test/request.test.js +157 -157
- package/dist.esm/test/request.test.js.map +1 -1
- package/dist.esm/test/response.test.d.ts +1 -1
- package/dist.esm/test/response.test.js +77 -77
- package/dist.esm/test/response.test.js.map +1 -1
- package/dist.esm/test/test.d.ts +1 -1
- package/dist.esm/test/test.js +14 -14
- package/dist.esm/test/xhr.mock.d.ts +48 -48
- package/dist.esm/test/xhr.mock.js +88 -88
- package/dist.esm/test/xhr.mock.js.map +1 -1
- package/dist.esm/test/xhr.test.d.ts +1 -1
- package/dist.esm/test/xhr.test.js +342 -342
- package/dist.esm/test/xhr.test.js.map +1 -1
- package/dist.esm/test/xsrf.test.d.ts +1 -1
- package/dist.esm/test/xsrf.test.js +61 -61
- package/dist.esm/test/xsrf.test.js.map +1 -1
- package/dist.esm/testing/api.d.ts +102 -102
- package/dist.esm/testing/api.js +15 -15
- package/dist.esm/testing/backend.d.ts +63 -63
- package/dist.esm/testing/backend.js +138 -138
- package/dist.esm/testing/backend.js.map +1 -1
- package/dist.esm/testing/index.d.ts +10 -10
- package/dist.esm/testing/index.js +10 -10
- package/dist.esm/testing/module.d.ts +16 -16
- package/dist.esm/testing/module.js +35 -35
- package/dist.esm/testing/module.js.map +1 -1
- package/dist.esm/testing/request.d.ts +56 -56
- package/dist.esm/testing/request.js +173 -173
- package/dist.esm/testing/request.js.map +1 -1
- package/dist.esm/testing/request.test.d.ts +8 -8
- package/dist.esm/testing/request.test.js +22 -22
- package/dist.esm/xhr.d.ts +42 -42
- package/dist.esm/xhr.js +294 -294
- package/dist.esm/xhr.js.map +1 -1
- package/dist.esm/xsrf.d.ts +37 -37
- package/dist.esm/xsrf.js +51 -51
- package/dist.esm/xsrf.js.map +1 -1
- package/package.json +9 -9
- package/tsconfig.esm.tsbuildinfo +1 -0
- package/tsconfig.json +0 -2
- package/tsconfig.tsbuildinfo +1 -8046
package/dist.esm/headers.d.ts
CHANGED
|
@@ -1,58 +1,58 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright Google Inc. All Rights Reserved.
|
|
4
|
-
*
|
|
5
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
-
* found in the LICENSE file at https://angular.io/license
|
|
7
|
-
*/
|
|
8
|
-
/**
|
|
9
|
-
* Immutable set of Http headers, with lazy parsing.
|
|
10
|
-
*
|
|
11
|
-
*/
|
|
12
|
-
export declare class HttpHeaders {
|
|
13
|
-
/**
|
|
14
|
-
* Internal map of lowercase header names to values.
|
|
15
|
-
*/
|
|
16
|
-
private headers;
|
|
17
|
-
/**
|
|
18
|
-
* Internal map of lowercased header names to the normalized
|
|
19
|
-
* form of the name (the form seen first).
|
|
20
|
-
*/
|
|
21
|
-
private normalizedNames;
|
|
22
|
-
/**
|
|
23
|
-
* Complete the lazy initialization of this object (needed before reading).
|
|
24
|
-
*/
|
|
25
|
-
private lazyInit;
|
|
26
|
-
/**
|
|
27
|
-
* Queued updates to be materialized the next initialization.
|
|
28
|
-
*/
|
|
29
|
-
private lazyUpdate;
|
|
30
|
-
constructor(headers?: string | {
|
|
31
|
-
[name: string]: string | string[];
|
|
32
|
-
});
|
|
33
|
-
/**
|
|
34
|
-
* Checks for existence of header by given name.
|
|
35
|
-
*/
|
|
36
|
-
has(name: string): boolean;
|
|
37
|
-
/**
|
|
38
|
-
* Returns first header that matches given name.
|
|
39
|
-
*/
|
|
40
|
-
get(name: string): string | null;
|
|
41
|
-
/**
|
|
42
|
-
* Returns the names of the headers
|
|
43
|
-
*/
|
|
44
|
-
keys(): string[];
|
|
45
|
-
/**
|
|
46
|
-
* Returns list of header values for a given name.
|
|
47
|
-
*/
|
|
48
|
-
getAll(name: string): string[] | null;
|
|
49
|
-
append(name: string, value: string | string[]): HttpHeaders;
|
|
50
|
-
set(name: string, value: string | string[]): HttpHeaders;
|
|
51
|
-
delete(name: string, value?: string | string[]): HttpHeaders;
|
|
52
|
-
private maybeSetNormalizedName;
|
|
53
|
-
private init;
|
|
54
|
-
private copyFrom;
|
|
55
|
-
private clone;
|
|
56
|
-
private applyUpdate;
|
|
57
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright Google Inc. All Rights Reserved.
|
|
4
|
+
*
|
|
5
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
+
* found in the LICENSE file at https://angular.io/license
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Immutable set of Http headers, with lazy parsing.
|
|
10
|
+
*
|
|
11
|
+
*/
|
|
12
|
+
export declare class HttpHeaders {
|
|
13
|
+
/**
|
|
14
|
+
* Internal map of lowercase header names to values.
|
|
15
|
+
*/
|
|
16
|
+
private headers;
|
|
17
|
+
/**
|
|
18
|
+
* Internal map of lowercased header names to the normalized
|
|
19
|
+
* form of the name (the form seen first).
|
|
20
|
+
*/
|
|
21
|
+
private normalizedNames;
|
|
22
|
+
/**
|
|
23
|
+
* Complete the lazy initialization of this object (needed before reading).
|
|
24
|
+
*/
|
|
25
|
+
private lazyInit;
|
|
26
|
+
/**
|
|
27
|
+
* Queued updates to be materialized the next initialization.
|
|
28
|
+
*/
|
|
29
|
+
private lazyUpdate;
|
|
30
|
+
constructor(headers?: string | {
|
|
31
|
+
[name: string]: string | string[];
|
|
32
|
+
});
|
|
33
|
+
/**
|
|
34
|
+
* Checks for existence of header by given name.
|
|
35
|
+
*/
|
|
36
|
+
has(name: string): boolean;
|
|
37
|
+
/**
|
|
38
|
+
* Returns first header that matches given name.
|
|
39
|
+
*/
|
|
40
|
+
get(name: string): string | null;
|
|
41
|
+
/**
|
|
42
|
+
* Returns the names of the headers
|
|
43
|
+
*/
|
|
44
|
+
keys(): string[];
|
|
45
|
+
/**
|
|
46
|
+
* Returns list of header values for a given name.
|
|
47
|
+
*/
|
|
48
|
+
getAll(name: string): string[] | null;
|
|
49
|
+
append(name: string, value: string | string[]): HttpHeaders;
|
|
50
|
+
set(name: string, value: string | string[]): HttpHeaders;
|
|
51
|
+
delete(name: string, value?: string | string[]): HttpHeaders;
|
|
52
|
+
private maybeSetNormalizedName;
|
|
53
|
+
private init;
|
|
54
|
+
private copyFrom;
|
|
55
|
+
private clone;
|
|
56
|
+
private applyUpdate;
|
|
57
|
+
}
|
|
58
58
|
//# sourceMappingURL=headers.d.ts.map
|
package/dist.esm/headers.js
CHANGED
|
@@ -1,184 +1,184 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright Google Inc. All Rights Reserved.
|
|
4
|
-
*
|
|
5
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
-
* found in the LICENSE file at https://angular.io/license
|
|
7
|
-
*/
|
|
8
|
-
/**
|
|
9
|
-
* Immutable set of Http headers, with lazy parsing.
|
|
10
|
-
*
|
|
11
|
-
*/
|
|
12
|
-
export class HttpHeaders {
|
|
13
|
-
constructor(headers) {
|
|
14
|
-
/**
|
|
15
|
-
* Internal map of lowercased header names to the normalized
|
|
16
|
-
* form of the name (the form seen first).
|
|
17
|
-
*/
|
|
18
|
-
this.normalizedNames = new Map();
|
|
19
|
-
/**
|
|
20
|
-
* Queued updates to be materialized the next initialization.
|
|
21
|
-
*/
|
|
22
|
-
this.lazyUpdate = null;
|
|
23
|
-
if (!headers) {
|
|
24
|
-
this.headers = new Map();
|
|
25
|
-
}
|
|
26
|
-
else if (typeof headers === 'string') {
|
|
27
|
-
this.lazyInit = () => {
|
|
28
|
-
this.headers = new Map();
|
|
29
|
-
headers.split('\n').forEach(line => {
|
|
30
|
-
const index = line.indexOf(':');
|
|
31
|
-
if (index > 0) {
|
|
32
|
-
const name = line.slice(0, index);
|
|
33
|
-
const key = name.toLowerCase();
|
|
34
|
-
const value = line.slice(index + 1).trim();
|
|
35
|
-
this.maybeSetNormalizedName(name, key);
|
|
36
|
-
if (this.headers.has(key)) {
|
|
37
|
-
this.headers.get(key).push(value);
|
|
38
|
-
}
|
|
39
|
-
else {
|
|
40
|
-
this.headers.set(key, [value]);
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
});
|
|
44
|
-
};
|
|
45
|
-
}
|
|
46
|
-
else {
|
|
47
|
-
this.lazyInit = () => {
|
|
48
|
-
this.headers = new Map();
|
|
49
|
-
Object.keys(headers).forEach(name => {
|
|
50
|
-
let values = headers[name];
|
|
51
|
-
const key = name.toLowerCase();
|
|
52
|
-
if (typeof values === 'string') {
|
|
53
|
-
values = [values];
|
|
54
|
-
}
|
|
55
|
-
if (values.length > 0) {
|
|
56
|
-
this.headers.set(key, values);
|
|
57
|
-
this.maybeSetNormalizedName(name, key);
|
|
58
|
-
}
|
|
59
|
-
});
|
|
60
|
-
};
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
/**
|
|
64
|
-
* Checks for existence of header by given name.
|
|
65
|
-
*/
|
|
66
|
-
has(name) {
|
|
67
|
-
this.init();
|
|
68
|
-
return this.headers.has(name.toLowerCase());
|
|
69
|
-
}
|
|
70
|
-
/**
|
|
71
|
-
* Returns first header that matches given name.
|
|
72
|
-
*/
|
|
73
|
-
get(name) {
|
|
74
|
-
this.init();
|
|
75
|
-
const values = this.headers.get(name.toLowerCase());
|
|
76
|
-
return values && values.length > 0 ? values[0] : null;
|
|
77
|
-
}
|
|
78
|
-
/**
|
|
79
|
-
* Returns the names of the headers
|
|
80
|
-
*/
|
|
81
|
-
keys() {
|
|
82
|
-
this.init();
|
|
83
|
-
return Array.from(this.normalizedNames.values());
|
|
84
|
-
}
|
|
85
|
-
/**
|
|
86
|
-
* Returns list of header values for a given name.
|
|
87
|
-
*/
|
|
88
|
-
getAll(name) {
|
|
89
|
-
this.init();
|
|
90
|
-
return this.headers.get(name.toLowerCase()) || null;
|
|
91
|
-
}
|
|
92
|
-
append(name, value) {
|
|
93
|
-
return this.clone({ name, value, op: 'a' });
|
|
94
|
-
}
|
|
95
|
-
set(name, value) {
|
|
96
|
-
return this.clone({ name, value, op: 's' });
|
|
97
|
-
}
|
|
98
|
-
delete(name, value) {
|
|
99
|
-
return this.clone({ name, value, op: 'd' });
|
|
100
|
-
}
|
|
101
|
-
maybeSetNormalizedName(name, lcName) {
|
|
102
|
-
if (!this.normalizedNames.has(lcName)) {
|
|
103
|
-
this.normalizedNames.set(lcName, name);
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
init() {
|
|
107
|
-
if (!!this.lazyInit) {
|
|
108
|
-
if (this.lazyInit instanceof HttpHeaders) {
|
|
109
|
-
this.copyFrom(this.lazyInit);
|
|
110
|
-
}
|
|
111
|
-
else {
|
|
112
|
-
this.lazyInit();
|
|
113
|
-
}
|
|
114
|
-
this.lazyInit = null;
|
|
115
|
-
if (!!this.lazyUpdate) {
|
|
116
|
-
this.lazyUpdate.forEach(update => this.applyUpdate(update));
|
|
117
|
-
this.lazyUpdate = null;
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
copyFrom(other) {
|
|
122
|
-
other.init();
|
|
123
|
-
Array.from(other.headers.keys()).forEach(key => {
|
|
124
|
-
this.headers.set(key, other.headers.get(key));
|
|
125
|
-
this.normalizedNames.set(key, other.normalizedNames.get(key));
|
|
126
|
-
});
|
|
127
|
-
}
|
|
128
|
-
clone(update) {
|
|
129
|
-
const clone = new HttpHeaders();
|
|
130
|
-
clone.lazyInit =
|
|
131
|
-
(!!this.lazyInit && this.lazyInit instanceof HttpHeaders) ? this.lazyInit : this;
|
|
132
|
-
clone.lazyUpdate = (this.lazyUpdate || []).concat([update]);
|
|
133
|
-
return clone;
|
|
134
|
-
}
|
|
135
|
-
applyUpdate(update) {
|
|
136
|
-
const key = update.name.toLowerCase();
|
|
137
|
-
switch (update.op) {
|
|
138
|
-
case 'a':
|
|
139
|
-
case 's':
|
|
140
|
-
let value = update.value;
|
|
141
|
-
if (typeof value === 'string') {
|
|
142
|
-
value = [value];
|
|
143
|
-
}
|
|
144
|
-
if (value.length === 0) {
|
|
145
|
-
return;
|
|
146
|
-
}
|
|
147
|
-
this.maybeSetNormalizedName(update.name, key);
|
|
148
|
-
const base = (update.op === 'a' ? this.headers.get(key) : undefined) || [];
|
|
149
|
-
base.push(...value);
|
|
150
|
-
this.headers.set(key, base);
|
|
151
|
-
break;
|
|
152
|
-
case 'd':
|
|
153
|
-
const toDelete = update.value;
|
|
154
|
-
if (!toDelete) {
|
|
155
|
-
this.headers.delete(key);
|
|
156
|
-
this.normalizedNames.delete(key);
|
|
157
|
-
}
|
|
158
|
-
else {
|
|
159
|
-
let existing = this.headers.get(key);
|
|
160
|
-
if (!existing) {
|
|
161
|
-
return;
|
|
162
|
-
}
|
|
163
|
-
existing = existing.filter(value => toDelete.indexOf(value) === -1);
|
|
164
|
-
if (existing.length === 0) {
|
|
165
|
-
this.headers.delete(key);
|
|
166
|
-
this.normalizedNames.delete(key);
|
|
167
|
-
}
|
|
168
|
-
else {
|
|
169
|
-
this.headers.set(key, existing);
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
break;
|
|
173
|
-
}
|
|
174
|
-
}
|
|
175
|
-
/**
|
|
176
|
-
* @internal
|
|
177
|
-
*/
|
|
178
|
-
forEach(fn) {
|
|
179
|
-
this.init();
|
|
180
|
-
Array.from(this.normalizedNames.keys())
|
|
181
|
-
.forEach(key => fn(this.normalizedNames.get(key), this.headers.get(key)));
|
|
182
|
-
}
|
|
183
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright Google Inc. All Rights Reserved.
|
|
4
|
+
*
|
|
5
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
+
* found in the LICENSE file at https://angular.io/license
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Immutable set of Http headers, with lazy parsing.
|
|
10
|
+
*
|
|
11
|
+
*/
|
|
12
|
+
export class HttpHeaders {
|
|
13
|
+
constructor(headers) {
|
|
14
|
+
/**
|
|
15
|
+
* Internal map of lowercased header names to the normalized
|
|
16
|
+
* form of the name (the form seen first).
|
|
17
|
+
*/
|
|
18
|
+
this.normalizedNames = new Map();
|
|
19
|
+
/**
|
|
20
|
+
* Queued updates to be materialized the next initialization.
|
|
21
|
+
*/
|
|
22
|
+
this.lazyUpdate = null;
|
|
23
|
+
if (!headers) {
|
|
24
|
+
this.headers = new Map();
|
|
25
|
+
}
|
|
26
|
+
else if (typeof headers === 'string') {
|
|
27
|
+
this.lazyInit = () => {
|
|
28
|
+
this.headers = new Map();
|
|
29
|
+
headers.split('\n').forEach(line => {
|
|
30
|
+
const index = line.indexOf(':');
|
|
31
|
+
if (index > 0) {
|
|
32
|
+
const name = line.slice(0, index);
|
|
33
|
+
const key = name.toLowerCase();
|
|
34
|
+
const value = line.slice(index + 1).trim();
|
|
35
|
+
this.maybeSetNormalizedName(name, key);
|
|
36
|
+
if (this.headers.has(key)) {
|
|
37
|
+
this.headers.get(key).push(value);
|
|
38
|
+
}
|
|
39
|
+
else {
|
|
40
|
+
this.headers.set(key, [value]);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
});
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
else {
|
|
47
|
+
this.lazyInit = () => {
|
|
48
|
+
this.headers = new Map();
|
|
49
|
+
Object.keys(headers).forEach(name => {
|
|
50
|
+
let values = headers[name];
|
|
51
|
+
const key = name.toLowerCase();
|
|
52
|
+
if (typeof values === 'string') {
|
|
53
|
+
values = [values];
|
|
54
|
+
}
|
|
55
|
+
if (values.length > 0) {
|
|
56
|
+
this.headers.set(key, values);
|
|
57
|
+
this.maybeSetNormalizedName(name, key);
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Checks for existence of header by given name.
|
|
65
|
+
*/
|
|
66
|
+
has(name) {
|
|
67
|
+
this.init();
|
|
68
|
+
return this.headers.has(name.toLowerCase());
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Returns first header that matches given name.
|
|
72
|
+
*/
|
|
73
|
+
get(name) {
|
|
74
|
+
this.init();
|
|
75
|
+
const values = this.headers.get(name.toLowerCase());
|
|
76
|
+
return values && values.length > 0 ? values[0] : null;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Returns the names of the headers
|
|
80
|
+
*/
|
|
81
|
+
keys() {
|
|
82
|
+
this.init();
|
|
83
|
+
return Array.from(this.normalizedNames.values());
|
|
84
|
+
}
|
|
85
|
+
/**
|
|
86
|
+
* Returns list of header values for a given name.
|
|
87
|
+
*/
|
|
88
|
+
getAll(name) {
|
|
89
|
+
this.init();
|
|
90
|
+
return this.headers.get(name.toLowerCase()) || null;
|
|
91
|
+
}
|
|
92
|
+
append(name, value) {
|
|
93
|
+
return this.clone({ name, value, op: 'a' });
|
|
94
|
+
}
|
|
95
|
+
set(name, value) {
|
|
96
|
+
return this.clone({ name, value, op: 's' });
|
|
97
|
+
}
|
|
98
|
+
delete(name, value) {
|
|
99
|
+
return this.clone({ name, value, op: 'd' });
|
|
100
|
+
}
|
|
101
|
+
maybeSetNormalizedName(name, lcName) {
|
|
102
|
+
if (!this.normalizedNames.has(lcName)) {
|
|
103
|
+
this.normalizedNames.set(lcName, name);
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
init() {
|
|
107
|
+
if (!!this.lazyInit) {
|
|
108
|
+
if (this.lazyInit instanceof HttpHeaders) {
|
|
109
|
+
this.copyFrom(this.lazyInit);
|
|
110
|
+
}
|
|
111
|
+
else {
|
|
112
|
+
this.lazyInit();
|
|
113
|
+
}
|
|
114
|
+
this.lazyInit = null;
|
|
115
|
+
if (!!this.lazyUpdate) {
|
|
116
|
+
this.lazyUpdate.forEach(update => this.applyUpdate(update));
|
|
117
|
+
this.lazyUpdate = null;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
copyFrom(other) {
|
|
122
|
+
other.init();
|
|
123
|
+
Array.from(other.headers.keys()).forEach(key => {
|
|
124
|
+
this.headers.set(key, other.headers.get(key));
|
|
125
|
+
this.normalizedNames.set(key, other.normalizedNames.get(key));
|
|
126
|
+
});
|
|
127
|
+
}
|
|
128
|
+
clone(update) {
|
|
129
|
+
const clone = new HttpHeaders();
|
|
130
|
+
clone.lazyInit =
|
|
131
|
+
(!!this.lazyInit && this.lazyInit instanceof HttpHeaders) ? this.lazyInit : this;
|
|
132
|
+
clone.lazyUpdate = (this.lazyUpdate || []).concat([update]);
|
|
133
|
+
return clone;
|
|
134
|
+
}
|
|
135
|
+
applyUpdate(update) {
|
|
136
|
+
const key = update.name.toLowerCase();
|
|
137
|
+
switch (update.op) {
|
|
138
|
+
case 'a':
|
|
139
|
+
case 's':
|
|
140
|
+
let value = update.value;
|
|
141
|
+
if (typeof value === 'string') {
|
|
142
|
+
value = [value];
|
|
143
|
+
}
|
|
144
|
+
if (value.length === 0) {
|
|
145
|
+
return;
|
|
146
|
+
}
|
|
147
|
+
this.maybeSetNormalizedName(update.name, key);
|
|
148
|
+
const base = (update.op === 'a' ? this.headers.get(key) : undefined) || [];
|
|
149
|
+
base.push(...value);
|
|
150
|
+
this.headers.set(key, base);
|
|
151
|
+
break;
|
|
152
|
+
case 'd':
|
|
153
|
+
const toDelete = update.value;
|
|
154
|
+
if (!toDelete) {
|
|
155
|
+
this.headers.delete(key);
|
|
156
|
+
this.normalizedNames.delete(key);
|
|
157
|
+
}
|
|
158
|
+
else {
|
|
159
|
+
let existing = this.headers.get(key);
|
|
160
|
+
if (!existing) {
|
|
161
|
+
return;
|
|
162
|
+
}
|
|
163
|
+
existing = existing.filter(value => toDelete.indexOf(value) === -1);
|
|
164
|
+
if (existing.length === 0) {
|
|
165
|
+
this.headers.delete(key);
|
|
166
|
+
this.normalizedNames.delete(key);
|
|
167
|
+
}
|
|
168
|
+
else {
|
|
169
|
+
this.headers.set(key, existing);
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
break;
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
/**
|
|
176
|
+
* @internal
|
|
177
|
+
*/
|
|
178
|
+
forEach(fn) {
|
|
179
|
+
this.init();
|
|
180
|
+
Array.from(this.normalizedNames.keys())
|
|
181
|
+
.forEach(key => fn(this.normalizedNames.get(key), this.headers.get(key)));
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
184
|
//# sourceMappingURL=headers.js.map
|
package/dist.esm/headers.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"headers.js","sourceRoot":"","sources":["../src/headers.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAQH;;;GAGG;AACH,MAAM,OAAO,WAAW;IAyBtB,YAAY,OAAoD;QAjBhE;;;WAGG;QACK,oBAAe,GAAwB,IAAI,GAAG,EAAE,CAAC;QAQzD;;WAEG;QACK,eAAU,GAAkB,IAAI,CAAC;QAGvC,IAAI,CAAC,OAAO,EAAE;
|
|
1
|
+
{"version":3,"file":"headers.js","sourceRoot":"","sources":["../src/headers.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAQH;;;GAGG;AACH,MAAM,OAAO,WAAW;IAyBtB,YAAY,OAAoD;QAjBhE;;;WAGG;QACK,oBAAe,GAAwB,IAAI,GAAG,EAAE,CAAC;QAQzD;;WAEG;QACK,eAAU,GAAkB,IAAI,CAAC;QAGvC,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,IAAI,CAAC,OAAO,GAAG,IAAI,GAAG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C,GAAG,EAAE,QAAQ,CAAC,CAAC;oBAClC,CAAC;gBACH,CAAC;gBACD,MAAM;QACV,CAAC;IACH,CAAC;IAED;;OAEG;IACH,OAAO,CAAC,EAA4C;QAClD,IAAI,CAAC,IAAI,EAAE,CAAC;QACZ,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,eAAe,CAAC,IAAI,EAAE,CAAC;aAClC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,CAAC,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,GAAG,CAAG,EAAE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,GAAG,CAAG,CAAC,CAAC,CAAC;IACpF,CAAC;CACF"}
|
package/dist.esm/index.d.ts
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright Google Inc. All Rights Reserved.
|
|
4
|
-
*
|
|
5
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
-
* found in the LICENSE file at https://angular.io/license
|
|
7
|
-
*/
|
|
8
|
-
export { HttpBackend, HttpHandler } from './backend';
|
|
9
|
-
export { HttpClient } from './client';
|
|
10
|
-
export { HttpHeaders } from './headers';
|
|
11
|
-
export { HTTP_INTERCEPTORS, HttpInterceptor } from './interceptor';
|
|
12
|
-
export { HttpClientModule, HttpClientXsrfModule, HttpInterceptingHandler as ɵHttpInterceptingHandler } from './module';
|
|
13
|
-
export { HttpParameterCodec, HttpParams, HttpUrlEncodingCodec } from './params';
|
|
14
|
-
export { HttpRequest } from './request';
|
|
15
|
-
export { HttpDownloadProgressEvent, HttpErrorResponse, HttpEvent, HttpEventType, HttpHeaderResponse, HttpProgressEvent, HttpResponse, HttpResponseBase, HttpSentEvent, HttpUserEvent } from './response';
|
|
16
|
-
export { HttpXhrBackend, XhrFactory } from './xhr';
|
|
17
|
-
export { HttpXsrfTokenExtractor } from './xsrf';
|
|
18
|
-
export { ServerXhr, zoneWrappedInterceptingHandler } from './server';
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright Google Inc. All Rights Reserved.
|
|
4
|
+
*
|
|
5
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
+
* found in the LICENSE file at https://angular.io/license
|
|
7
|
+
*/
|
|
8
|
+
export { HttpBackend, HttpHandler } from './backend';
|
|
9
|
+
export { HttpClient } from './client';
|
|
10
|
+
export { HttpHeaders } from './headers';
|
|
11
|
+
export { HTTP_INTERCEPTORS, HttpInterceptor } from './interceptor';
|
|
12
|
+
export { HttpClientModule, HttpClientXsrfModule, HttpInterceptingHandler as ɵHttpInterceptingHandler } from './module';
|
|
13
|
+
export { HttpParameterCodec, HttpParams, HttpUrlEncodingCodec } from './params';
|
|
14
|
+
export { HttpRequest } from './request';
|
|
15
|
+
export { HttpDownloadProgressEvent, HttpErrorResponse, HttpEvent, HttpEventType, HttpHeaderResponse, HttpProgressEvent, HttpResponse, HttpResponseBase, HttpSentEvent, HttpUserEvent } from './response';
|
|
16
|
+
export { HttpXhrBackend, XhrFactory } from './xhr';
|
|
17
|
+
export { HttpXsrfTokenExtractor } from './xsrf';
|
|
18
|
+
export { ServerXhr, zoneWrappedInterceptingHandler } from './server';
|
|
19
19
|
//# sourceMappingURL=index.d.ts.map
|
package/dist.esm/index.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright Google Inc. All Rights Reserved.
|
|
4
|
-
*
|
|
5
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
-
* found in the LICENSE file at https://angular.io/license
|
|
7
|
-
*/
|
|
8
|
-
export { HttpBackend, HttpHandler } from './backend';
|
|
9
|
-
export { HttpClient } from './client';
|
|
10
|
-
export { HttpHeaders } from './headers';
|
|
11
|
-
export { HTTP_INTERCEPTORS } from './interceptor';
|
|
12
|
-
export { HttpClientModule, HttpClientXsrfModule, HttpInterceptingHandler as ɵHttpInterceptingHandler } from './module';
|
|
13
|
-
export { HttpParams, HttpUrlEncodingCodec } from './params';
|
|
14
|
-
export { HttpRequest } from './request';
|
|
15
|
-
export { HttpErrorResponse, HttpEventType, HttpHeaderResponse, HttpResponse, HttpResponseBase } from './response';
|
|
16
|
-
export { HttpXhrBackend, XhrFactory } from './xhr';
|
|
17
|
-
export { HttpXsrfTokenExtractor } from './xsrf';
|
|
18
|
-
export { ServerXhr, zoneWrappedInterceptingHandler } from './server';
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright Google Inc. All Rights Reserved.
|
|
4
|
+
*
|
|
5
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
+
* found in the LICENSE file at https://angular.io/license
|
|
7
|
+
*/
|
|
8
|
+
export { HttpBackend, HttpHandler } from './backend';
|
|
9
|
+
export { HttpClient } from './client';
|
|
10
|
+
export { HttpHeaders } from './headers';
|
|
11
|
+
export { HTTP_INTERCEPTORS } from './interceptor';
|
|
12
|
+
export { HttpClientModule, HttpClientXsrfModule, HttpInterceptingHandler as ɵHttpInterceptingHandler } from './module';
|
|
13
|
+
export { HttpParams, HttpUrlEncodingCodec } from './params';
|
|
14
|
+
export { HttpRequest } from './request';
|
|
15
|
+
export { HttpErrorResponse, HttpEventType, HttpHeaderResponse, HttpResponse, HttpResponseBase } from './response';
|
|
16
|
+
export { HttpXhrBackend, XhrFactory } from './xhr';
|
|
17
|
+
export { HttpXsrfTokenExtractor } from './xsrf';
|
|
18
|
+
export { ServerXhr, zoneWrappedInterceptingHandler } from './server';
|
|
19
19
|
//# sourceMappingURL=index.js.map
|