Documentation ¶
Index ¶
- type FilePos
- type Reader
- func (r *Reader) BufToCurrent(start int) []byte
- func (r *Reader) GetFileLineInfo() string
- func (r *Reader) IsEof() bool
- func (r *Reader) IsMatchAfter(s []byte) bool
- func (r *Reader) MustReadMatch(s []byte)
- func (r *Reader) MustReadWithSize(size int) []byte
- func (r *Reader) NextByte() byte
- func (r *Reader) Pos() int
- func (r *Reader) ReadAllSpace()
- func (r *Reader) ReadAllSpaceWithoutLineBreak()
- func (r *Reader) ReadByte() byte
- func (r *Reader) ReadRune() rune
- func (r *Reader) ReadUntilByte(b byte) []byte
- func (r *Reader) ReadUntilRuneCb(cb func(run rune) bool) []byte
- func (r *Reader) ReadUntilString(s []byte) []byte
- func (r *Reader) UnreadByte()
- func (r *Reader) UnreadRune() rune
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FilePos ¶
type FilePos struct {
// contains filtered or unexported fields
}
func NewPosFile ¶
func (*FilePos) GetLineWithPos ¶
type Reader ¶
type Reader struct {
// contains filtered or unexported fields
}
func NewReaderWithPosFile ¶
func (*Reader) BufToCurrent ¶
func (*Reader) GetFileLineInfo ¶
func (*Reader) IsMatchAfter ¶
func (*Reader) MustReadMatch ¶
func (*Reader) MustReadWithSize ¶
func (*Reader) ReadAllSpace ¶
func (r *Reader) ReadAllSpace()
func (*Reader) ReadAllSpaceWithoutLineBreak ¶
func (r *Reader) ReadAllSpaceWithoutLineBreak()
func (*Reader) ReadUntilByte ¶
读取到某个字符,或者读取到结束(该字符会已经被读过)
func (*Reader) ReadUntilRuneCb ¶
回调返回真的时候,停止读取,(这个回调提到的字符串也包含在内)
func (*Reader) ReadUntilString ¶
读取到某个字符串,或者读取到结束(该字符串会已经被读过)
func (*Reader) UnreadByte ¶
func (r *Reader) UnreadByte()
func (*Reader) UnreadRune ¶
Click to show internal directories.
Click to hide internal directories.