parser

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2021 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Conf

func Conf(ctx context.Context, r io.Reader) (context.Context, error)

Conf ...

func ExportCSV

func ExportCSV(ctx context.Context, path string) error

ExportCSV ...

func New

New ...

func Output

func Output(ctx context.Context, w io.Writer) error

Output ...

func RuleConfig

func RuleConfig(ctx context.Context, fileName string) (context.Context, error)

RuleConfig ...

func Run

func Run(ctx context.Context) (context.Context, error)

Run ...

Types

type Parser

type Parser struct {
	URL      string  `json:"url"`
	All      bool    `json:"all"`
	Rule     []*Rule `json:"rule"`
	Host     string  `json:"host"`
	Name     string  `json:"name"`
	Domen    string  `json:"domen"`
	Limit    string  `json:"limit"`
	PathType int     `json:"path_type"`
}

Parser ...

type Rule

type Rule struct {
	Type     string      `json:"type"`
	Name     string      `json:"name"`
	Attr     string      `json:"attr"`
	Parent   interface{} `json:"parent"`
	Page     string      `json:"page"`
	Path     string      `json:"path"`
	Children []*Rule     `json:"children,omitempty"`
}

Rule ...

Jump to

Keyboard shortcuts

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