byteslice

package
v2.0.0-alpha.3 Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package byteslice contains functions for working with byte slices.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IndexAll

func IndexAll(p, sub []byte) []int

IndexAll returns a list of all indexes of occurrences of the given sub-slice in the parent byte slice.

func IndexAllPartial

func IndexAllPartial(p, sub []byte) ([]int, int)

IndexAllPartial is a helper function that returns results of both IndexAll and PartialIndex in one call.

func PartialIndex

func PartialIndex(buf, match []byte) int

PartialIndex returns the index of the first occurrence of a partial match in the end of the buffer. If there is no partial match, -1 is returned.

Types

This section is empty.

Jump to

Keyboard shortcuts

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