// GetContext is the context version of Get.
161060
func (tx *Tx) GetContext(ctx context.Context, dest interface{}, keys ...interface{}) error {
	return getObject(ctx, tx.DB, tx, dest, keys)
}
528193
func (d *Context) GetContext(index int) *Context {
	return contextFromPointer(C.duk_get_context(d.duk_context, C.duk_idx_t(index)))
}
189804
func (c *GetTaskDefCall) Context(ctx context.Context) *GetTaskDefCall {
	c.ctx_ = ctx
	return c
}
1000236
func (client *BaseClient) GetClientContext(
	settings *InvokeSettings) (context *ClientContext) {
	context = client.contextPool.Get().(*ClientContext)
	context.InitBaseContext()
	context.Client = client
	context.Retried = 0
	if client.UserData != nil {
		for k, v := range client.UserData {
			context.SetInterface(k, v)
		}
	}
	if settings == nil {
		context.InvokeSettings = InvokeSettings{
			Timeout: client.timeout,
			Retry:   client.retry,
		}
	} else {
		if settings.userData != nil {
			for k, v := range settings.userData {
				context.SetInterface(k, v)
			}
		}
		context.InvokeSettings = *settings
		if settings.Timeout <= 0 {
			context.Timeout = client.timeout
		}
		if settings.Retry <= 0 {
			context.Retry = client.retry
		}
	}
	return context
}
507311
func Get(r *http.Request) *Context {

	// get the context bound to the http.Request
	if v, ok := r.Body.(*wrapper); ok {
		return v.context
	}

	// create a new context
	c := Context{ }
	c.Params = make(Params)
	c.Values = make(Values)
	c.req = r

	// wrap the request and bind the context
	wrapper := wrap(r)
	wrapper.context = &c
	return &c
}
897358
func (o *GetStatusParams) WithContext(ctx context.Context) *GetStatusParams {
	o.SetContext(ctx)
	return o
}
1031716
func (c *GetConfigSetsCall) Context(ctx context.Context) *GetConfigSetsCall {
	c.ctx_ = ctx
	return c
}
709708
func (c *GetBuildersCall) Context(ctx context.Context) *GetBuildersCall {
	c.ctx_ = ctx
	return c
}
839209
func GetContext(ctx context.Context) Entry {
	v := ctx.Value(ctxIdent)
	if v == nil {
		return newEntryWithFields(nil)
	}
	return v.(Entry)
}
891110
func WithContext(ctx context.Context, fnctx Context) context.Context {
	return context.WithValue(ctx, ctxKey, fnctx)
}
407201
func (c *UnitStateGetCall) Context(ctx context.Context) *UnitStateGetCall {
	c.ctx_ = ctx
	return c
}
560340
func (c *AckCall) Context(ctx context.Context) *AckCall {
	c.ctx_ = ctx
	return c
}
1340159
func (c *ValidateConfigCall) Context(ctx context.Context) *ValidateConfigCall {
	c.ctx_ = ctx
	return c
}
1016726
func (n *NamedStmt) GetContext(ctx context.Context, dest interface{}, arg interface{}) error {
	r := n.QueryRowxContext(ctx, arg)
	return r.scanAny(dest, false)
}
708859
func (r *RoutesService) GetWithContext(ctx context.Context, id string) (*Route, *http.Response, error) {
	resource, _ := url.Parse(routesResourcePath)
	resource.Path = path.Join(resource.Path, id)

	req, err := r.client.NewRequest(ctx, http.MethodGet, resource, nil)

	if err != nil {
		return nil, nil, err
	}

	route := new(Route)

	res, err := r.client.Do(req, route)

	if err != nil {
		return nil, res, err
	}

	return route, res, nil
}
971029
func (r *Request) Context(ctx context.Context) *Request {
	r.ctx = ctx
	return r
}
620057
func ensureContext(ctx context.Context) context.Context {
	if ctx == nil {
		return context.TODO()
	}
	return ctx
}