vidshare

package
v0.0.0-...-ebac000 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (

	// Too many (or too few) sources for given MimeTypes-array. (ZIP-mismatch)
	ErrTooManyFewSources = errors.New("Too many/few sources for given MimeTypes")
)

Functions

func ReadFile

func ReadFile(sh *shell.Shell, c *Crypto, id string, name string) (io.ReadCloser, error)

func Upload

func Upload(sh *shell.Shell, c *Crypto, m *MediaMeta, sources ...io.Reader) (string, error)

Types

type Crypto

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

func MakeCrypto

func MakeCrypto(password []byte) *Crypto

func (*Crypto) Derive

func (c *Crypto) Derive(s string) cipher.Stream

type MediaMeta

type MediaMeta struct {
	HtmlType string `json:"h,omitempty"` // "img", "audio", "video"

	MimeTypes []string `json:"m,omitempty"` // MimeType for each <source> -tag

	Title      string `json:"t,omitempty"`     // Title
	VideoDescr string `json:"descr,omitempty"` // Video Description

	MetaTag [][2]string `json:"meta,omitempty"` // Metadata tags.
}

func Decode

func Decode(sh *shell.Shell, c *Crypto, id string) (md *MediaMeta, _ error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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