swift

package
v0.51.1 Latest Latest
Warning

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

Go to latest
Published: May 4, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewParser

func NewParser() types.Parser

Types

type LockFile

type LockFile struct {
	Object  Object `json:"object"`
	Pins    []Pin  `json:"pins"`
	Version int    `json:"version"`
}

type Object

type Object struct {
	Pins []Pin `json:"pins"`
}

type Parser

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

Parser is a parser for Package.resolved files

func (*Parser) Parse

func (p *Parser) Parse(r xio.ReadSeekerAt) ([]types.Library, []types.Dependency, error)

type Pin

type Pin struct {
	Package       string `json:"package"`
	RepositoryURL string `json:"repositoryURL"` // Package.revision v1
	Location      string `json:"location"`      // Package.revision v2
	State         State  `json:"state"`
	StartLine     int
	EndLine       int
}

func (*Pin) UnmarshalJSONWithMetadata

func (p *Pin) UnmarshalJSONWithMetadata(node jfather.Node) error

UnmarshalJSONWithMetadata needed to detect start and end lines of deps for v1

type State

type State struct {
	Branch   string `json:"branch"`
	Revision string `json:"revision"`
	Version  string `json:"version"`
}

Jump to

Keyboard shortcuts

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