model

package
v0.0.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrDuplicate         = errors.New("duplicate entry")
	ErrNotFound          = errors.New("not found")
	ErrDocumentsMismatch = errors.New("documents did not match count")
)

Common errors.

Functions

This section is empty.

Types

type Document

type Document struct {
	ID string

	Created      time.Time
	Sequence     int64
	DocType      string
	EdgarURL     string
	Description  string
	Body         string
	SizeEstimate string
	FilingID     string
}

Document represent a single document in a filing.

type Filer

type Filer struct {
	ID             string
	Symbol         string
	CIK            string
	Name           string
	SIC            string
	SICDescription string
}

Filer is a single sec filer.

type Filing

type Filing struct {
	ID string

	Created           time.Time
	Updated           time.Time
	Filer             string
	Accession         string
	CIK               string
	EdgarURL          string
	EdgarTime         time.Time
	FilerRelation     string
	FormType          string
	DocumentCount     int64
	TotalSizeEstimate string
	Symbol            string
	AllSymbols        []string
	AllCIKs           []string
}

Filing represents a sec filing after a successful parsing of an Entry.

type Form

type Form struct {
	ID          string
	FormType    string
	Description string
	Active      bool
}

Form is a single sec form.

type Time

type Time struct{ time.Time }

Time wraps time.Time with serialization support.

func TimeFromFloat

func TimeFromFloat(ts float64) Time

TimeFromFloat converts timestamp floats to a Time object.

func (Time) Float

func (t Time) Float() float64

Float converts a Time object to a timestamp float.

func (Time) MarshalJSON

func (t Time) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*Time) UnmarshalJSON

func (t *Time) UnmarshalJSON(data []byte) (err error)

UnmarshalJSON implements json.Unmarshaler

Jump to

Keyboard shortcuts

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