예제 #1
0
파일: params.go 프로젝트: snikch/api
// ContextParams returns the httprouter.Params for the context.
func ContextParams(context *ctx.Context) httprouter.Params {
	return context.Get(paramsContextKey).(httprouter.Params)
}
예제 #2
0
파일: criteria.go 프로젝트: snikch/api
// ContextCriteria returns the criteria for the supplied context.
func ContextCriteria(context *ctx.Context) *Criteria {
	return context.Get(criteriaContextKey).(*Criteria)
}