#
faucet
import "command-line-arguments"
#
Index
Constants func ExtractSignatureFromTweet(tweet twitter.Tweet) (string, error) func FindEmojiPosition(tweetText string) (int, error) func GetAddressForUsername(username string) string func GetStore() *pb.FaucetStore func GetTimestampForDrip(address string) int64 func GetTotalDripCount() float64 func GetUsernameForAddress(address string) string func IncrementTotalDripCount(dripConfig *DripConfig) func IsLinked(linked string, requested string) bool func LinkAddressAndUsername(address string, username string) func ReplenishFaucetWorker(ticker *time.Ticker, quit chan struct) func ResetTotalDripCount() func SetAddressForUsername(address string, username string, store *pb.FaucetStore) func SetTimestampForDrip(address string, timestamp int64, store *pb.FaucetStore) func SetTotalDripCount(dripCount float64, store *pb.FaucetStore) func SetUsernameForAddress(username string, address string, store *pb.FaucetStore) func SetupStore() func TimeDiff(earlierTime time.Time, laterTime time.Time) time.Duration func TwitterUsernameQuery(username string) string func UpdateDripRequestTimestamp(address string) func VerifyDripRequest(tweets []twitter.Tweet, username string, address string, numLatestTweets int) error func VerifyDripRequestTweet(tweet twitter.Tweet, username string, address string) error type DripConfig
#
Constants
FaucetStoreDir is the directory name for where the faucet store is stored.
const FaucetStoreDir string = "store"
FaucetStoreFilename is the name for the faucet store binary.
const FaucetStoreFilename string = "./store/FaucetStore"
#
func ExtractSignatureFromTweet
func ExtractSignatureFromTweet(tweet twitter.Tweet) (string, error)
#
func FindEmojiPosition
func FindEmojiPosition(tweetText string) (int, error)
#
func GetAddressForUsername
func GetAddressForUsername(username string) string
#
func GetStore
func GetStore() *pb.FaucetStore
#
func GetTimestampForDrip
func GetTimestampForDrip(address string) int64
#
func GetTotalDripCount
func GetTotalDripCount() float64
#
func GetUsernameForAddress
func GetUsernameForAddress(address string) string
#
func IncrementTotalDripCount
func IncrementTotalDripCount(dripConfig *DripConfig)
#
func IsLinked
func IsLinked(linked string, requested string) bool
#
func LinkAddressAndUsername
func LinkAddressAndUsername(address string, username string)
#
func ReplenishFaucetWorker
func ReplenishFaucetWorker(ticker *time.Ticker, quit chan struct{})
#
func ResetTotalDripCount
func ResetTotalDripCount()
#
func SetAddressForUsername
func SetAddressForUsername(address string, username string, store *pb.FaucetStore)
#
func SetTimestampForDrip
func SetTimestampForDrip(address string, timestamp int64, store *pb.FaucetStore)
#
func SetTotalDripCount
func SetTotalDripCount(dripCount float64, store *pb.FaucetStore)
#
func SetUsernameForAddress
func SetUsernameForAddress(username string, address string, store *pb.FaucetStore)
#
func SetupStore
func SetupStore()
#
func TimeDiff
func TimeDiff(earlierTime time.Time, laterTime time.Time) time.Duration
#
func TwitterUsernameQuery
func TwitterUsernameQuery(username string) string
#
func UpdateDripRequestTimestamp
func UpdateDripRequestTimestamp(address string)
#
func VerifyDripRequest
func VerifyDripRequest(tweets []twitter.Tweet, username string, address string, numLatestTweets int) error
#
func VerifyDripRequestTweet
func VerifyDripRequestTweet(tweet twitter.Tweet, username string, address string) error
#
type DripConfig
type DripConfig struct {
DripAmount float64
DripFrequency float64
DripLimit float64
DevMode bool
TwitterMode bool
// Miscellaneous.
NumLatestTweetsForVerify int
NameSystemAddress string
}
Generated by gomarkdoc