uuid

package
v0.2.0-alpha.20180328 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 29, 2018 License: MIT Imports: 3 Imported by: 3

README

uuid

It uses UUID Version 5, based on SHA-1 hashing (RFC 4122).

Documentation

Overview

Package uuid provides the UUID type and helper functions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Canonical

func Canonical(b []byte) string

Canonical converts an array of bytes into the canonical representation of UUID: xxxxxxxx-xxxx-Mxxx-Nxxx-xxxxxxxxxxxx. The one to three most significant bits of digit N indicate the UUID variant and the four bits of digit M indicate the UUID version.

Types

type UUID

type UUID string

UUID is a type used as identifier, compliant with Version 5 of RFC 4122: https://www.ietf.org/rfc/rfc4122.txt

func New

func New(input string) UUID

New creates a new UUID given a string.

func (UUID) String

func (u UUID) String() string

String returns a string representation of the UUID, implementing the Stringer interface.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL