From 860e5d483cd952ec833c40312a2141bb3e4ef579 Mon Sep 17 00:00:00 2001 From: Joram Wilander Date: Mon, 29 May 2017 15:46:35 -0400 Subject: PLT-6341/PLT-6342 Update gorp to mattermost fork and add connection timeout setting (#6410) * Update gorp to mattermost fork and add connection timeout setting * Add go dependency * Rename from connection timeout to query timeout * Properly add gorp dependency --- vendor/github.com/mattermost/gorp/hooks.go | 49 ++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 vendor/github.com/mattermost/gorp/hooks.go (limited to 'vendor/github.com/mattermost/gorp/hooks.go') diff --git a/vendor/github.com/mattermost/gorp/hooks.go b/vendor/github.com/mattermost/gorp/hooks.go new file mode 100644 index 000000000..192b51f00 --- /dev/null +++ b/vendor/github.com/mattermost/gorp/hooks.go @@ -0,0 +1,49 @@ +// Copyright 2012 James Cooper. All rights reserved. +// Use of this source code is governed by a MIT-style +// license that can be found in the LICENSE file. + +// Package gorp provides a simple way to marshal Go structs to and from +// SQL databases. It uses the database/sql package, and should work with any +// compliant database/sql driver. +// +// Source code and project home: +// https://github.com/go-gorp/gorp + +package gorp + +//++ TODO v2-phase3: HasPostGet => PostGetter, HasPostDelete => PostDeleter, etc. + +// PostUpdate() will be executed after the GET statement. +type HasPostGet interface { + PostGet(SqlExecutor) error +} + +// PostUpdate() will be executed after the DELETE statement +type HasPostDelete interface { + PostDelete(SqlExecutor) error +} + +// PostUpdate() will be executed after the UPDATE statement +type HasPostUpdate interface { + PostUpdate(SqlExecutor) error +} + +// PostInsert() will be executed after the INSERT statement +type HasPostInsert interface { + PostInsert(SqlExecutor) error +} + +// PreDelete() will be executed before the DELETE statement. +type HasPreDelete interface { + PreDelete(SqlExecutor) error +} + +// PreUpdate() will be executed before UPDATE statement. +type HasPreUpdate interface { + PreUpdate(SqlExecutor) error +} + +// PreInsert() will be executed before INSERT statement. +type HasPreInsert interface { + PreInsert(SqlExecutor) error +} -- cgit v1.2.3-1-g7c22