util

package
v0.0.0-...-8a3301c Latest Latest
Warning

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

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

Documentation

Overview

Copyright © 2017 sosozhuang <sosozhuang@163.com>

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddHook

func AddHook(h func())

func BytesToInt

func BytesToInt(b []byte) (int, error)

func BytesToObject

func BytesToObject(b []byte, i interface{}) error

func Checksum

func Checksum(data []byte) uint32

func Compare

func Compare(a, b []byte) bool

func ExitPaxos

func ExitPaxos(code int)

func HandleInterrupts

func HandleInterrupts()

func IntToBytes

func IntToBytes(n int) ([]byte, error)

func ObjectToBytes

func ObjectToBytes(i interface{}) ([]byte, error)

func UpdateChecksum

func UpdateChecksum(crc uint32, data []byte) uint32

Types

This section is empty.

Jump to

Keyboard shortcuts

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