Versions in this module Expand all Collapse all v1 v1.3.0 Sep 11, 2020 v1.2.3 Sep 9, 2020 v1.2.2 Sep 9, 2020 v1.2.1 Sep 9, 2020 v1.2.0 Sep 9, 2020 v1.1.2 Sep 9, 2020 Changes in this version + var ErrInvalidSource = errors.New("parse failed: invalid proto source") + var ErrNoSyntax = errors.New("no syntax specified; defaulting to proto2 syntax") + func ResolveFilenames(importPaths []string, fileNames ...string) ([]string, error) + type ErrorReporter func(err ErrorWithPos) error + type ErrorWithPos interface + GetPosition func() SourcePos + Unwrap func() error + type ErrorWithSourcePos struct + Pos *SourcePos + Underlying error + func (e ErrorWithSourcePos) Error() string + func (e ErrorWithSourcePos) GetPosition() SourcePos + func (e ErrorWithSourcePos) Unwrap() error + type FileAccessor func(filename string) (io.ReadCloser, error) + func FileContentsFromMap(files map[string]string) FileAccessor + type Parser struct + Accessor FileAccessor + ErrorReporter ErrorReporter + ImportPaths []string + IncludeSourceCodeInfo bool + InferImportPaths bool + InterpretOptionsInUnlinkedFiles bool + LookupImport func(string) (*desc.FileDescriptor, error) + ValidateUnlinkedFiles bool + WarningReporter WarningReporter + func (p Parser) ParseFiles(filenames ...string) ([]*desc.FileDescriptor, error) + func (p Parser) ParseFilesButDoNotLink(filenames ...string) ([]*dpb.FileDescriptorProto, error) + type SourcePos struct + Col int + Filename string + Line int + Offset int + func (pos SourcePos) String() string + type WarningReporter func(ErrorWithPos)