// CLI annotation extension type.
//
// The fraser `ia` CLI is proto-driven: `cmd/protoc-gen-ia-cli` walks every
// service in the buf input and emits a Cobra command per RPC. The default
// mapping follows the IA convention (service noun + verb), and per-RPC
// `(tars.cli.v1.command)` annotations override individual mappings. Per-
// field `(tars.cli.v1.field)` annotations rename the generated CLI flag.
//
// Field number 50002 mirrors IA's allocation. Fraser's auth extension uses
// 50001; this proto reserves 50002 in google.protobuf.MethodOptions for
// CLI customization and 50003 in google.protobuf.FieldOptions for the
// per-field flag customization.

// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.10
// 	protoc        (unknown)
// source: tars/cli/v1/cli.proto

package cliv1

import (
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	descriptorpb "google.golang.org/protobuf/types/descriptorpb"
	reflect "reflect"
	sync "sync"
	unsafe "unsafe"
)

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)
)

// Command customizes the CLI mapping for a single RPC.
//
// Every field is optional -- omitting `(tars.cli.v1.command)` leaves the
// default mapping in place. Customizations are additive: each field
// overrides one default behavior.
type Command struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Override the last segment of the command path. Default is the verb
	// portion of the RPC name in lower-kebab-case.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Additional command names that resolve to the same command. Useful for
	// short aliases on long actions, e.g. ["stop"] for "drain".
	Aliases []string `protobuf:"bytes,2,rep,name=aliases,proto3" json:"aliases,omitempty"`
	// Request field name (snake_case) that becomes the command's positional
	// argument instead of a flag. Typically the resource ID for action verbs:
	// dataplane_id on DrainDataplane -> `ia dataplanes drain DP_ID`.
	PrimaryFlag string `protobuf:"bytes,3,opt,name=primary_flag,json=primaryFlag,proto3" json:"primary_flag,omitempty"`
	// Hide the command from --help. The command is still registered and
	// invokable; just not advertised. Used for internal-only commands.
	Hidden bool `protobuf:"varint,5,opt,name=hidden,proto3" json:"hidden,omitempty"`
	// Full command path override. When set, takes precedence over both the
	// default service-noun + verb mapping and the `name` field. Each entry
	// is a segment in the command tree, e.g. ["whoami"] mounts the RPC at
	// the root, ["keys", "create"] mounts it under a `keys` parent.
	Path          []string `protobuf:"bytes,7,rep,name=path,proto3" json:"path,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*Command) ProtoMessage() {}

func (x *Command) ProtoReflect() protoreflect.Message {
	mi := &file_tars_cli_v1_cli_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 Command.ProtoReflect.Descriptor instead.
func (*Command) Descriptor() ([]byte, []int) {
	return file_tars_cli_v1_cli_proto_rawDescGZIP(), []int{0}
}

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

func (x *Command) GetAliases() []string {
	if x != nil {
		return x.Aliases
	}
	return nil
}

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

func (x *Command) GetHidden() bool {
	if x != nil {
		return x.Hidden
	}
	return false
}

func (x *Command) GetPath() []string {
	if x != nil {
		return x.Path
	}
	return nil
}

// Field customizes the CLI mapping for a single request-message field.
//
// Omitting `(tars.cli.v1.field)` leaves the default mapping in place
// (snake_case -> kebab-case flag name).
type Field struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Override the generated flag name. Default is the field name converted
	// from snake_case to kebab-case (e.g. customer_id -> customer-id).
	// Setting `flag: "customer"` produces `--customer`.
	Flag string `protobuf:"bytes,1,opt,name=flag,proto3" json:"flag,omitempty"`
	// Hide the flag from --help. The flag is still parsed when supplied.
	Hidden        bool `protobuf:"varint,2,opt,name=hidden,proto3" json:"hidden,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*Field) ProtoMessage() {}

func (x *Field) ProtoReflect() protoreflect.Message {
	mi := &file_tars_cli_v1_cli_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 Field.ProtoReflect.Descriptor instead.
func (*Field) Descriptor() ([]byte, []int) {
	return file_tars_cli_v1_cli_proto_rawDescGZIP(), []int{1}
}

func (x *Field) GetFlag() string {
	if x != nil {
		return x.Flag
	}
	return ""
}

func (x *Field) GetHidden() bool {
	if x != nil {
		return x.Hidden
	}
	return false
}

var file_tars_cli_v1_cli_proto_extTypes = []protoimpl.ExtensionInfo{
	{
		ExtendedType:  (*descriptorpb.MethodOptions)(nil),
		ExtensionType: (*Command)(nil),
		Field:         50002,
		Name:          "tars.cli.v1.command",
		Tag:           "bytes,50002,opt,name=command",
		Filename:      "tars/cli/v1/cli.proto",
	},
	{
		ExtendedType:  (*descriptorpb.FieldOptions)(nil),
		ExtensionType: (*Field)(nil),
		Field:         50003,
		Name:          "tars.cli.v1.field",
		Tag:           "bytes,50003,opt,name=field",
		Filename:      "tars/cli/v1/cli.proto",
	},
}

// Extension fields to descriptorpb.MethodOptions.
var (
	// Field 50002 holds the CLI-mapping override for this RPC. Coexists
	// with the existing `tars.auth.v1.auth` extension at 50001.
	//
	// optional tars.cli.v1.Command command = 50002;
	E_Command = &file_tars_cli_v1_cli_proto_extTypes[0]
)

// Extension fields to descriptorpb.FieldOptions.
var (
	// Field 50003 holds the CLI flag override for this request-message
	// field. Picked to sit next to the method-level 50002 allocation.
	//
	// optional tars.cli.v1.Field field = 50003;
	E_Field = &file_tars_cli_v1_cli_proto_extTypes[1]
)

var File_tars_cli_v1_cli_proto protoreflect.FileDescriptor

const file_tars_cli_v1_cli_proto_rawDesc = "" +
	"\n" +
	"\x15tars/cli/v1/cli.proto\x12\vtars.cli.v1\x1a google/protobuf/descriptor.proto\"\xac\x01\n" +
	"\aCommand\x12\x12\n" +
	"\x04name\x18\x01 \x01(\tR\x04name\x12\x18\n" +
	"\aaliases\x18\x02 \x03(\tR\aaliases\x12!\n" +
	"\fprimary_flag\x18\x03 \x01(\tR\vprimaryFlag\x12\x16\n" +
	"\x06hidden\x18\x05 \x01(\bR\x06hidden\x12\x12\n" +
	"\x04path\x18\a \x03(\tR\x04pathJ\x04\b\x04\x10\x05J\x04\b\x06\x10\aR\aconfirmR\x0foutput_template\"3\n" +
	"\x05Field\x12\x12\n" +
	"\x04flag\x18\x01 \x01(\tR\x04flag\x12\x16\n" +
	"\x06hidden\x18\x02 \x01(\bR\x06hidden:P\n" +
	"\acommand\x12\x1e.google.protobuf.MethodOptions\x18҆\x03 \x01(\v2\x14.tars.cli.v1.CommandR\acommand:I\n" +
	"\x05field\x12\x1d.google.protobuf.FieldOptions\x18ӆ\x03 \x01(\v2\x12.tars.cli.v1.FieldR\x05fieldB\x9c\x01\n" +
	"\x0fcom.tars.cli.v1B\bCliProtoP\x01Z1github.com/tetrateio/fraser/api/tars/cli/v1;cliv1\xa2\x02\x03TCX\xaa\x02\vTars.Cli.V1\xca\x02\vTars\\Cli\\V1\xe2\x02\x17Tars\\Cli\\V1\\GPBMetadata\xea\x02\rTars::Cli::V1b\x06proto3"

var (
	file_tars_cli_v1_cli_proto_rawDescOnce sync.Once
	file_tars_cli_v1_cli_proto_rawDescData []byte
)

func file_tars_cli_v1_cli_proto_rawDescGZIP() []byte {
	file_tars_cli_v1_cli_proto_rawDescOnce.Do(func() {
		file_tars_cli_v1_cli_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_tars_cli_v1_cli_proto_rawDesc), len(file_tars_cli_v1_cli_proto_rawDesc)))
	})
	return file_tars_cli_v1_cli_proto_rawDescData
}

var file_tars_cli_v1_cli_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
var file_tars_cli_v1_cli_proto_goTypes = []any{
	(*Command)(nil),                    // 0: tars.cli.v1.Command
	(*Field)(nil),                      // 1: tars.cli.v1.Field
	(*descriptorpb.MethodOptions)(nil), // 2: google.protobuf.MethodOptions
	(*descriptorpb.FieldOptions)(nil),  // 3: google.protobuf.FieldOptions
}
var file_tars_cli_v1_cli_proto_depIdxs = []int32{
	2, // 0: tars.cli.v1.command:extendee -> google.protobuf.MethodOptions
	3, // 1: tars.cli.v1.field:extendee -> google.protobuf.FieldOptions
	0, // 2: tars.cli.v1.command:type_name -> tars.cli.v1.Command
	1, // 3: tars.cli.v1.field:type_name -> tars.cli.v1.Field
	4, // [4:4] is the sub-list for method output_type
	4, // [4:4] is the sub-list for method input_type
	2, // [2:4] is the sub-list for extension type_name
	0, // [0:2] is the sub-list for extension extendee
	0, // [0:0] is the sub-list for field type_name
}

func init() { file_tars_cli_v1_cli_proto_init() }
func file_tars_cli_v1_cli_proto_init() {
	if File_tars_cli_v1_cli_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_tars_cli_v1_cli_proto_rawDesc), len(file_tars_cli_v1_cli_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   2,
			NumExtensions: 2,
			NumServices:   0,
		},
		GoTypes:           file_tars_cli_v1_cli_proto_goTypes,
		DependencyIndexes: file_tars_cli_v1_cli_proto_depIdxs,
		MessageInfos:      file_tars_cli_v1_cli_proto_msgTypes,
		ExtensionInfos:    file_tars_cli_v1_cli_proto_extTypes,
	}.Build()
	File_tars_cli_v1_cli_proto = out.File
	file_tars_cli_v1_cli_proto_goTypes = nil
	file_tars_cli_v1_cli_proto_depIdxs = nil
}
