refactor - pasdns can now look sane 3.0
This commit is contained in:
parent
57fbfbf059
commit
61f89c8067
7 changed files with 3 additions and 3 deletions
35
Constants/constants.go
Normal file
35
Constants/constants.go
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
package Constants
|
||||
|
||||
type Method string
|
||||
type OperationSuccessClassification string
|
||||
|
||||
const (
|
||||
UNKNOWN Method = "wtf bro"
|
||||
GET Method = "GET"
|
||||
POST Method = "POST"
|
||||
)
|
||||
|
||||
const (
|
||||
OK OperationSuccessClassification = "OK"
|
||||
INTERNALSERVERERROR OperationSuccessClassification = "SERVERSHATITSELF"
|
||||
BADREQUEST OperationSuccessClassification = "BRUH"
|
||||
NOTFOUND OperationSuccessClassification = "NOTFOUND"
|
||||
)
|
||||
|
||||
type Request struct {
|
||||
Intent Intent
|
||||
Body string
|
||||
}
|
||||
|
||||
type Response struct {
|
||||
OperationSuccessClassification OperationSuccessClassification
|
||||
ResponseHeader map[string]string
|
||||
Body string
|
||||
}
|
||||
|
||||
type Intent struct {
|
||||
Method Method
|
||||
Path string
|
||||
Version string
|
||||
Headers map[string]string
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue