示例#1
0
// Setting the transport to allow stackongo to call StackExchange API
func SetTransport(c context.Context) {
	transport = &urlfetch.Transport{Context: c}
	stackongo.SetTransport(transport)
}
示例#2
0
func SetTransport(r *http.Request) {
	c := appengine.NewContext(r)
	ut := &urlfetch.Transport{Context: c}
	stackongo.SetTransport(ut)
}