package base type PkgVersion struct { Name string `db:"pkg"` Bundle string `db:"bundle"` Hash string `db:"hash"` FileName string `db:"filename"` SourceMapFileName string `db:"sourcemapFileName"` Imports []string `db:"imports"` Platform string `db:"platform"` ReleaseAt string `db:"release_at"` UpdatedAt string `db:"updated_at"` CreatedAt string `db:"created_at"` } func (this PkgVersion) GetFile() []byte func (this PkgVersion) GetSourceMap() []byte type GetPkgVersion func(pkg string, opts ...PkgOption) (PkgVersion, bool) // ็ญ›้€‰้€‰้กน type PkgOption func(option *PkgOptions) type PkgOptions struct { platform string hash string } func (this PkgOptions) Platform() string { return this.platform } func (this PkgOptions) Hash() string { return this.hash } func PkgPlatform(value string) PkgOption { return func(option *PkgOptions) { option.platform = value } } func PkgHash(value string) PkgOption { return func(option *PkgOptions) { option.hash = value } }