goplayspace: github.com/iafan/goplayspace/client/hash Index | Files

package hash

import "github.com/iafan/goplayspace/client/hash"

Index

Package Files

hash.go

type Hash Uses

type Hash struct {
    ID     string
    Ranges string

    OnChange func(h *Hash)
    // contains filtered or unexported fields
}

Hash contains the state parsed from URL hash

func New Uses

func New(onChange func(h *Hash)) *Hash

New returns a new Hash instance filled with values from window.localtion.hash

func (*Hash) Reset Uses

func (h *Hash) Reset()

Reset resets the hash properties

func (*Hash) SetID Uses

func (h *Hash) SetID(id string)

SetID sets ID part and updates state (URL in the address bar)

func (*Hash) SetRanges Uses

func (h *Hash) SetRanges(ranges string)

SetRanges sets Ranges part and updates state (URL in the address bar)

Package hash imports 3 packages (graph) and is imported by 1 packages. Updated 2017-08-06. Refresh now. Tools for package owners.