MCPcopy Create free account
hub / github.com/OpenPrinting/goipp / DeepCopy

Method DeepCopy

group.go:78–87  ·  view source on GitHub ↗

DeepCopy creates a deep copy of Groups. For nil input it returns nil output.

()

Source from the content-addressed store, hash-verified

76// DeepCopy creates a deep copy of Groups.
77// For nil input it returns nil output.
78func (groups Groups) DeepCopy() Groups {
79 var groups2 Groups
80 if groups != nil {
81 groups2 = make(Groups, len(groups))
82 for i := range groups {
83 groups2[i] = groups[i].DeepCopy()
84 }
85 }
86 return groups2
87}
88
89// Equal checks that groups and groups2 are equal.
90//

Callers

nothing calls this directly

Calls 1

DeepCopyMethod · 0.65

Tested by

no test coverage detected