stringkey

package
v0.0.0-...-096b6cb Latest Latest
Warning

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

Go to latest
Published: Jun 3, 2017 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package stringkey is an implementation of the "github.com/lleo/go-hamt/key" interface.

Both of these packages are are in separate package namespaces to prevent circular references between "github.com/lleo/go-hamt" and "github.com/lleo/go-hamt/hamt32" and/or "github.com/lleo/go-hamt/hamt64"; as well as "github.com/lleo/go-hamt-functional", "github.com/lleo/go-hamt-functional/hamt32", and "github.com/lleo/go-hamt-functional/hamt64".

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type StringKey

type StringKey struct {
	key.Base
	// contains filtered or unexported fields
}

StringKey is a simple string implementing the key.Key interface.

func New

func New(str string) *StringKey

New allocates and initializes a StringKey data structure.

func (StringKey) Equals

func (sk StringKey) Equals(k1 key.Key) bool

Equals returns true iff the StringKey exactly matches the key passed it. If The key.Key passed as an argument is not also a StringKey Equals() automatically returns false.

func (StringKey) Str

func (sk StringKey) Str() string

Str() returns the internal string this key is based on.

func (StringKey) String

func (sk StringKey) String() string

String return a string representation of StringKey data structure.

Jump to

Keyboard shortcuts

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