2019-01-02 00:00:53 +00:00
import { HttpStatus , TStatusGroup } from './smartstatus.classes.http' ;
2017-04-06 15:00:38 +00:00
2019-01-02 01:08:12 +00:00
export class Status500 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 500 ,
text : 'Internal Server Error' ,
description :
'A generic error message, given when an unexpected condition was encountered and no more specific message is suitable.'
} ) ;
2017-04-06 15:00:38 +00:00
}
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '500' , Status500 ) ;
2017-04-11 15:02:15 +00:00
2019-01-02 01:08:12 +00:00
// tslint:disable-next-line: max-classes-per-file
export class Status501 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 501 ,
text : 'Bad Request' ,
description : ` The server cannot or will not process the request due to an apparent client error (e.g., malformed request syntax, too large size, invalid request message framing, or deceptive request routing). `
} ) ;
2017-04-11 15:02:15 +00:00
}
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '501' , Status501 ) ;
2017-04-11 15:02:15 +00:00
2019-01-02 01:08:12 +00:00
// tslint:disable-next-line: max-classes-per-file
export class Status502 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 502 ,
text : 'Payment Required' ,
description : ` The request was valid, but the server is refusing action. The user might not have the necessary permissions for a resource. `
} ) ;
2017-04-11 15:02:15 +00:00
}
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '502' , Status502 ) ;
2017-04-11 15:02:15 +00:00
2019-01-02 01:08:12 +00:00
// tslint:disable-next-line: max-classes-per-file
export class Status503 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 503 ,
text : 'Forbidden' ,
description : ` The request was valid, but the server is refusing action. The user might not have the necessary permissions for a resource. `
} ) ;
2017-04-11 15:02:15 +00:00
}
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '503' , Status503 ) ;
2017-04-11 15:02:15 +00:00
2019-01-02 01:08:12 +00:00
// tslint:disable-next-line: max-classes-per-file
export class Status504 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 504 ,
text : 'Gateway Time-out' ,
description : ` The server was acting as a gateway or proxy
2017-04-11 15:02:15 +00:00
and did not receive a timely response from the upstream server . `
2019-01-02 00:00:53 +00:00
} ) ;
2017-04-11 15:02:15 +00:00
}
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '504' , Status504 ) ;
2017-04-11 15:02:15 +00:00
2019-01-02 01:08:12 +00:00
// tslint:disable-next-line: max-classes-per-file
export class Status505 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 505 ,
text : 'HTTP Version Not Supported' ,
description : ` The server does not support the HTTP protocol version used in the request. `
} ) ;
2017-04-11 15:02:15 +00:00
}
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '505' , Status505 ) ;
2017-04-11 15:02:15 +00:00
2019-01-02 01:08:12 +00:00
// tslint:disable-next-line: max-classes-per-file
export class Status506 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 506 ,
text : 'Variant Also Negotiates' ,
description : ` Transparent content negotiation for the request results in a circular reference. `
} ) ;
2017-04-11 15:02:15 +00:00
}
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '506' , Status506 ) ;
// tslint:disable-next-line: max-classes-per-file
export class Status507 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 507 ,
text : 'Insufficient Storage' ,
description : ` The server is unable to store the representation needed to complete the request. `
} ) ;
2017-04-11 15:02:15 +00:00
}
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '507' , Status507 ) ;
// tslint:disable-next-line: max-classes-per-file
export class Status508 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 508 ,
text : 'Loop Detected' ,
description : ` The server detected an infinite loop while processing the request `
} ) ;
2017-04-11 15:02:15 +00:00
}
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '508' , Status508 ) ;
2017-04-11 15:02:15 +00:00
2019-01-02 01:08:12 +00:00
// tslint:disable-next-line: max-classes-per-file
export class Status510 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 510 ,
text : 'Loop Detected' ,
description : ` The server detected an infinite loop while processing the request `
} ) ;
2017-04-11 15:02:15 +00:00
}
}
2019-01-02 01:08:12 +00:00
// tslint:disable-next-line: max-classes-per-file
export class Status511 extends HttpStatus {
2019-01-02 00:00:53 +00:00
constructor ( ) {
super ( {
code : 511 ,
text : 'Network Authentication Required' ,
description : ` The client needs to authenticate to gain network access.
2017-04-11 15:02:15 +00:00
Intended for use by intercepting proxies used to control access to the network
( e . g . , "captive portals" used to require agreement to Terms of Service before granting full Internet access via a Wi - Fi hotspot ) `
2019-01-02 00:00:53 +00:00
} ) ;
2017-04-11 15:02:15 +00:00
}
2019-01-02 00:00:53 +00:00
}
2019-01-02 01:08:12 +00:00
HttpStatus . addStatus ( '511' , Status511 ) ;