Documentation
¶
Index ¶
- func Check(e error)
- func CheckEmail(email string) (ok bool)
- func ElapsedMs(start time.Time) float64
- func ErrorTraced(prev error, args ...string) error
- func FromGob(by []byte, m interface{})
- func Log(shoudLog bool, format string, a ...interface{})
- func PrettyPrint(v interface{}) (err error)
- func TimeTrack(start time.Time, name string)
- func ToGob(m interface{}) []byte
- func Trace()
- type TimeRemainingTimer
- func (v *TimeRemainingTimer) Get(current int64) (percentageDone float64, timeRemaining time.Duration)
- func (v *TimeRemainingTimer) Getf(current int64) string
- func (v *TimeRemainingTimer) Printr(current int64)
- func (v *TimeRemainingTimer) Restart(start, end int64)
- func (v *TimeRemainingTimer) Start()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckEmail ¶
CheckEmail checks e-mail format correctness
Types ¶
type TimeRemainingTimer ¶
type TimeRemainingTimer struct {
// contains filtered or unexported fields
}
TimeRemainingTimer used to track progress
func CreateTimeRemainingTimer ¶
func CreateTimeRemainingTimer(start, end int64) *TimeRemainingTimer
CreateTimeRemainingTimer creates timer, that will interpolate remaining time based on some start & end indexes
func (*TimeRemainingTimer) Get ¶
func (v *TimeRemainingTimer) Get(current int64) (percentageDone float64, timeRemaining time.Duration)
Get returns %done & remainingTime for current index
func (*TimeRemainingTimer) Getf ¶
func (v *TimeRemainingTimer) Getf(current int64) string
Getf returns formatted string of %done & remaining time
func (*TimeRemainingTimer) Printr ¶
func (v *TimeRemainingTimer) Printr(current int64)
Printr fmt.Printf's formatted %done & remaining time
func (*TimeRemainingTimer) Restart ¶
func (v *TimeRemainingTimer) Restart(start, end int64)
Restart restarts the timer with new start & end values
Click to show internal directories.
Click to hide internal directories.