Get implemented on T instead of *T
Methods defined on T are also available on *T. Thought this technically
changes the interface, because *T will be automatically dereferenced as
needed it shouldn't be a breaking change.
See a8802b16cc for similar change.
This commit is contained in:
+1
-1
@@ -43,7 +43,7 @@ func (dst *ACLItem) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *ACLItem) Get() interface{} {
|
||||
func (dst ACLItem) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.String
|
||||
|
||||
+1
-1
@@ -62,7 +62,7 @@ func (dst *ACLItemArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *ACLItemArray) Get() interface{} {
|
||||
func (dst ACLItemArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -10,8 +10,8 @@ func (dst *Bit) Set(src interface{}) error {
|
||||
return (*Varbit)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *Bit) Get() interface{} {
|
||||
return (*Varbit)(dst).Get()
|
||||
func (dst Bit) Get() interface{} {
|
||||
return (Varbit)(dst).Get()
|
||||
}
|
||||
|
||||
func (src *Bit) AssignTo(dst interface{}) error {
|
||||
|
||||
@@ -38,7 +38,7 @@ func (dst *Bool) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Bool) Get() interface{} {
|
||||
func (dst Bool) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Bool
|
||||
|
||||
+1
-1
@@ -64,7 +64,7 @@ func (dst *BoolArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *BoolArray) Get() interface{} {
|
||||
func (dst BoolArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -21,7 +21,7 @@ func (dst *Box) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Box", src)
|
||||
}
|
||||
|
||||
func (dst *Box) Get() interface{} {
|
||||
func (dst Box) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -14,8 +14,8 @@ func (dst *BPChar) Set(src interface{}) error {
|
||||
}
|
||||
|
||||
// Get returns underlying value
|
||||
func (dst *BPChar) Get() interface{} {
|
||||
return (*Text)(dst).Get()
|
||||
func (dst BPChar) Get() interface{} {
|
||||
return (Text)(dst).Get()
|
||||
}
|
||||
|
||||
// AssignTo assigns from src to dst.
|
||||
|
||||
+1
-1
@@ -64,7 +64,7 @@ func (dst *BPCharArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *BPCharArray) Get() interface{} {
|
||||
func (dst BPCharArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -35,7 +35,7 @@ func (dst *Bytea) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Bytea) Get() interface{} {
|
||||
func (dst Bytea) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Bytes
|
||||
|
||||
+1
-1
@@ -64,7 +64,7 @@ func (dst *ByteaArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *ByteaArray) Get() interface{} {
|
||||
func (dst ByteaArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -24,8 +24,8 @@ func (dst *CID) Set(src interface{}) error {
|
||||
return (*pguint32)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *CID) Get() interface{} {
|
||||
return (*pguint32)(dst).Get()
|
||||
func (dst CID) Get() interface{} {
|
||||
return (pguint32)(dst).Get()
|
||||
}
|
||||
|
||||
// AssignTo assigns from src to dst. Note that as CID is not a general number
|
||||
|
||||
@@ -6,8 +6,8 @@ func (dst *CIDR) Set(src interface{}) error {
|
||||
return (*Inet)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *CIDR) Get() interface{} {
|
||||
return (*Inet)(dst).Get()
|
||||
func (dst CIDR) Get() interface{} {
|
||||
return (Inet)(dst).Get()
|
||||
}
|
||||
|
||||
func (src *CIDR) AssignTo(dst interface{}) error {
|
||||
|
||||
+1
-1
@@ -84,7 +84,7 @@ func (dst *CIDRArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *CIDRArray) Get() interface{} {
|
||||
func (dst CIDRArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -22,7 +22,7 @@ func (dst *Circle) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Circle", src)
|
||||
}
|
||||
|
||||
func (dst *Circle) Get() interface{} {
|
||||
func (dst Circle) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -40,7 +40,7 @@ func (dst *Date) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Date) Get() interface{} {
|
||||
func (dst Date) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
if dst.InfinityModifier != None {
|
||||
|
||||
+1
-1
@@ -65,7 +65,7 @@ func (dst *DateArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *DateArray) Get() interface{} {
|
||||
func (dst DateArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -19,7 +19,7 @@ func (dst *Daterange) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Daterange", src)
|
||||
}
|
||||
|
||||
func (dst *Daterange) Get() interface{} {
|
||||
func (dst Daterange) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -62,7 +62,7 @@ func (dst *EnumArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *EnumArray) Get() interface{} {
|
||||
func (dst EnumArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -47,7 +47,7 @@ func (dst *UUID) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *UUID) Get() interface{} {
|
||||
func (dst UUID) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case pgtype.Present:
|
||||
return dst.UUID
|
||||
|
||||
@@ -89,7 +89,7 @@ func (dst *Numeric) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Numeric) Get() interface{} {
|
||||
func (dst Numeric) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case pgtype.Present:
|
||||
return dst.Decimal
|
||||
|
||||
@@ -92,7 +92,7 @@ func (dst *Float4) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Float4) Get() interface{} {
|
||||
func (dst Float4) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Float
|
||||
|
||||
+1
-1
@@ -64,7 +64,7 @@ func (dst *Float4Array) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Float4Array) Get() interface{} {
|
||||
func (dst Float4Array) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -82,7 +82,7 @@ func (dst *Float8) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Float8) Get() interface{} {
|
||||
func (dst Float8) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Float
|
||||
|
||||
+1
-1
@@ -64,7 +64,7 @@ func (dst *Float8Array) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Float8Array) Get() interface{} {
|
||||
func (dst Float8Array) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+2
-2
@@ -12,8 +12,8 @@ func (dst *GenericBinary) Set(src interface{}) error {
|
||||
return (*Bytea)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *GenericBinary) Get() interface{} {
|
||||
return (*Bytea)(dst).Get()
|
||||
func (dst GenericBinary) Get() interface{} {
|
||||
return (Bytea)(dst).Get()
|
||||
}
|
||||
|
||||
func (src *GenericBinary) AssignTo(dst interface{}) error {
|
||||
|
||||
+2
-2
@@ -12,8 +12,8 @@ func (dst *GenericText) Set(src interface{}) error {
|
||||
return (*Text)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *GenericText) Get() interface{} {
|
||||
return (*Text)(dst).Get()
|
||||
func (dst GenericText) Get() interface{} {
|
||||
return (Text)(dst).Get()
|
||||
}
|
||||
|
||||
func (src *GenericText) AssignTo(dst interface{}) error {
|
||||
|
||||
@@ -40,7 +40,7 @@ func (dst *Hstore) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Hstore) Get() interface{} {
|
||||
func (dst Hstore) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Map
|
||||
|
||||
+1
-1
@@ -64,7 +64,7 @@ func (dst *HstoreArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *HstoreArray) Get() interface{} {
|
||||
func (dst HstoreArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -52,7 +52,7 @@ func (dst *Inet) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Inet) Get() interface{} {
|
||||
func (dst Inet) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.IPNet
|
||||
|
||||
+1
-1
@@ -84,7 +84,7 @@ func (dst *InetArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *InetArray) Get() interface{} {
|
||||
func (dst InetArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -88,7 +88,7 @@ func (dst *Int2) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Int2) Get() interface{} {
|
||||
func (dst Int2) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Int
|
||||
|
||||
+1
-1
@@ -197,7 +197,7 @@ func (dst *Int2Array) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Int2Array) Get() interface{} {
|
||||
func (dst Int2Array) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -80,7 +80,7 @@ func (dst *Int4) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Int4) Get() interface{} {
|
||||
func (dst Int4) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Int
|
||||
|
||||
+1
-1
@@ -197,7 +197,7 @@ func (dst *Int4Array) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Int4Array) Get() interface{} {
|
||||
func (dst Int4Array) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -19,7 +19,7 @@ func (dst *Int4range) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Int4range", src)
|
||||
}
|
||||
|
||||
func (dst *Int4range) Get() interface{} {
|
||||
func (dst Int4range) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -71,7 +71,7 @@ func (dst *Int8) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Int8) Get() interface{} {
|
||||
func (dst Int8) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Int
|
||||
|
||||
+1
-1
@@ -197,7 +197,7 @@ func (dst *Int8Array) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Int8Array) Get() interface{} {
|
||||
func (dst Int8Array) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -19,7 +19,7 @@ func (dst *Int8range) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Int8range", src)
|
||||
}
|
||||
|
||||
func (dst *Int8range) Get() interface{} {
|
||||
func (dst Int8range) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -44,7 +44,7 @@ func (dst *Interval) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Interval) Get() interface{} {
|
||||
func (dst Interval) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -53,7 +53,7 @@ func (dst *JSON) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *JSON) Get() interface{} {
|
||||
func (dst JSON) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
var i interface{}
|
||||
|
||||
@@ -12,8 +12,8 @@ func (dst *JSONB) Set(src interface{}) error {
|
||||
return (*JSON)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *JSONB) Get() interface{} {
|
||||
return (*JSON)(dst).Get()
|
||||
func (dst JSONB) Get() interface{} {
|
||||
return (JSON)(dst).Get()
|
||||
}
|
||||
|
||||
func (src *JSONB) AssignTo(dst interface{}) error {
|
||||
|
||||
@@ -21,7 +21,7 @@ func (dst *Line) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Line", src)
|
||||
}
|
||||
|
||||
func (dst *Line) Get() interface{} {
|
||||
func (dst Line) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -21,7 +21,7 @@ func (dst *Lseg) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Lseg", src)
|
||||
}
|
||||
|
||||
func (dst *Lseg) Get() interface{} {
|
||||
func (dst Lseg) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -39,7 +39,7 @@ func (dst *Macaddr) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Macaddr) Get() interface{} {
|
||||
func (dst Macaddr) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Addr
|
||||
|
||||
+1
-1
@@ -65,7 +65,7 @@ func (dst *MacaddrArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *MacaddrArray) Get() interface{} {
|
||||
func (dst MacaddrArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -23,8 +23,8 @@ func (dst *Name) Set(src interface{}) error {
|
||||
return (*Text)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *Name) Get() interface{} {
|
||||
return (*Text)(dst).Get()
|
||||
func (dst Name) Get() interface{} {
|
||||
return (Text)(dst).Get()
|
||||
}
|
||||
|
||||
func (src *Name) AssignTo(dst interface{}) error {
|
||||
|
||||
+1
-1
@@ -104,7 +104,7 @@ func (dst *Numeric) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Numeric) Get() interface{} {
|
||||
func (dst Numeric) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -121,7 +121,7 @@ func (dst *NumericArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *NumericArray) Get() interface{} {
|
||||
func (dst NumericArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -19,7 +19,7 @@ func (dst *Numrange) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Numrange", src)
|
||||
}
|
||||
|
||||
func (dst *Numrange) Get() interface{} {
|
||||
func (dst Numrange) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+2
-2
@@ -18,8 +18,8 @@ func (dst *OIDValue) Set(src interface{}) error {
|
||||
return (*pguint32)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *OIDValue) Get() interface{} {
|
||||
return (*pguint32)(dst).Get()
|
||||
func (dst OIDValue) Get() interface{} {
|
||||
return (pguint32)(dst).Get()
|
||||
}
|
||||
|
||||
// AssignTo assigns from src to dst. Note that as OIDValue is not a general number
|
||||
|
||||
@@ -22,7 +22,7 @@ func (dst *Path) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Path", src)
|
||||
}
|
||||
|
||||
func (dst *Path) Get() interface{} {
|
||||
func (dst Path) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -39,7 +39,7 @@ func (dst *pguint32) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *pguint32) Get() interface{} {
|
||||
func (dst pguint32) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Uint
|
||||
|
||||
@@ -26,7 +26,7 @@ func (dst *Point) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Point", src)
|
||||
}
|
||||
|
||||
func (dst *Point) Get() interface{} {
|
||||
func (dst Point) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -21,7 +21,7 @@ func (dst *Polygon) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Polygon", src)
|
||||
}
|
||||
|
||||
func (dst *Polygon) Get() interface{} {
|
||||
func (dst Polygon) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -105,7 +105,7 @@ func (dst *QChar) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *QChar) Get() interface{} {
|
||||
func (dst QChar) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Int
|
||||
|
||||
@@ -33,7 +33,7 @@ func (dst *Record) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Record) Get() interface{} {
|
||||
func (dst Record) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Fields
|
||||
|
||||
@@ -43,7 +43,7 @@ func (dst *Text) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Text) Get() interface{} {
|
||||
func (dst Text) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.String
|
||||
|
||||
+1
-1
@@ -64,7 +64,7 @@ func (dst *TextArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *TextArray) Get() interface{} {
|
||||
func (dst TextArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -32,7 +32,7 @@ func (dst *TID) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to TID", src)
|
||||
}
|
||||
|
||||
func (dst *TID) Get() interface{} {
|
||||
func (dst TID) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -45,7 +45,7 @@ func (dst *Time) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Time) Get() interface{} {
|
||||
func (dst Time) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Microseconds
|
||||
|
||||
+1
-1
@@ -43,7 +43,7 @@ func (dst *Timestamp) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Timestamp) Get() interface{} {
|
||||
func (dst Timestamp) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
if dst.InfinityModifier != None {
|
||||
|
||||
+1
-1
@@ -65,7 +65,7 @@ func (dst *TimestampArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *TimestampArray) Get() interface{} {
|
||||
func (dst TimestampArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -45,7 +45,7 @@ func (dst *Timestamptz) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *Timestamptz) Get() interface{} {
|
||||
func (dst Timestamptz) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
if dst.InfinityModifier != None {
|
||||
|
||||
@@ -65,7 +65,7 @@ func (dst *TimestamptzArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *TimestamptzArray) Get() interface{} {
|
||||
func (dst TimestamptzArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -19,7 +19,7 @@ func (dst *Tsrange) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Tsrange", src)
|
||||
}
|
||||
|
||||
func (dst *Tsrange) Get() interface{} {
|
||||
func (dst Tsrange) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -19,7 +19,7 @@ func (dst *Tstzrange) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Tstzrange", src)
|
||||
}
|
||||
|
||||
func (dst *Tstzrange) Get() interface{} {
|
||||
func (dst Tstzrange) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -45,7 +45,7 @@ func (dst *TstzrangeArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *TstzrangeArray) Get() interface{} {
|
||||
func (dst TstzrangeArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -66,7 +66,7 @@ func (dst *<%= pgtype_array_type %>) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *<%= pgtype_array_type %>) Get() interface{} {
|
||||
func (dst <%= pgtype_array_type %>) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+1
-1
@@ -21,7 +21,7 @@ func (dst *<%= range_type %>) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to <%= range_type %>", src)
|
||||
}
|
||||
|
||||
func (dst *<%= range_type %>) Get() interface{} {
|
||||
func (dst <%= range_type %>) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+2
-2
@@ -15,8 +15,8 @@ func (dst *Unknown) Set(src interface{}) error {
|
||||
return (*Text)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *Unknown) Get() interface{} {
|
||||
return (*Text)(dst).Get()
|
||||
func (dst Unknown) Get() interface{} {
|
||||
return (Text)(dst).Get()
|
||||
}
|
||||
|
||||
// AssignTo assigns from src to dst. Note that as Unknown is not a general number
|
||||
|
||||
@@ -48,7 +48,7 @@ func (dst *UUID) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *UUID) Get() interface{} {
|
||||
func (dst UUID) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst.Bytes
|
||||
|
||||
+1
-1
@@ -102,7 +102,7 @@ func (dst *UUIDArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *UUIDArray) Get() interface{} {
|
||||
func (dst UUIDArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -18,7 +18,7 @@ func (dst *Varbit) Set(src interface{}) error {
|
||||
return errors.Errorf("cannot convert %v to Varbit", src)
|
||||
}
|
||||
|
||||
func (dst *Varbit) Get() interface{} {
|
||||
func (dst Varbit) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
+2
-2
@@ -13,8 +13,8 @@ func (dst *Varchar) Set(src interface{}) error {
|
||||
return (*Text)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *Varchar) Get() interface{} {
|
||||
return (*Text)(dst).Get()
|
||||
func (dst Varchar) Get() interface{} {
|
||||
return (Text)(dst).Get()
|
||||
}
|
||||
|
||||
// AssignTo assigns from src to dst. Note that as Varchar is not a general number
|
||||
|
||||
+1
-1
@@ -64,7 +64,7 @@ func (dst *VarcharArray) Set(src interface{}) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (dst *VarcharArray) Get() interface{} {
|
||||
func (dst VarcharArray) Get() interface{} {
|
||||
switch dst.Status {
|
||||
case Present:
|
||||
return dst
|
||||
|
||||
@@ -27,8 +27,8 @@ func (dst *XID) Set(src interface{}) error {
|
||||
return (*pguint32)(dst).Set(src)
|
||||
}
|
||||
|
||||
func (dst *XID) Get() interface{} {
|
||||
return (*pguint32)(dst).Get()
|
||||
func (dst XID) Get() interface{} {
|
||||
return (pguint32)(dst).Get()
|
||||
}
|
||||
|
||||
// AssignTo assigns from src to dst. Note that as XID is not a general number
|
||||
|
||||
Reference in New Issue
Block a user