-
Notifications
You must be signed in to change notification settings - Fork 0
/
types.go
32 lines (27 loc) · 1.51 KB
/
types.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
package geneos
import "encoding/xml"
type Types struct {
XMLName xml.Name `xml:"types" json:"-" yaml:"-"`
Types []Type `xml:"type,omitempty" json:",omitempty" yaml:",omitempty" mapstructure:"type"`
TypeGroups []TypeGroup `xml:"typeGroup,omitempty" json:"typeGroup,omitempty" yaml:",omitempty" mapstructure:"typegroup"`
}
type TypeGroup struct {
XMLName xml.Name `xml:"typeGroup" json:"-" yaml:"-"`
Name string `xml:"name,attr"`
Disabled bool `xml:"disabled,attr,omitempty" json:",omitempty" yaml:",omitempty"`
Types []Type `xml:"type,omitempty" json:",omitempty" yaml:",omitempty" mapstructure:"type"`
TypeGroups []TypeGroup `xml:"typeGroup,omitempty" json:"typeGroup,omitempty" yaml:",omitempty" mapstructure:"typegroup"`
}
type Type struct {
XMLName xml.Name `xml:"type" json:"-" yaml:"-"`
Name string `xml:"name,attr"`
Disabled bool `xml:"disabled,attr,omitempty" json:",omitempty" yaml:",omitempty"`
Environment *Reference `xml:"environment,omitempty" json:",omitempty" yaml:",omitempty"`
Vars []Vars `xml:"var,omitempty" json:",omitempty" yaml:",omitempty" mapstructure:"var"`
Samplers []SamplerRef `xml:"sampler,omitempty" json:",omitempty" yaml:",omitempty" mapstructure:"sampler"`
}
type SamplerRef struct {
XMLName xml.Name `xml:"sampler" json:"-" yaml:"-"`
Name string `xml:"ref,attr" json:",omitempty" yaml:",omitempty"`
Disabled bool `xml:"disabled,attr,omitempty" json:",omitempty" yaml:",omitempty"`
}