web

package
v0.0.0-...-9870119 Latest Latest
Warning

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

Go to latest
Published: May 21, 2018 License: MIT Imports: 30 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var EtagNotFoundError = errors.New("etag not found")

Functions

func TimeElapsed

func TimeElapsed(timestamp time.Time, full bool) string

Types

type Config

type Config struct {
	Wallet   *bitcoincash.SPVWallet
	Listener *app.TransactionListener
	Db       *db.Database

	Hostname string
	Port     int

	AddrChan chan [2]string
}

type EtagFactory

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

func NewEtagFactory

func NewEtagFactory(staticFileDir string) (*EtagFactory, error)

func (*EtagFactory) GetEtag

func (ef *EtagFactory) GetEtag(filePath string) (string, error)

type FormattedFile

type FormattedFile struct {
	db.FileDescriptor
	FormattedNet string
}

type NotFound

type NotFound struct {
	ErrorText string
}

type SearchResult

type SearchResult struct {
	Files    []FormattedFile
	More     bool
	Page     int
	Category string
	Query    string
}

type Server

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

func NewServer

func NewServer(conf Config) (*Server, error)

func (*Server) ProcessSocketRequests

func (s *Server) ProcessSocketRequests()

func (*Server) Start

func (s *Server) Start()

func (*Server) Stop

func (s *Server) Stop()

type SiteData

type SiteData struct {
	Title         string
	AddressPrefix string
	Hostname      string
	Port          int
}

Jump to

Keyboard shortcuts

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