Versions in this module Expand all Collapse all v1 v1.1.0 Apr 17, 2019 Changes in this version + const AuthTypeSASL + const AuthTypeSASLContinue + const AuthTypeSASLFinal type Authentication + SASLAuthMechanisms []string + SASLData []byte + type SASLInitialResponse struct + AuthMechanism string + Data []byte + func (*SASLInitialResponse) Frontend() + func (dst *SASLInitialResponse) Decode(src []byte) error + func (src *SASLInitialResponse) Encode(dst []byte) []byte + func (src *SASLInitialResponse) MarshalJSON() ([]byte, error) + type SASLResponse struct + Data []byte + func (*SASLResponse) Frontend() + func (dst *SASLResponse) Decode(src []byte) error + func (src *SASLResponse) Encode(dst []byte) []byte + func (src *SASLResponse) MarshalJSON() ([]byte, error) v1.0.0 Mar 30, 2019 Changes in this version + const AuthTypeCleartextPassword + const AuthTypeMD5Password + const AuthTypeOk + const BinaryFormat + const ProtocolVersionNumber + const TextFormat + type Authentication struct + Salt [4]byte + Type uint32 + func (*Authentication) Backend() + func (dst *Authentication) Decode(src []byte) error + func (src *Authentication) Encode(dst []byte) []byte + type Backend struct + func NewBackend(cr ChunkReader, w io.Writer) (*Backend, error) + func (b *Backend) Receive() (FrontendMessage, error) + func (b *Backend) ReceiveStartupMessage() (*StartupMessage, error) + func (b *Backend) Send(msg BackendMessage) error + type BackendKeyData struct + ProcessID uint32 + SecretKey uint32 + func (*BackendKeyData) Backend() + func (dst *BackendKeyData) Decode(src []byte) error + func (src *BackendKeyData) Encode(dst []byte) []byte + func (src *BackendKeyData) MarshalJSON() ([]byte, error) + type BackendMessage interface + Backend func() + type BigEndianBuf [8]byte + func (b BigEndianBuf) Int16(n int16) []byte + func (b BigEndianBuf) Int32(n int32) []byte + func (b BigEndianBuf) Int64(n int64) []byte + func (b BigEndianBuf) Uint16(n uint16) []byte + func (b BigEndianBuf) Uint32(n uint32) []byte + type Bind struct + DestinationPortal string + ParameterFormatCodes []int16 + Parameters [][]byte + PreparedStatement string + ResultFormatCodes []int16 + func (*Bind) Frontend() + func (dst *Bind) Decode(src []byte) error + func (src *Bind) Encode(dst []byte) []byte + func (src *Bind) MarshalJSON() ([]byte, error) + type BindComplete struct + func (*BindComplete) Backend() + func (dst *BindComplete) Decode(src []byte) error + func (src *BindComplete) Encode(dst []byte) []byte + func (src *BindComplete) MarshalJSON() ([]byte, error) + type ChunkReader interface + Next func(n int) (buf []byte, err error) + func NewChunkReader(r io.Reader) ChunkReader + type Close struct + Name string + ObjectType byte + func (*Close) Frontend() + func (dst *Close) Decode(src []byte) error + func (src *Close) Encode(dst []byte) []byte + func (src *Close) MarshalJSON() ([]byte, error) + type CloseComplete struct + func (*CloseComplete) Backend() + func (dst *CloseComplete) Decode(src []byte) error + func (src *CloseComplete) Encode(dst []byte) []byte + func (src *CloseComplete) MarshalJSON() ([]byte, error) + type CommandComplete struct + CommandTag string + func (*CommandComplete) Backend() + func (dst *CommandComplete) Decode(src []byte) error + func (src *CommandComplete) Encode(dst []byte) []byte + func (src *CommandComplete) MarshalJSON() ([]byte, error) + type CopyBothResponse struct + ColumnFormatCodes []uint16 + OverallFormat byte + func (*CopyBothResponse) Backend() + func (dst *CopyBothResponse) Decode(src []byte) error + func (src *CopyBothResponse) Encode(dst []byte) []byte + func (src *CopyBothResponse) MarshalJSON() ([]byte, error) + type CopyData struct + Data []byte + func (*CopyData) Backend() + func (*CopyData) Frontend() + func (dst *CopyData) Decode(src []byte) error + func (src *CopyData) Encode(dst []byte) []byte + func (src *CopyData) MarshalJSON() ([]byte, error) + type CopyDone struct + func (*CopyDone) Backend() + func (dst *CopyDone) Decode(src []byte) error + func (src *CopyDone) Encode(dst []byte) []byte + func (src *CopyDone) MarshalJSON() ([]byte, error) + type CopyFail struct + Error string + func (*CopyFail) Backend() + func (*CopyFail) Frontend() + func (dst *CopyFail) Decode(src []byte) error + func (src *CopyFail) Encode(dst []byte) []byte + func (src *CopyFail) MarshalJSON() ([]byte, error) + type CopyInResponse struct + ColumnFormatCodes []uint16 + OverallFormat byte + func (*CopyInResponse) Backend() + func (dst *CopyInResponse) Decode(src []byte) error + func (src *CopyInResponse) Encode(dst []byte) []byte + func (src *CopyInResponse) MarshalJSON() ([]byte, error) + type CopyOutResponse struct + ColumnFormatCodes []uint16 + OverallFormat byte + func (*CopyOutResponse) Backend() + func (dst *CopyOutResponse) Decode(src []byte) error + func (src *CopyOutResponse) Encode(dst []byte) []byte + func (src *CopyOutResponse) MarshalJSON() ([]byte, error) + type DataRow struct + Values [][]byte + func (*DataRow) Backend() + func (dst *DataRow) Decode(src []byte) error + func (src *DataRow) Encode(dst []byte) []byte + func (src *DataRow) MarshalJSON() ([]byte, error) + type Describe struct + Name string + ObjectType byte + func (*Describe) Frontend() + func (dst *Describe) Decode(src []byte) error + func (src *Describe) Encode(dst []byte) []byte + func (src *Describe) MarshalJSON() ([]byte, error) + type EmptyQueryResponse struct + func (*EmptyQueryResponse) Backend() + func (dst *EmptyQueryResponse) Decode(src []byte) error + func (src *EmptyQueryResponse) Encode(dst []byte) []byte + func (src *EmptyQueryResponse) MarshalJSON() ([]byte, error) + type ErrorResponse struct + Code string + ColumnName string + ConstraintName string + DataTypeName string + Detail string + File string + Hint string + InternalPosition int32 + InternalQuery string + Line int32 + Message string + Position int32 + Routine string + SchemaName string + Severity string + TableName string + UnknownFields map[byte]string + Where string + func (*ErrorResponse) Backend() + func (dst *ErrorResponse) Decode(src []byte) error + func (src *ErrorResponse) Encode(dst []byte) []byte + type Execute struct + MaxRows uint32 + Portal string + func (*Execute) Frontend() + func (dst *Execute) Decode(src []byte) error + func (src *Execute) Encode(dst []byte) []byte + func (src *Execute) MarshalJSON() ([]byte, error) + type FieldDescription struct + DataTypeOID uint32 + DataTypeSize int16 + Format int16 + Name string + TableAttributeNumber uint16 + TableOID uint32 + TypeModifier int32 + type Flush struct + func (*Flush) Frontend() + func (dst *Flush) Decode(src []byte) error + func (src *Flush) Encode(dst []byte) []byte + func (src *Flush) MarshalJSON() ([]byte, error) + type Frontend struct + func NewFrontend(cr ChunkReader, w io.Writer) (*Frontend, error) + func (b *Frontend) Receive() (BackendMessage, error) + func (b *Frontend) Send(msg FrontendMessage) error + type FrontendMessage interface + Frontend func() + type FunctionCallResponse struct + Result []byte + func (*FunctionCallResponse) Backend() + func (dst *FunctionCallResponse) Decode(src []byte) error + func (src *FunctionCallResponse) Encode(dst []byte) []byte + func (src *FunctionCallResponse) MarshalJSON() ([]byte, error) + type Message interface + Decode func(data []byte) error + Encode func(dst []byte) []byte + type NoData struct + func (*NoData) Backend() + func (dst *NoData) Decode(src []byte) error + func (src *NoData) Encode(dst []byte) []byte + func (src *NoData) MarshalJSON() ([]byte, error) + type NoticeResponse ErrorResponse + func (*NoticeResponse) Backend() + func (dst *NoticeResponse) Decode(src []byte) error + func (src *NoticeResponse) Encode(dst []byte) []byte + type NotificationResponse struct + Channel string + PID uint32 + Payload string + func (*NotificationResponse) Backend() + func (dst *NotificationResponse) Decode(src []byte) error + func (src *NotificationResponse) Encode(dst []byte) []byte + func (src *NotificationResponse) MarshalJSON() ([]byte, error) + type ParameterDescription struct + ParameterOIDs []uint32 + func (*ParameterDescription) Backend() + func (dst *ParameterDescription) Decode(src []byte) error + func (src *ParameterDescription) Encode(dst []byte) []byte + func (src *ParameterDescription) MarshalJSON() ([]byte, error) + type ParameterStatus struct + Name string + Value string + func (*ParameterStatus) Backend() + func (dst *ParameterStatus) Decode(src []byte) error + func (ps *ParameterStatus) MarshalJSON() ([]byte, error) + func (src *ParameterStatus) Encode(dst []byte) []byte + type Parse struct + Name string + ParameterOIDs []uint32 + Query string + func (*Parse) Frontend() + func (dst *Parse) Decode(src []byte) error + func (src *Parse) Encode(dst []byte) []byte + func (src *Parse) MarshalJSON() ([]byte, error) + type ParseComplete struct + func (*ParseComplete) Backend() + func (dst *ParseComplete) Decode(src []byte) error + func (src *ParseComplete) Encode(dst []byte) []byte + func (src *ParseComplete) MarshalJSON() ([]byte, error) + type PasswordMessage struct + Password string + func (*PasswordMessage) Frontend() + func (dst *PasswordMessage) Decode(src []byte) error + func (src *PasswordMessage) Encode(dst []byte) []byte + func (src *PasswordMessage) MarshalJSON() ([]byte, error) + type Query struct + String string + func (*Query) Frontend() + func (dst *Query) Decode(src []byte) error + func (src *Query) Encode(dst []byte) []byte + func (src *Query) MarshalJSON() ([]byte, error) + type ReadyForQuery struct + TxStatus byte + func (*ReadyForQuery) Backend() + func (dst *ReadyForQuery) Decode(src []byte) error + func (src *ReadyForQuery) Encode(dst []byte) []byte + func (src *ReadyForQuery) MarshalJSON() ([]byte, error) + type RowDescription struct + Fields []FieldDescription + func (*RowDescription) Backend() + func (dst *RowDescription) Decode(src []byte) error + func (src *RowDescription) Encode(dst []byte) []byte + func (src *RowDescription) MarshalJSON() ([]byte, error) + type StartupMessage struct + Parameters map[string]string + ProtocolVersion uint32 + func (*StartupMessage) Frontend() + func (dst *StartupMessage) Decode(src []byte) error + func (src *StartupMessage) Encode(dst []byte) []byte + func (src *StartupMessage) MarshalJSON() ([]byte, error) + type Sync struct + func (*Sync) Frontend() + func (dst *Sync) Decode(src []byte) error + func (src *Sync) Encode(dst []byte) []byte + func (src *Sync) MarshalJSON() ([]byte, error) + type Terminate struct + func (*Terminate) Frontend() + func (dst *Terminate) Decode(src []byte) error + func (src *Terminate) Encode(dst []byte) []byte + func (src *Terminate) MarshalJSON() ([]byte, error) Other modules containing this package github.com/jackc/pgproto3/v2