bmaildb

package
v0.0.0-...-64eff32 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2020 License: GPL-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AttahmentMeta

type AttahmentMeta struct {
	SendHash   dbcommon.Hash
	RecvHash   dbcommon.Hash
	SendPubKey dbcommon.PKey
	FileName   string
	FileTye    int
	FileSize   int
	FilePath   string
	CreateTime int64
	UpdateTime int64
}

type BMAttachmentDb

type BMAttachmentDb struct {
	db.NbsDbInter
	// contains filtered or unexported fields
}

func GetBMAttachmentStore

func GetBMAttachmentStore() *BMAttachmentDb

func (*BMAttachmentDb) Insert

func (s *BMAttachmentDb) Insert(fileHash dbcommon.Hash, am *AttahmentMeta) error

type BMMailContentDB

type BMMailContentDB struct {
	db.NbsDbInter
	// contains filtered or unexported fields
}

func GetBMMailContentDb

func GetBMMailContentDb() *BMMailContentDB

func (*BMMailContentDB) Delete

func (mcdb *BMMailContentDB) Delete(eid uuid.UUID) error

func (*BMMailContentDB) IncRef

func (mcdb *BMMailContentDB) IncRef(eid uuid.UUID) error

func (*BMMailContentDB) Insert

func (mcdb *BMMailContentDB) Insert(eid uuid.UUID, env *bmp.BMailEnvelope) error

func (*BMMailContentDB) Iterator

func (mcdb *BMMailContentDB) Iterator()

func (*BMMailContentDB) Next

func (mcdb *BMMailContentDB) Next() (key string, meta *MailContentMeta, r1 error)

func (*BMMailContentDB) Save

func (mcdb *BMMailContentDB) Save()

type BMSaveMailDb

type BMSaveMailDb struct {
	db.NbsDbInter
	// contains filtered or unexported fields
}

func GetBMPullMailDb

func GetBMPullMailDb() *BMSaveMailDb

func GetBMSendMailDb

func GetBMSendMailDb() *BMSaveMailDb

func (*BMSaveMailDb) Delete

func (smdb *BMSaveMailDb) Delete(owner string, eid uuid.UUID) error

func (*BMSaveMailDb) Find

func (smdb *BMSaveMailDb) Find(owner string) (sm *SaveMail, err error)

func (*BMSaveMailDb) Insert

func (smdb *BMSaveMailDb) Insert(owner string, size int, eid uuid.UUID, curTime int64) error

type MailContentMeta

type MailContentMeta struct {
	Eid        uuid.UUID        `json:"-"`
	From       string           `json:"from"`
	FromAddr   bmail.Address    `json:"from_addr"`
	RCPTs      []*bmp.Recipient `json:"rcp_ts"`
	CreateTime int64            `json:"create_time"`
	SessionID  string           `json:"session_id"`
	RefCnt     int              `json:"ref_cnt"`
}

type MailItem

type MailItem struct {
	Eid        uuid.UUID `json:"eid"`
	Size       int       `json:"size"`
	CreateTime int64     `json:"create_time"`
}

type SaveMail

type SaveMail struct {
	Owner     string      `json:"-"`
	TotalSize int64       `json:"total_size"`
	TotalCnt  int         `json:"total_cnt"`
	Smi       []*MailItem `json:"smi"`
}

Jump to

Keyboard shortcuts

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