// Code generated by protoc-gen-go-lite. DO NOT EDIT.
// protoc-gen-go-lite version: v0.11.0
// source: github.com/aperturerobotics/controllerbus/controller/exec/exec.proto

package controller_exec

import (
	fmt "fmt"
	io "io"
	slices "slices"
	strconv "strconv"
	strings "strings"

	controller "github.com/aperturerobotics/controllerbus/controller"
	proto "github.com/aperturerobotics/controllerbus/controller/configset/proto"
	protobuf_go_lite "github.com/aperturerobotics/protobuf-go-lite"
	json "github.com/aperturerobotics/protobuf-go-lite/json"
)

// ControllerStatus holds basic status for a controller.
type ControllerStatus int32

const (
	// ControllerStatus_UNKNOWN is unrecognized.
	ControllerStatus_ControllerStatus_UNKNOWN ControllerStatus = 0
	// ControllerStatus_CONFIGURING indicates the controller is configuring.
	ControllerStatus_ControllerStatus_CONFIGURING ControllerStatus = 1
	// ControllerStatus_RUNNING indicates the controller is running.
	ControllerStatus_ControllerStatus_RUNNING ControllerStatus = 2
	// ControllerStatus_ERROR indicates the controller is terminated with an error.
	ControllerStatus_ControllerStatus_ERROR ControllerStatus = 3
)

// Enum value maps for ControllerStatus.
var (
	ControllerStatus_name = map[int32]string{
		0: "ControllerStatus_UNKNOWN",
		1: "ControllerStatus_CONFIGURING",
		2: "ControllerStatus_RUNNING",
		3: "ControllerStatus_ERROR",
	}
	ControllerStatus_value = map[string]int32{
		"ControllerStatus_UNKNOWN":     0,
		"ControllerStatus_CONFIGURING": 1,
		"ControllerStatus_RUNNING":     2,
		"ControllerStatus_ERROR":       3,
	}
)

func (x ControllerStatus) Enum() *ControllerStatus {
	p := new(ControllerStatus)
	*p = x
	return p
}

func (x ControllerStatus) String() string {
	name, valid := ControllerStatus_name[int32(x)]
	if valid {
		return name
	}
	return strconv.Itoa(int(x))
}

// ExecControllerRequest is a protobuf request to execute a controller.
type ExecControllerRequest struct {
	unknownFields []byte
	// ConfigSet is the controller config set to execute.
	ConfigSet *proto.ConfigSet `protobuf:"bytes,1,opt,name=config_set,json=configSet,proto3" json:"configSet,omitempty"`
	// ConfigSetYaml is optionally the YAML form of config_set to parse.
	// Merged with config_set.
	ConfigSetYaml string `protobuf:"bytes,2,opt,name=config_set_yaml,json=configSetYaml,proto3" json:"configSetYaml,omitempty"`
	// ConfigSetYamlOverwrite sets if the yaml portion overwrites the proto portion.
	ConfigSetYamlOverwrite bool `protobuf:"varint,3,opt,name=config_set_yaml_overwrite,json=configSetYamlOverwrite,proto3" json:"configSetYamlOverwrite,omitempty"`
}

func (x *ExecControllerRequest) Reset() {
	*x = ExecControllerRequest{}
}

func (*ExecControllerRequest) ProtoMessage() {}

func (x *ExecControllerRequest) GetConfigSet() *proto.ConfigSet {
	if x != nil {
		return x.ConfigSet
	}
	return nil
}

func (x *ExecControllerRequest) GetConfigSetYaml() string {
	if x != nil {
		return x.ConfigSetYaml
	}
	return ""
}

func (x *ExecControllerRequest) GetConfigSetYamlOverwrite() bool {
	if x != nil {
		return x.ConfigSetYamlOverwrite
	}
	return false
}

// ExecControllerResponse is a protobuf response stream.
type ExecControllerResponse struct {
	unknownFields []byte
	// Id is the configset identifier for this status report.
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// Status is the controller execution status.
	Status ControllerStatus `protobuf:"varint,2,opt,name=status,proto3" json:"status,omitempty"`
	// ControllerInfo may contain the running controller info.
	ControllerInfo *controller.Info `protobuf:"bytes,3,opt,name=controller_info,json=controllerInfo,proto3" json:"controllerInfo,omitempty"`
	// ErrorInfo may contain the error information.
	ErrorInfo string `protobuf:"bytes,4,opt,name=error_info,json=errorInfo,proto3" json:"errorInfo,omitempty"`
}

func (x *ExecControllerResponse) Reset() {
	*x = ExecControllerResponse{}
}

func (*ExecControllerResponse) ProtoMessage() {}

func (x *ExecControllerResponse) GetId() string {
	if x != nil {
		return x.Id
	}
	return ""
}

func (x *ExecControllerResponse) GetStatus() ControllerStatus {
	if x != nil {
		return x.Status
	}
	return ControllerStatus_ControllerStatus_UNKNOWN
}

func (x *ExecControllerResponse) GetControllerInfo() *controller.Info {
	if x != nil {
		return x.ControllerInfo
	}
	return nil
}

func (x *ExecControllerResponse) GetErrorInfo() string {
	if x != nil {
		return x.ErrorInfo
	}
	return ""
}

func (m *ExecControllerRequest) CloneVT() *ExecControllerRequest {
	if m == nil {
		return (*ExecControllerRequest)(nil)
	}
	r := new(ExecControllerRequest)
	r.ConfigSetYaml = m.ConfigSetYaml
	r.ConfigSetYamlOverwrite = m.ConfigSetYamlOverwrite
	if rhs := m.ConfigSet; rhs != nil {
		r.ConfigSet = rhs.CloneVT()
	}
	if len(m.unknownFields) > 0 {
		r.unknownFields = slices.Clone(m.unknownFields)
	}
	return r
}

func (m *ExecControllerRequest) CloneMessageVT() protobuf_go_lite.CloneMessage {
	return m.CloneVT()
}

func (m *ExecControllerResponse) CloneVT() *ExecControllerResponse {
	if m == nil {
		return (*ExecControllerResponse)(nil)
	}
	r := new(ExecControllerResponse)
	r.Id = m.Id
	r.Status = m.Status
	r.ErrorInfo = m.ErrorInfo
	if rhs := m.ControllerInfo; rhs != nil {
		r.ControllerInfo = rhs.CloneVT()
	}
	if len(m.unknownFields) > 0 {
		r.unknownFields = slices.Clone(m.unknownFields)
	}
	return r
}

func (m *ExecControllerResponse) CloneMessageVT() protobuf_go_lite.CloneMessage {
	return m.CloneVT()
}

func (this *ExecControllerRequest) EqualVT(that *ExecControllerRequest) bool {
	if this == that {
		return true
	} else if this == nil || that == nil {
		return false
	}
	if !this.ConfigSet.EqualVT(that.ConfigSet) {
		return false
	}
	if this.ConfigSetYaml != that.ConfigSetYaml {
		return false
	}
	if this.ConfigSetYamlOverwrite != that.ConfigSetYamlOverwrite {
		return false
	}
	return string(this.unknownFields) == string(that.unknownFields)
}

func (this *ExecControllerRequest) EqualMessageVT(thatMsg any) bool {
	that, ok := thatMsg.(*ExecControllerRequest)
	if !ok {
		return false
	}
	return this.EqualVT(that)
}
func (this *ExecControllerResponse) EqualVT(that *ExecControllerResponse) bool {
	if this == that {
		return true
	} else if this == nil || that == nil {
		return false
	}
	if this.Id != that.Id {
		return false
	}
	if this.Status != that.Status {
		return false
	}
	if !this.ControllerInfo.EqualVT(that.ControllerInfo) {
		return false
	}
	if this.ErrorInfo != that.ErrorInfo {
		return false
	}
	return string(this.unknownFields) == string(that.unknownFields)
}

func (this *ExecControllerResponse) EqualMessageVT(thatMsg any) bool {
	that, ok := thatMsg.(*ExecControllerResponse)
	if !ok {
		return false
	}
	return this.EqualVT(that)
}

// MarshalProtoJSON marshals the ControllerStatus to JSON.
func (x ControllerStatus) MarshalProtoJSON(s *json.MarshalState) {
	s.WriteEnum(int32(x), ControllerStatus_name)
}

// MarshalText marshals the ControllerStatus to text.
func (x ControllerStatus) MarshalText() ([]byte, error) {
	return []byte(json.GetEnumString(int32(x), ControllerStatus_name)), nil
}

// MarshalJSON marshals the ControllerStatus to JSON.
func (x ControllerStatus) MarshalJSON() ([]byte, error) {
	return json.DefaultMarshalerConfig.Marshal(x)
}

// UnmarshalProtoJSON unmarshals the ControllerStatus from JSON.
func (x *ControllerStatus) UnmarshalProtoJSON(s *json.UnmarshalState) {
	v := s.ReadEnum(ControllerStatus_value)
	if err := s.Err(); err != nil {
		s.SetErrorf("could not read ControllerStatus enum: %v", err)
		return
	}
	*x = ControllerStatus(v)
}

// UnmarshalText unmarshals the ControllerStatus from text.
func (x *ControllerStatus) UnmarshalText(b []byte) error {
	i, err := json.ParseEnumString(string(b), ControllerStatus_value)
	if err != nil {
		return err
	}
	*x = ControllerStatus(i)
	return nil
}

// UnmarshalJSON unmarshals the ControllerStatus from JSON.
func (x *ControllerStatus) UnmarshalJSON(b []byte) error {
	return json.DefaultUnmarshalerConfig.Unmarshal(b, x)
}

// MarshalProtoJSON marshals the ExecControllerRequest message to JSON.
func (x *ExecControllerRequest) MarshalProtoJSON(s *json.MarshalState) {
	if x == nil {
		s.WriteNil()
		return
	}
	s.WriteObjectStart()
	var wroteField bool
	if x.ConfigSet != nil || s.HasField("configSet") {
		s.WriteMoreIf(&wroteField)
		s.WriteObjectField("configSet")
		x.ConfigSet.MarshalProtoJSON(s.WithField("configSet"))
	}
	if x.ConfigSetYaml != "" || s.HasField("configSetYaml") {
		s.WriteMoreIf(&wroteField)
		s.WriteObjectField("configSetYaml")
		s.WriteString(x.ConfigSetYaml)
	}
	if x.ConfigSetYamlOverwrite || s.HasField("configSetYamlOverwrite") {
		s.WriteMoreIf(&wroteField)
		s.WriteObjectField("configSetYamlOverwrite")
		s.WriteBool(x.ConfigSetYamlOverwrite)
	}
	s.WriteObjectEnd()
}

// MarshalJSON marshals the ExecControllerRequest to JSON.
func (x *ExecControllerRequest) MarshalJSON() ([]byte, error) {
	return json.DefaultMarshalerConfig.Marshal(x)
}

// UnmarshalProtoJSON unmarshals the ExecControllerRequest message from JSON.
func (x *ExecControllerRequest) UnmarshalProtoJSON(s *json.UnmarshalState) {
	if s.ReadNil() {
		return
	}
	s.ReadObject(func(key string) {
		switch key {
		default:
			s.Skip() // ignore unknown field
		case "config_set", "configSet":
			if s.ReadNil() {
				x.ConfigSet = nil
				return
			}
			x.ConfigSet = &proto.ConfigSet{}
			x.ConfigSet.UnmarshalProtoJSON(s.WithField("config_set", true))
		case "config_set_yaml", "configSetYaml":
			s.AddField("config_set_yaml")
			x.ConfigSetYaml = s.ReadString()
		case "config_set_yaml_overwrite", "configSetYamlOverwrite":
			s.AddField("config_set_yaml_overwrite")
			x.ConfigSetYamlOverwrite = s.ReadBool()
		}
	})
}

// UnmarshalJSON unmarshals the ExecControllerRequest from JSON.
func (x *ExecControllerRequest) UnmarshalJSON(b []byte) error {
	return json.DefaultUnmarshalerConfig.Unmarshal(b, x)
}

// MarshalProtoJSON marshals the ExecControllerResponse message to JSON.
func (x *ExecControllerResponse) MarshalProtoJSON(s *json.MarshalState) {
	if x == nil {
		s.WriteNil()
		return
	}
	s.WriteObjectStart()
	var wroteField bool
	if x.Id != "" || s.HasField("id") {
		s.WriteMoreIf(&wroteField)
		s.WriteObjectField("id")
		s.WriteString(x.Id)
	}
	if x.Status != 0 || s.HasField("status") {
		s.WriteMoreIf(&wroteField)
		s.WriteObjectField("status")
		x.Status.MarshalProtoJSON(s)
	}
	if x.ControllerInfo != nil || s.HasField("controllerInfo") {
		s.WriteMoreIf(&wroteField)
		s.WriteObjectField("controllerInfo")
		x.ControllerInfo.MarshalProtoJSON(s.WithField("controllerInfo"))
	}
	if x.ErrorInfo != "" || s.HasField("errorInfo") {
		s.WriteMoreIf(&wroteField)
		s.WriteObjectField("errorInfo")
		s.WriteString(x.ErrorInfo)
	}
	s.WriteObjectEnd()
}

// MarshalJSON marshals the ExecControllerResponse to JSON.
func (x *ExecControllerResponse) MarshalJSON() ([]byte, error) {
	return json.DefaultMarshalerConfig.Marshal(x)
}

// UnmarshalProtoJSON unmarshals the ExecControllerResponse message from JSON.
func (x *ExecControllerResponse) UnmarshalProtoJSON(s *json.UnmarshalState) {
	if s.ReadNil() {
		return
	}
	s.ReadObject(func(key string) {
		switch key {
		default:
			s.Skip() // ignore unknown field
		case "id":
			s.AddField("id")
			x.Id = s.ReadString()
		case "status":
			s.AddField("status")
			x.Status.UnmarshalProtoJSON(s)
		case "controller_info", "controllerInfo":
			if s.ReadNil() {
				x.ControllerInfo = nil
				return
			}
			x.ControllerInfo = &controller.Info{}
			x.ControllerInfo.UnmarshalProtoJSON(s.WithField("controller_info", true))
		case "error_info", "errorInfo":
			s.AddField("error_info")
			x.ErrorInfo = s.ReadString()
		}
	})
}

// UnmarshalJSON unmarshals the ExecControllerResponse from JSON.
func (x *ExecControllerResponse) UnmarshalJSON(b []byte) error {
	return json.DefaultUnmarshalerConfig.Unmarshal(b, x)
}

func (m *ExecControllerRequest) MarshalVT() (dAtA []byte, err error) {
	if m == nil {
		return nil, nil
	}
	size := m.SizeVT()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBufferVT(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ExecControllerRequest) MarshalToVT(dAtA []byte) (int, error) {
	size := m.SizeVT()
	return m.MarshalToSizedBufferVT(dAtA[:size])
}

func (m *ExecControllerRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error) {
	if m == nil {
		return 0, nil
	}
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.unknownFields != nil {
		i -= len(m.unknownFields)
		copy(dAtA[i:], m.unknownFields)
	}
	if m.ConfigSetYamlOverwrite {
		i--
		if m.ConfigSetYamlOverwrite {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i--
		dAtA[i] = 0x18
	}
	if len(m.ConfigSetYaml) > 0 {
		i -= len(m.ConfigSetYaml)
		copy(dAtA[i:], m.ConfigSetYaml)
		i = protobuf_go_lite.EncodeVarint(dAtA, i, uint64(len(m.ConfigSetYaml)))
		i--
		dAtA[i] = 0x12
	}
	if m.ConfigSet != nil {
		size, err := m.ConfigSet.MarshalToSizedBufferVT(dAtA[:i])
		if err != nil {
			return 0, err
		}
		i -= size
		i = protobuf_go_lite.EncodeVarint(dAtA, i, uint64(size))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *ExecControllerResponse) MarshalVT() (dAtA []byte, err error) {
	if m == nil {
		return nil, nil
	}
	size := m.SizeVT()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBufferVT(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ExecControllerResponse) MarshalToVT(dAtA []byte) (int, error) {
	size := m.SizeVT()
	return m.MarshalToSizedBufferVT(dAtA[:size])
}

func (m *ExecControllerResponse) MarshalToSizedBufferVT(dAtA []byte) (int, error) {
	if m == nil {
		return 0, nil
	}
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.unknownFields != nil {
		i -= len(m.unknownFields)
		copy(dAtA[i:], m.unknownFields)
	}
	if len(m.ErrorInfo) > 0 {
		i -= len(m.ErrorInfo)
		copy(dAtA[i:], m.ErrorInfo)
		i = protobuf_go_lite.EncodeVarint(dAtA, i, uint64(len(m.ErrorInfo)))
		i--
		dAtA[i] = 0x22
	}
	if m.ControllerInfo != nil {
		size, err := m.ControllerInfo.MarshalToSizedBufferVT(dAtA[:i])
		if err != nil {
			return 0, err
		}
		i -= size
		i = protobuf_go_lite.EncodeVarint(dAtA, i, uint64(size))
		i--
		dAtA[i] = 0x1a
	}
	if m.Status != 0 {
		i = protobuf_go_lite.EncodeVarint(dAtA, i, uint64(m.Status))
		i--
		dAtA[i] = 0x10
	}
	if len(m.Id) > 0 {
		i -= len(m.Id)
		copy(dAtA[i:], m.Id)
		i = protobuf_go_lite.EncodeVarint(dAtA, i, uint64(len(m.Id)))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *ExecControllerRequest) SizeVT() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.ConfigSet != nil {
		l = m.ConfigSet.SizeVT()
		n += 1 + l + protobuf_go_lite.SizeOfVarint(uint64(l))
	}
	l = len(m.ConfigSetYaml)
	if l > 0 {
		n += 1 + l + protobuf_go_lite.SizeOfVarint(uint64(l))
	}
	if m.ConfigSetYamlOverwrite {
		n += 2
	}
	n += len(m.unknownFields)
	return n
}

func (m *ExecControllerResponse) SizeVT() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Id)
	if l > 0 {
		n += 1 + l + protobuf_go_lite.SizeOfVarint(uint64(l))
	}
	if m.Status != 0 {
		n += 1 + protobuf_go_lite.SizeOfVarint(uint64(m.Status))
	}
	if m.ControllerInfo != nil {
		l = m.ControllerInfo.SizeVT()
		n += 1 + l + protobuf_go_lite.SizeOfVarint(uint64(l))
	}
	l = len(m.ErrorInfo)
	if l > 0 {
		n += 1 + l + protobuf_go_lite.SizeOfVarint(uint64(l))
	}
	n += len(m.unknownFields)
	return n
}

func (x ControllerStatus) MarshalProtoText() string {
	return x.String()
}
func (x *ExecControllerRequest) MarshalProtoText() string {
	var sb strings.Builder
	sb.WriteString("ExecControllerRequest {")
	if x.ConfigSet != nil {
		if sb.Len() > 23 {
			sb.WriteString(" ")
		}
		sb.WriteString("config_set: ")
		sb.WriteString(x.ConfigSet.MarshalProtoText())
	}
	if x.ConfigSetYaml != "" {
		if sb.Len() > 23 {
			sb.WriteString(" ")
		}
		sb.WriteString("config_set_yaml: ")
		sb.WriteString(strconv.Quote(x.ConfigSetYaml))
	}
	if x.ConfigSetYamlOverwrite != false {
		if sb.Len() > 23 {
			sb.WriteString(" ")
		}
		sb.WriteString("config_set_yaml_overwrite: ")
		sb.WriteString(strconv.FormatBool(x.ConfigSetYamlOverwrite))
	}
	sb.WriteString("}")
	return sb.String()
}

func (x *ExecControllerRequest) String() string {
	return x.MarshalProtoText()
}
func (x *ExecControllerResponse) MarshalProtoText() string {
	var sb strings.Builder
	sb.WriteString("ExecControllerResponse {")
	if x.Id != "" {
		if sb.Len() > 24 {
			sb.WriteString(" ")
		}
		sb.WriteString("id: ")
		sb.WriteString(strconv.Quote(x.Id))
	}
	if x.Status != 0 {
		if sb.Len() > 24 {
			sb.WriteString(" ")
		}
		sb.WriteString("status: ")
		sb.WriteString("\"")
		sb.WriteString(ControllerStatus(x.Status).String())
		sb.WriteString("\"")
	}
	if x.ControllerInfo != nil {
		if sb.Len() > 24 {
			sb.WriteString(" ")
		}
		sb.WriteString("controller_info: ")
		sb.WriteString(x.ControllerInfo.MarshalProtoText())
	}
	if x.ErrorInfo != "" {
		if sb.Len() > 24 {
			sb.WriteString(" ")
		}
		sb.WriteString("error_info: ")
		sb.WriteString(strconv.Quote(x.ErrorInfo))
	}
	sb.WriteString("}")
	return sb.String()
}

func (x *ExecControllerResponse) String() string {
	return x.MarshalProtoText()
}
func (m *ExecControllerRequest) UnmarshalVT(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return protobuf_go_lite.ErrIntOverflow
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ExecControllerRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ExecControllerRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ConfigSet", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return protobuf_go_lite.ErrIntOverflow
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ConfigSet == nil {
				m.ConfigSet = &proto.ConfigSet{}
			}
			if err := m.ConfigSet.UnmarshalVT(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ConfigSetYaml", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return protobuf_go_lite.ErrIntOverflow
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ConfigSetYaml = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 3:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field ConfigSetYamlOverwrite", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return protobuf_go_lite.ErrIntOverflow
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				v |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			m.ConfigSetYamlOverwrite = bool(v != 0)
		default:
			iNdEx = preIndex
			skippy, err := protobuf_go_lite.Skip(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			m.unknownFields = append(m.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ExecControllerResponse) UnmarshalVT(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return protobuf_go_lite.ErrIntOverflow
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ExecControllerResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ExecControllerResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return protobuf_go_lite.ErrIntOverflow
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Id = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
			}
			m.Status = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return protobuf_go_lite.ErrIntOverflow
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Status |= ControllerStatus(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ControllerInfo", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return protobuf_go_lite.ErrIntOverflow
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ControllerInfo == nil {
				m.ControllerInfo = &controller.Info{}
			}
			if err := m.ControllerInfo.UnmarshalVT(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ErrorInfo", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return protobuf_go_lite.ErrIntOverflow
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ErrorInfo = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := protobuf_go_lite.Skip(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return protobuf_go_lite.ErrInvalidLength
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			m.unknownFields = append(m.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
