mirror of
https://github.com/Teamlinker/Teamlinker.git
synced 2025-06-03 03:00:17 +00:00
24 lines
548 B
TypeScript
24 lines
548 B
TypeScript
export default class HttpHeader {
|
|
private incomingHeaders:{
|
|
[param:string]:string
|
|
}={}
|
|
private outcomingHeaders:{
|
|
[param:string]:string
|
|
}={}
|
|
constructor(headers:{
|
|
[param:string]:string
|
|
}){
|
|
for(let key in headers){
|
|
this.incomingHeaders[key]=headers[key]
|
|
}
|
|
}
|
|
get(key:string){
|
|
return this.incomingHeaders[key]
|
|
}
|
|
set(key:string,value:string){
|
|
this.outcomingHeaders[key]=value
|
|
}
|
|
get values(){
|
|
return this.outcomingHeaders
|
|
}
|
|
} |