object

package
v0.0.0-...-1b40114 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewCommitObject

func NewCommitObject(o object) *commitObject

func NewTreeObject

func NewTreeObject(o object) *treeObject

Types

type CommitObject

type CommitObject interface {
	Object
	Tree() string
	Parent() string
	Author() string
	Committer() string
	GPGSignature() string
	Message() string
}

type Object

type Object interface {
	IsBlob() bool
	IsTree() bool
	IsCommit() bool

	Length() int
	String() string
}

func NewObject

func NewObject(obj []byte) Object

type TreeItem

type TreeItem interface {
	Name() string
	Hash() string
	Type() Type
	String() string
}

type TreeObject

type TreeObject interface {
	Object
	Items() []TreeItem
}

type Type

type Type int
const (
	TypeSimpleBlob     Type = 100644
	TypeExecutableBlob Type = 100755
	TypeSymbolLinkBlob Type = 120000
	TypeBlob           Type = 1
	TypeTree           Type = 040000
	TypeCommit         Type = 2
)

func (Type) String

func (t Type) String() string

Jump to

Keyboard shortcuts

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