extractor

package
v0.0.0-...-fff90db Latest Latest
Warning

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

Go to latest
Published: Jul 7, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(filename string) entity.Extractor

New creates a new Extractor.

Types

type Extractor

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

Extractor represents an extraction algorithm, capable of retriving several definitions/declarations. The current implementation handles:

  • function declaration
  • variable declaration
  • constant declaration
  • struct definition
  • interface definition

func (*Extractor) Identifiers

func (e *Extractor) Identifiers() []entity.Identifier

Identifiers returns the list of found identifiers.

func (*Extractor) Visit

func (e *Extractor) Visit(node ast.Node) ast.Visitor

Visit implements the ast.Visitor interface and handles the logic for the identifiers extraction.

Jump to

Keyboard shortcuts

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