// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.8
// 	protoc        v6.32.0
// source: protos/user.proto

package proto

import (
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	emptypb "google.golang.org/protobuf/types/known/emptypb"
	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)
)

type UsernameValidation int32

const (
	UsernameValidation_OK              UsernameValidation = 0
	UsernameValidation_ALREADY_IN_USE  UsernameValidation = 1
	UsernameValidation_SYSTEM_RESERVED UsernameValidation = 2
	UsernameValidation_INVALID_CHARS   UsernameValidation = 3
	UsernameValidation_TOO_LONG        UsernameValidation = 4
	UsernameValidation_EMPTY           UsernameValidation = 5
)

// Enum value maps for UsernameValidation.
var (
	UsernameValidation_name = map[int32]string{
		0: "OK",
		1: "ALREADY_IN_USE",
		2: "SYSTEM_RESERVED",
		3: "INVALID_CHARS",
		4: "TOO_LONG",
		5: "EMPTY",
	}
	UsernameValidation_value = map[string]int32{
		"OK":              0,
		"ALREADY_IN_USE":  1,
		"SYSTEM_RESERVED": 2,
		"INVALID_CHARS":   3,
		"TOO_LONG":        4,
		"EMPTY":           5,
	}
)

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

func (x UsernameValidation) String() string {
	return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}

func (UsernameValidation) Descriptor() protoreflect.EnumDescriptor {
	return file_protos_user_proto_enumTypes[0].Descriptor()
}

func (UsernameValidation) Type() protoreflect.EnumType {
	return &file_protos_user_proto_enumTypes[0]
}

func (x UsernameValidation) Number() protoreflect.EnumNumber {
	return protoreflect.EnumNumber(x)
}

// Deprecated: Use UsernameValidation.Descriptor instead.
func (UsernameValidation) EnumDescriptor() ([]byte, []int) {
	return file_protos_user_proto_rawDescGZIP(), []int{0}
}

type User struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	RealName      string                 `protobuf:"bytes,1,opt,name=real_name,json=realName,proto3" json:"real_name,omitempty"`
	Hostname      string                 `protobuf:"bytes,2,opt,name=hostname,proto3" json:"hostname,omitempty"`
	Username      string                 `protobuf:"bytes,3,opt,name=username,proto3" json:"username,omitempty"`
	Password      string                 `protobuf:"bytes,4,opt,name=password,proto3" json:"password,omitempty"`
	AutoLogin     bool                   `protobuf:"varint,5,opt,name=auto_login,json=autoLogin,proto3" json:"auto_login,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*User) ProtoMessage() {}

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

func (x *User) GetRealName() string {
	if x != nil {
		return x.RealName
	}
	return ""
}

func (x *User) GetHostname() string {
	if x != nil {
		return x.Hostname
	}
	return ""
}

func (x *User) GetUsername() string {
	if x != nil {
		return x.Username
	}
	return ""
}

func (x *User) GetPassword() string {
	if x != nil {
		return x.Password
	}
	return ""
}

func (x *User) GetAutoLogin() bool {
	if x != nil {
		return x.AutoLogin
	}
	return false
}

type CreateUserRequest struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	User          *User                  `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"`
	IsAdmin       bool                   `protobuf:"varint,2,opt,name=is_admin,json=isAdmin,proto3" json:"is_admin,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*CreateUserRequest) ProtoMessage() {}

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

func (x *CreateUserRequest) GetUser() *User {
	if x != nil {
		return x.User
	}
	return nil
}

func (x *CreateUserRequest) GetIsAdmin() bool {
	if x != nil {
		return x.IsAdmin
	}
	return false
}

type ValidateUsernameRequest struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Username      string                 `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *ValidateUsernameRequest) Reset() {
	*x = ValidateUsernameRequest{}
	mi := &file_protos_user_proto_msgTypes[2]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

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

func (*ValidateUsernameRequest) ProtoMessage() {}

func (x *ValidateUsernameRequest) ProtoReflect() protoreflect.Message {
	mi := &file_protos_user_proto_msgTypes[2]
	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 ValidateUsernameRequest.ProtoReflect.Descriptor instead.
func (*ValidateUsernameRequest) Descriptor() ([]byte, []int) {
	return file_protos_user_proto_rawDescGZIP(), []int{2}
}

func (x *ValidateUsernameRequest) GetUsername() string {
	if x != nil {
		return x.Username
	}
	return ""
}

type ValidateUsernameResponse struct {
	state              protoimpl.MessageState `protogen:"open.v1"`
	UsernameValidation UsernameValidation     `protobuf:"varint,1,opt,name=username_validation,json=usernameValidation,proto3,enum=user.UsernameValidation" json:"username_validation,omitempty"`
	unknownFields      protoimpl.UnknownFields
	sizeCache          protoimpl.SizeCache
}

func (x *ValidateUsernameResponse) Reset() {
	*x = ValidateUsernameResponse{}
	mi := &file_protos_user_proto_msgTypes[3]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

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

func (*ValidateUsernameResponse) ProtoMessage() {}

func (x *ValidateUsernameResponse) ProtoReflect() protoreflect.Message {
	mi := &file_protos_user_proto_msgTypes[3]
	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 ValidateUsernameResponse.ProtoReflect.Descriptor instead.
func (*ValidateUsernameResponse) Descriptor() ([]byte, []int) {
	return file_protos_user_proto_rawDescGZIP(), []int{3}
}

func (x *ValidateUsernameResponse) GetUsernameValidation() UsernameValidation {
	if x != nil {
		return x.UsernameValidation
	}
	return UsernameValidation_OK
}

var File_protos_user_proto protoreflect.FileDescriptor

const file_protos_user_proto_rawDesc = "" +
	"\n" +
	"\x11protos/user.proto\x12\x04user\x1a\x1bgoogle/protobuf/empty.proto\"\x96\x01\n" +
	"\x04User\x12\x1b\n" +
	"\treal_name\x18\x01 \x01(\tR\brealName\x12\x1a\n" +
	"\bhostname\x18\x02 \x01(\tR\bhostname\x12\x1a\n" +
	"\busername\x18\x03 \x01(\tR\busername\x12\x1a\n" +
	"\bpassword\x18\x04 \x01(\tR\bpassword\x12\x1d\n" +
	"\n" +
	"auto_login\x18\x05 \x01(\bR\tautoLogin\"N\n" +
	"\x11CreateUserRequest\x12\x1e\n" +
	"\x04user\x18\x01 \x01(\v2\n" +
	".user.UserR\x04user\x12\x19\n" +
	"\bis_admin\x18\x02 \x01(\bR\aisAdmin\"5\n" +
	"\x17ValidateUsernameRequest\x12\x1a\n" +
	"\busername\x18\x01 \x01(\tR\busername\"e\n" +
	"\x18ValidateUsernameResponse\x12I\n" +
	"\x13username_validation\x18\x01 \x01(\x0e2\x18.user.UsernameValidationR\x12usernameValidation*q\n" +
	"\x12UsernameValidation\x12\x06\n" +
	"\x02OK\x10\x00\x12\x12\n" +
	"\x0eALREADY_IN_USE\x10\x01\x12\x13\n" +
	"\x0fSYSTEM_RESERVED\x10\x02\x12\x11\n" +
	"\rINVALID_CHARS\x10\x03\x12\f\n" +
	"\bTOO_LONG\x10\x04\x12\t\n" +
	"\x05EMPTY\x10\x052\x9f\x01\n" +
	"\vUserService\x12=\n" +
	"\n" +
	"CreateUser\x12\x17.user.CreateUserRequest\x1a\x16.google.protobuf.Empty\x12Q\n" +
	"\x10ValidateUsername\x12\x1d.user.ValidateUsernameRequest\x1a\x1e.user.ValidateUsernameResponseB;Z9github.com/canonical/ubuntu-desktop-provision/provd/protob\x06proto3"

var (
	file_protos_user_proto_rawDescOnce sync.Once
	file_protos_user_proto_rawDescData []byte
)

func file_protos_user_proto_rawDescGZIP() []byte {
	file_protos_user_proto_rawDescOnce.Do(func() {
		file_protos_user_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_protos_user_proto_rawDesc), len(file_protos_user_proto_rawDesc)))
	})
	return file_protos_user_proto_rawDescData
}

var file_protos_user_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
var file_protos_user_proto_msgTypes = make([]protoimpl.MessageInfo, 4)
var file_protos_user_proto_goTypes = []any{
	(UsernameValidation)(0),          // 0: user.UsernameValidation
	(*User)(nil),                     // 1: user.User
	(*CreateUserRequest)(nil),        // 2: user.CreateUserRequest
	(*ValidateUsernameRequest)(nil),  // 3: user.ValidateUsernameRequest
	(*ValidateUsernameResponse)(nil), // 4: user.ValidateUsernameResponse
	(*emptypb.Empty)(nil),            // 5: google.protobuf.Empty
}
var file_protos_user_proto_depIdxs = []int32{
	1, // 0: user.CreateUserRequest.user:type_name -> user.User
	0, // 1: user.ValidateUsernameResponse.username_validation:type_name -> user.UsernameValidation
	2, // 2: user.UserService.CreateUser:input_type -> user.CreateUserRequest
	3, // 3: user.UserService.ValidateUsername:input_type -> user.ValidateUsernameRequest
	5, // 4: user.UserService.CreateUser:output_type -> google.protobuf.Empty
	4, // 5: user.UserService.ValidateUsername:output_type -> user.ValidateUsernameResponse
	4, // [4:6] is the sub-list for method output_type
	2, // [2:4] is the sub-list for method input_type
	2, // [2:2] is the sub-list for extension type_name
	2, // [2:2] is the sub-list for extension extendee
	0, // [0:2] is the sub-list for field type_name
}

func init() { file_protos_user_proto_init() }
func file_protos_user_proto_init() {
	if File_protos_user_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_protos_user_proto_rawDesc), len(file_protos_user_proto_rawDesc)),
			NumEnums:      1,
			NumMessages:   4,
			NumExtensions: 0,
			NumServices:   1,
		},
		GoTypes:           file_protos_user_proto_goTypes,
		DependencyIndexes: file_protos_user_proto_depIdxs,
		EnumInfos:         file_protos_user_proto_enumTypes,
		MessageInfos:      file_protos_user_proto_msgTypes,
	}.Build()
	File_protos_user_proto = out.File
	file_protos_user_proto_goTypes = nil
	file_protos_user_proto_depIdxs = nil
}
