Refactor pgio and types to append buffers
This commit is contained in:
+4
-5
@@ -2,7 +2,6 @@ package pgtype
|
||||
|
||||
import (
|
||||
"database/sql/driver"
|
||||
"io"
|
||||
)
|
||||
|
||||
// OidValue (Object Identifier Type) is, according to
|
||||
@@ -37,12 +36,12 @@ func (dst *OidValue) DecodeBinary(ci *ConnInfo, src []byte) error {
|
||||
return (*pguint32)(dst).DecodeBinary(ci, src)
|
||||
}
|
||||
|
||||
func (src *OidValue) EncodeText(ci *ConnInfo, w io.Writer) (bool, error) {
|
||||
return (*pguint32)(src).EncodeText(ci, w)
|
||||
func (src *OidValue) EncodeText(ci *ConnInfo, buf []byte) ([]byte, error) {
|
||||
return (*pguint32)(src).EncodeText(ci, buf)
|
||||
}
|
||||
|
||||
func (src *OidValue) EncodeBinary(ci *ConnInfo, w io.Writer) (bool, error) {
|
||||
return (*pguint32)(src).EncodeBinary(ci, w)
|
||||
func (src *OidValue) EncodeBinary(ci *ConnInfo, buf []byte) ([]byte, error) {
|
||||
return (*pguint32)(src).EncodeBinary(ci, buf)
|
||||
}
|
||||
|
||||
// Scan implements the database/sql Scanner interface.
|
||||
|
||||
Reference in New Issue
Block a user