MCPcopy
hub / github.com/jackc/pgx / Copy

Method Copy

pgtype/pgtype.go:223–229  ·  view source on GitHub ↗

Copy returns a new Map containing the same registered types.

()

Source from the content-addressed store, hash-verified

221
222// Copy returns a new Map containing the same registered types.
223func (m *Map) Copy() *Map {
224 newMap := NewMap()
225 for _, type_ := range m.oidToType {
226 newMap.RegisterType(type_)
227 }
228 return newMap
229}
230
231func NewMap() *Map {
232 defaultMapInitOnce.Do(initDefaultMap)

Callers

nothing calls this directly

Calls 2

RegisterTypeMethod · 0.95
NewMapFunction · 0.85

Tested by

no test coverage detected