utils

package
v0.0.0-...-63a49d0 Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2017 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func APICall

func APICall(apiAddress string, data interface{})

APICall function

func CryptoCurrency

func CryptoCurrency(args []string)

CryptoCurrency function

func Currency

func Currency(args []string)

Currency main function

func GenericAPICall

func GenericAPICall(address string, data interface{}, tbTransport *http.Transport)

GenericAPICall function

func IPInfo

func IPInfo(args []string)

IPInfo function

func SafeParam

func SafeParam(s string) string

SafeParam function

func SimplifyCurrMap

func SimplifyCurrMap(mp map[string](map[string]float64), reqC string) map[string]float64

SimplifyCurrMap function

func Space

func Space()

Space main function

func Tor

func Tor()

Tor main function

func TorAPICall

func TorAPICall(apiAddress string, data interface{})

TorAPICall function

Types

type Pair

type Pair struct {
	Key   string
	Value float64
}

Pair struct

type PairList

type PairList []Pair

PairList type

func (PairList) Len

func (p PairList) Len() int

func (PairList) Less

func (p PairList) Less(i, j int) bool

func (PairList) Swap

func (p PairList) Swap(i, j int)

type SCheckTorprojectOrg

type SCheckTorprojectOrg struct {
	IsTor bool   `json:"IsTor"`
	IP    string `json:"IP"`
}

SCheckTorprojectOrg struct

type SFixerIo

type SFixerIo struct {
	Base  string             `json:"base"`
	Date  string             `json:"date"`
	Rates map[string]float64 `json:"rates"`
}

SFixerIo struct

type SGoogleGEO

type SGoogleGEO struct {
	Results []struct {
		FormattedAddress string `json:"formatted_address"`
	} `json:"results"`
	Status string `json:"status"`
}

SGoogleGEO source : http://maps.google.com/maps/api/geocode/json?latlng=4.1108,34.5748

type SIPAPICom

type SIPAPICom struct {
	As          string  `json:"as"`
	City        string  `json:"city"`
	Country     string  `json:"country"`
	CountryCode string  `json:"countryCode"`
	ISP         string  `json:"isp"`
	Lat         float64 `json:"lat"`
	Lon         float64 `json:"lon"`
	Org         string  `json:"org"`
	Query       string  `json:"query"`
	Region      string  `json:"region"`
	RegionName  string  `json:"regionName"`
	Status      string  `json:"status"`
	Timezone    string  `json:"timezone"`
	Zip         string  `json:"zip"`
}

SIPAPICom struct

type SOpenAstros

type SOpenAstros struct {
	SOpenGeneric
	Number int `json:"number"`
	People []struct {
		Name  string `json:"name"`
		Craft string `json:"craft"`
	} `json:"people"`
}

SOpenAstros source : http://api.open-notify.org/astros.json

type SOpenGeneric

type SOpenGeneric struct {
	Message string `json:"message"`
}

SOpenGeneric struct

func (*SOpenGeneric) CheckMessage

func (s *SOpenGeneric) CheckMessage()

CheckMessage func

type SOpenIssnow

type SOpenIssnow struct {
	SOpenGeneric
	Timestamp   int `json:"timestamp"`
	IssPosition struct {
		Latitude  string `json:"latitude"`
		Longitude string `json:"longitude"`
	} `json:"iss_position"`
}

SOpenIssnow source : http://api.open-notify.org/iss-now.json

func (*SOpenIssnow) GetLatLong

func (s *SOpenIssnow) GetLatLong() string

GetLatLong func

Jump to

Keyboard shortcuts

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