2016-02-03 16:54:02 -05:00
|
|
|
// Package common contains common utilities that are shared among other packages.
|
|
|
|
// See each sub-package for detail.
|
|
|
|
package common
|
2016-03-09 18:33:01 -05:00
|
|
|
|
|
|
|
import (
|
|
|
|
"errors"
|
|
|
|
)
|
|
|
|
|
|
|
|
var (
|
|
|
|
ErrorAlreadyReleased = errors.New("Object already released.")
|
|
|
|
)
|
|
|
|
|
2016-03-11 17:51:58 -05:00
|
|
|
// Releasable interface is for those types that can release its members.
|
2016-03-09 18:33:01 -05:00
|
|
|
type Releasable interface {
|
2016-03-11 17:51:58 -05:00
|
|
|
// Release releases all references to accelerate garbage collection.
|
2016-03-09 18:33:01 -05:00
|
|
|
Release()
|
|
|
|
}
|