// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.10
// 	protoc        v3.21.12
// source: api.proto

package protogen

import (
	reflect "reflect"
	sync "sync"
	unsafe "unsafe"

	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
)

const (
	// Verify that this generated code is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
	// Verify that runtime/protoimpl is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)

// CommandRequest defines the command to execute and authentication key.
type CommandRequest struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Command       string                 `protobuf:"bytes,1,opt,name=command,proto3" json:"command,omitempty"` // The command to run (e.g., "cat /scripts/seqno").
	Data          []byte                 `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`       // backup job.
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *CommandRequest) Reset() {
	*x = CommandRequest{}
	mi := &file_api_proto_msgTypes[0]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *CommandRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CommandRequest) ProtoMessage() {}

func (x *CommandRequest) ProtoReflect() protoreflect.Message {
	mi := &file_api_proto_msgTypes[0]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CommandRequest.ProtoReflect.Descriptor instead.
func (*CommandRequest) Descriptor() ([]byte, []int) {
	return file_api_proto_rawDescGZIP(), []int{0}
}

func (x *CommandRequest) GetCommand() string {
	if x != nil {
		return x.Command
	}
	return ""
}

func (x *CommandRequest) GetData() []byte {
	if x != nil {
		return x.Data
	}
	return nil
}

// CommandResponse contains the command output or error.
type CommandResponse struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Status        string                 `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` // "success" or "error".
	Output        []byte                 `protobuf:"bytes,2,opt,name=output,proto3" json:"output,omitempty"` // Integer output of the command (e.g., contents of /scripts/seqno).
	Error         string                 `protobuf:"bytes,3,opt,name=error,proto3" json:"error,omitempty"`   // Error message, if any.
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *CommandResponse) Reset() {
	*x = CommandResponse{}
	mi := &file_api_proto_msgTypes[1]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *CommandResponse) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CommandResponse) ProtoMessage() {}

func (x *CommandResponse) ProtoReflect() protoreflect.Message {
	mi := &file_api_proto_msgTypes[1]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CommandResponse.ProtoReflect.Descriptor instead.
func (*CommandResponse) Descriptor() ([]byte, []int) {
	return file_api_proto_rawDescGZIP(), []int{1}
}

func (x *CommandResponse) GetStatus() string {
	if x != nil {
		return x.Status
	}
	return ""
}

func (x *CommandResponse) GetOutput() []byte {
	if x != nil {
		return x.Output
	}
	return nil
}

func (x *CommandResponse) GetError() string {
	if x != nil {
		return x.Error
	}
	return ""
}

var File_api_proto protoreflect.FileDescriptor

const file_api_proto_rawDesc = "" +
	"\n" +
	"\tapi.proto\x12\x05proto\">\n" +
	"\x0eCommandRequest\x12\x18\n" +
	"\acommand\x18\x01 \x01(\tR\acommand\x12\x12\n" +
	"\x04data\x18\x02 \x01(\fR\x04data\"W\n" +
	"\x0fCommandResponse\x12\x16\n" +
	"\x06status\x18\x01 \x01(\tR\x06status\x12\x16\n" +
	"\x06output\x18\x02 \x01(\fR\x06output\x12\x14\n" +
	"\x05error\x18\x03 \x01(\tR\x05error2Q\n" +
	"\x0eCommandService\x12?\n" +
	"\x0eExecuteCommand\x12\x15.proto.CommandRequest\x1a\x16.proto.CommandResponseB!Z\x1fpkg/utils/grpc/mariadb/protogenb\x06proto3"

var (
	file_api_proto_rawDescOnce sync.Once
	file_api_proto_rawDescData []byte
)

func file_api_proto_rawDescGZIP() []byte {
	file_api_proto_rawDescOnce.Do(func() {
		file_api_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_api_proto_rawDesc), len(file_api_proto_rawDesc)))
	})
	return file_api_proto_rawDescData
}

var file_api_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
var file_api_proto_goTypes = []any{
	(*CommandRequest)(nil),  // 0: proto.CommandRequest
	(*CommandResponse)(nil), // 1: proto.CommandResponse
}
var file_api_proto_depIdxs = []int32{
	0, // 0: proto.CommandService.ExecuteCommand:input_type -> proto.CommandRequest
	1, // 1: proto.CommandService.ExecuteCommand:output_type -> proto.CommandResponse
	1, // [1:2] is the sub-list for method output_type
	0, // [0:1] is the sub-list for method input_type
	0, // [0:0] is the sub-list for extension type_name
	0, // [0:0] is the sub-list for extension extendee
	0, // [0:0] is the sub-list for field type_name
}

func init() { file_api_proto_init() }
func file_api_proto_init() {
	if File_api_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_api_proto_rawDesc), len(file_api_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   2,
			NumExtensions: 0,
			NumServices:   1,
		},
		GoTypes:           file_api_proto_goTypes,
		DependencyIndexes: file_api_proto_depIdxs,
		MessageInfos:      file_api_proto_msgTypes,
	}.Build()
	File_api_proto = out.File
	file_api_proto_goTypes = nil
	file_api_proto_depIdxs = nil
}
