imid

package module
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2021 License: MIT Imports: 5 Imported by: 5

README

imagid

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Ext

type Ext byte

Ext ...

const (
	EtNone Ext = iota
	EtGIF
	EtJPEG
	EtPNG
)

consts

func ParseExt

func ParseExt(s string) Ext

ParseExt ...

func (Ext) MarshalText

func (z Ext) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface.

func (Ext) String

func (z Ext) String() string

String for fmt.Stringer

func (*Ext) UnmarshalText

func (z *Ext) UnmarshalText(data []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface.

func (Ext) Val

func (z Ext) Val() byte

Val ...

type IID

type IID uint64

IID Image ID

func ParseID

func ParseID(s string) (IID, error)

ParseID ...

func (IID) Bytes

func (z IID) Bytes() []byte

Bytes ...

func (IID) MarshalText

func (z IID) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface.

func (*IID) Scan

func (z *IID) Scan(src interface{}) (err error)

Scan implements of database/sql.Scanner

func (IID) String

func (z IID) String() string

String ...

func (*IID) UnmarshalText

func (z *IID) UnmarshalText(data []byte) (err error)

UnmarshalText implements the encoding.TextUnmarshaler interface.

func (IID) Value

func (z IID) Value() (driver.Value, error)

Value implements of database/sql/driver.Valuer

type Pin

type Pin struct {
	ID  IID
	Ext Ext
}

Pin ...

func NewPin

func NewPin(id uint64, ext Ext) Pin

NewPin ...

func ParsePin

func ParsePin(s string) (p *Pin, err error)

ParsePin ...

func (Pin) Bytes

func (p Pin) Bytes() []byte

Bytes ...

func (Pin) MarshalBinary

func (p Pin) MarshalBinary() ([]byte, error)

MarshalBinary implements the encoding.BinaryMarshaler interface.

func (Pin) MarshalText

func (p Pin) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface.

func (Pin) Path

func (p Pin) Path() string

Path ...

func (*Pin) Scan

func (p *Pin) Scan(src interface{}) (err error)

Scan implements of database/sql.Scanner

func (Pin) String

func (p Pin) String() string

String ...

func (*Pin) UnmarshalBinary

func (p *Pin) UnmarshalBinary(buf []byte) error

UnmarshalBinary implements the encoding.BinaryUnmarshaler interface.

func (*Pin) UnmarshalText

func (p *Pin) UnmarshalText(data []byte) (err error)

UnmarshalText implements the encoding.TextUnmarshaler interface.

func (Pin) Value

func (p Pin) Value() (driver.Value, error)

Value implements of database/sql/driver.Valuer

Jump to

Keyboard shortcuts

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