-
Notifications
You must be signed in to change notification settings - Fork 0
/
jobflow.go
46 lines (34 loc) · 979 Bytes
/
jobflow.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*
File : $File: //depot/stillwater-sc/perfmonitor/jobflow.go $
Authors : E. Theodore L. Omtzigt
Date : 5 May 2016
Source Control Information:
Version : $Revision: #1 $
Latest : $Date: 2016/05/05 $
Location : $Id: //depot/stillwater-sc/perfmonitor/jobflow.go#1 $
Organization:
Stillwater Supercomputing, Inc.
P.O Box 720
South Freeport, ME 04078-0720
Copyright (c) 2006-2016 E. Theodore L. Omtzigt. All rights reserved.
Licence : Stillwater license as defined in this directory
*/
package perfmonitor
import (
"fmt"
)
type JobFlow struct {
Arrivals uint64
Busy uint64
Completions uint64
}
/////////////////////////////////////////////////////////////////
// Selectors
func (f JobFlow) String() string {
return fmt.Sprintf("[%v,%v,%v]", f.Arrivals, f.Busy, f.Completions)
}
func (f *JobFlow) HasJobFlowBalance() bool {
return f.Arrivals == f.Completions
}
/////////////////////////////////////////////////////////////////
// Modifiers