ctxscanner

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package ctxscanner contains implementation of a scanner that takes in a context.Context, and allows it to be paused.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Scanner

type Scanner struct {
	// contains filtered or unexported fields
}

Scanner is a wrapper around bufio.Scanner that takes in a context.

func New

func New(r io.Reader) *Scanner

func (*Scanner) Bytes

func (s *Scanner) Bytes() []byte

func (*Scanner) Err

func (s *Scanner) Err() error

func (*Scanner) Scan

func (s *Scanner) Scan(ctx context.Context) (bool, error)

func (*Scanner) Text

func (s *Scanner) Text() string

Jump to

Keyboard shortcuts

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