Source File
	ssl_request.go
Belonging Package
	github.com/jackc/pgx/v5/pgproto3
package pgproto3import ()const sslRequestNumber = 80877103type SSLRequest struct {}// Frontend identifies this message as sendable by a PostgreSQL frontend.func (*SSLRequest) () {}func ( *SSLRequest) ( []byte) error {if len() < 4 {return errors.New("ssl request too short")}:= binary.BigEndian.Uint32()if != sslRequestNumber {return errors.New("bad ssl request code")}return nil}// Encode encodes src into dst. dst will include the 4 byte message length.func ( *SSLRequest) ( []byte) []byte {= pgio.AppendInt32(, 8)= pgio.AppendInt32(, sslRequestNumber)return}// MarshalJSON implements encoding/json.Marshaler.func ( SSLRequest) () ([]byte, error) {return json.Marshal(struct {stringuint32map[string]string}{: "SSLRequest",})}
![]()  | 
The pages are generated with Golds v0.6.7. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @Go100and1 (reachable from the left QR code) to get the latest news of Golds. |