Closed mudream4869 closed 4 years ago
Is there any function to get []byte from a UUID instance, or I should write the code as below?
func getBytes(u uuid.UUID) []byte { b := make([]byte, 16) for i := range b { b[i] = u[i] } return b }
b := uuidInstance[:]
also, might see MarshalBinary
Is there any function to get []byte from a UUID instance, or I should write the code as below?