utils

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 12, 2018 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateMessageFromByte

func CreateMessageFromByte(message []byte) evtwebsocket.Msg

func CreateMessageFromString

func CreateMessageFromString(message string) evtwebsocket.Msg

func DeserializeData

func DeserializeData(data []byte) (jsonObject interface{})

func DeserializeDataFromString

func DeserializeDataFromString(data string) (jsonObject interface{})

func GetAuthToken

func GetAuthToken(message interface{}) string

func GetIsAuthenticated

func GetIsAuthenticated(message interface{}) bool

func IsEqual

func IsEqual(s string, b []byte) bool

func PrintMessage

func PrintMessage(message string)

func SerializeData

func SerializeData(data interface{}) []byte

func SerializeDataIntoString

func SerializeDataIntoString(data interface{}) string

Types

type AtomicCounter

type AtomicCounter struct {
	Counter uint64
}

func (*AtomicCounter) GetAndIncrement

func (atomicCounter *AtomicCounter) GetAndIncrement() uint64

func (*AtomicCounter) IncrementAndGet

func (atomicCounter *AtomicCounter) IncrementAndGet() uint64

func (*AtomicCounter) Reset

func (atomicCounter *AtomicCounter) Reset()

func (*AtomicCounter) Value

func (atomicCounter *AtomicCounter) Value() uint64

Jump to

Keyboard shortcuts

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