40 lines
879 B
Go
40 lines
879 B
Go
package meta
|
|
|
|
type MetaTargetZoneType struct {
|
|
MetaTargetType
|
|
}
|
|
|
|
type MetaTargetZoneTypeEnum int
|
|
|
|
const (
|
|
MetaTargetZoneTypeEnumUNKNOWN MetaTargetZoneTypeEnum = iota + 1
|
|
MetaTargetZoneTypeEnumZONE
|
|
)
|
|
|
|
var (
|
|
metaTargetZoneTypeEnumID = map[MetaTargetZoneTypeEnum]string{
|
|
MetaTargetZoneTypeEnumUNKNOWN: "UNKNOWN",
|
|
MetaTargetZoneTypeEnumZONE: "ZONE",
|
|
}
|
|
|
|
metaTargetZoneTypeEnumKey = map[string]MetaTargetZoneTypeEnum{
|
|
"UNKNOWN": MetaTargetZoneTypeEnumUNKNOWN,
|
|
"ZONE": MetaTargetZoneTypeEnumZONE,
|
|
}
|
|
)
|
|
|
|
func (e MetaTargetZoneTypeEnum) String() string {
|
|
return metaTargetZoneTypeEnumID[e]
|
|
}
|
|
|
|
func ToMetaTargetZoneTypeEnum(v *MetaTargetZoneType) MetaTargetZoneTypeEnum {
|
|
return metaTargetZoneTypeEnumKey[v.Key]
|
|
}
|
|
|
|
func ToMetaTargetZoneType(v MetaTargetZoneTypeEnum) *MetaTargetZoneType {
|
|
m := &MetaTargetZoneType{}
|
|
m.Key = metaTargetZoneTypeEnumID[v]
|
|
|
|
return m
|
|
}
|