// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.5.1
// - protoc             v3.21.12
// source: yandex/cloud/ai/assistants/v1/assistant_service.proto

package assistants

import (
	context "context"
	grpc "google.golang.org/grpc"
	codes "google.golang.org/grpc/codes"
	status "google.golang.org/grpc/status"
)

// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
// Requires gRPC-Go v1.64.0 or later.
const _ = grpc.SupportPackageIsVersion9

const (
	AssistantService_Create_FullMethodName       = "/yandex.cloud.ai.assistants.v1.AssistantService/Create"
	AssistantService_Get_FullMethodName          = "/yandex.cloud.ai.assistants.v1.AssistantService/Get"
	AssistantService_Update_FullMethodName       = "/yandex.cloud.ai.assistants.v1.AssistantService/Update"
	AssistantService_Delete_FullMethodName       = "/yandex.cloud.ai.assistants.v1.AssistantService/Delete"
	AssistantService_List_FullMethodName         = "/yandex.cloud.ai.assistants.v1.AssistantService/List"
	AssistantService_ListVersions_FullMethodName = "/yandex.cloud.ai.assistants.v1.AssistantService/ListVersions"
)

// AssistantServiceClient is the client API for AssistantService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
//
// AssistantService provides operations for managing assistants.
type AssistantServiceClient interface {
	// Create a new assistant.
	Create(ctx context.Context, in *CreateAssistantRequest, opts ...grpc.CallOption) (*Assistant, error)
	// Retrieve details of a specific assistant by its ID.
	Get(ctx context.Context, in *GetAssistantRequest, opts ...grpc.CallOption) (*Assistant, error)
	// Update an existing assistant.
	Update(ctx context.Context, in *UpdateAssistantRequest, opts ...grpc.CallOption) (*Assistant, error)
	// Delete an assistant by its ID.
	Delete(ctx context.Context, in *DeleteAssistantRequest, opts ...grpc.CallOption) (*DeleteAssistantResponse, error)
	// List assistants in a specific folder.
	List(ctx context.Context, in *ListAssistantsRequest, opts ...grpc.CallOption) (*ListAssistantsResponse, error)
	// Lists all versions of a specific assistant.
	ListVersions(ctx context.Context, in *ListAssistantVersionsRequest, opts ...grpc.CallOption) (*ListAssistantVersionsResponse, error)
}

type assistantServiceClient struct {
	cc grpc.ClientConnInterface
}

func NewAssistantServiceClient(cc grpc.ClientConnInterface) AssistantServiceClient {
	return &assistantServiceClient{cc}
}

func (c *assistantServiceClient) Create(ctx context.Context, in *CreateAssistantRequest, opts ...grpc.CallOption) (*Assistant, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(Assistant)
	err := c.cc.Invoke(ctx, AssistantService_Create_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *assistantServiceClient) Get(ctx context.Context, in *GetAssistantRequest, opts ...grpc.CallOption) (*Assistant, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(Assistant)
	err := c.cc.Invoke(ctx, AssistantService_Get_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *assistantServiceClient) Update(ctx context.Context, in *UpdateAssistantRequest, opts ...grpc.CallOption) (*Assistant, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(Assistant)
	err := c.cc.Invoke(ctx, AssistantService_Update_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *assistantServiceClient) Delete(ctx context.Context, in *DeleteAssistantRequest, opts ...grpc.CallOption) (*DeleteAssistantResponse, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(DeleteAssistantResponse)
	err := c.cc.Invoke(ctx, AssistantService_Delete_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *assistantServiceClient) List(ctx context.Context, in *ListAssistantsRequest, opts ...grpc.CallOption) (*ListAssistantsResponse, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(ListAssistantsResponse)
	err := c.cc.Invoke(ctx, AssistantService_List_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *assistantServiceClient) ListVersions(ctx context.Context, in *ListAssistantVersionsRequest, opts ...grpc.CallOption) (*ListAssistantVersionsResponse, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(ListAssistantVersionsResponse)
	err := c.cc.Invoke(ctx, AssistantService_ListVersions_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// AssistantServiceServer is the server API for AssistantService service.
// All implementations should embed UnimplementedAssistantServiceServer
// for forward compatibility.
//
// AssistantService provides operations for managing assistants.
type AssistantServiceServer interface {
	// Create a new assistant.
	Create(context.Context, *CreateAssistantRequest) (*Assistant, error)
	// Retrieve details of a specific assistant by its ID.
	Get(context.Context, *GetAssistantRequest) (*Assistant, error)
	// Update an existing assistant.
	Update(context.Context, *UpdateAssistantRequest) (*Assistant, error)
	// Delete an assistant by its ID.
	Delete(context.Context, *DeleteAssistantRequest) (*DeleteAssistantResponse, error)
	// List assistants in a specific folder.
	List(context.Context, *ListAssistantsRequest) (*ListAssistantsResponse, error)
	// Lists all versions of a specific assistant.
	ListVersions(context.Context, *ListAssistantVersionsRequest) (*ListAssistantVersionsResponse, error)
}

// UnimplementedAssistantServiceServer should be embedded to have
// forward compatible implementations.
//
// NOTE: this should be embedded by value instead of pointer to avoid a nil
// pointer dereference when methods are called.
type UnimplementedAssistantServiceServer struct{}

func (UnimplementedAssistantServiceServer) Create(context.Context, *CreateAssistantRequest) (*Assistant, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Create not implemented")
}
func (UnimplementedAssistantServiceServer) Get(context.Context, *GetAssistantRequest) (*Assistant, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Get not implemented")
}
func (UnimplementedAssistantServiceServer) Update(context.Context, *UpdateAssistantRequest) (*Assistant, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Update not implemented")
}
func (UnimplementedAssistantServiceServer) Delete(context.Context, *DeleteAssistantRequest) (*DeleteAssistantResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Delete not implemented")
}
func (UnimplementedAssistantServiceServer) List(context.Context, *ListAssistantsRequest) (*ListAssistantsResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method List not implemented")
}
func (UnimplementedAssistantServiceServer) ListVersions(context.Context, *ListAssistantVersionsRequest) (*ListAssistantVersionsResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ListVersions not implemented")
}
func (UnimplementedAssistantServiceServer) testEmbeddedByValue() {}

// UnsafeAssistantServiceServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to AssistantServiceServer will
// result in compilation errors.
type UnsafeAssistantServiceServer interface {
	mustEmbedUnimplementedAssistantServiceServer()
}

func RegisterAssistantServiceServer(s grpc.ServiceRegistrar, srv AssistantServiceServer) {
	// If the following call pancis, it indicates UnimplementedAssistantServiceServer was
	// embedded by pointer and is nil.  This will cause panics if an
	// unimplemented method is ever invoked, so we test this at initialization
	// time to prevent it from happening at runtime later due to I/O.
	if t, ok := srv.(interface{ testEmbeddedByValue() }); ok {
		t.testEmbeddedByValue()
	}
	s.RegisterService(&AssistantService_ServiceDesc, srv)
}

func _AssistantService_Create_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(CreateAssistantRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AssistantServiceServer).Create(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AssistantService_Create_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AssistantServiceServer).Create(ctx, req.(*CreateAssistantRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AssistantService_Get_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GetAssistantRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AssistantServiceServer).Get(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AssistantService_Get_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AssistantServiceServer).Get(ctx, req.(*GetAssistantRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AssistantService_Update_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(UpdateAssistantRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AssistantServiceServer).Update(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AssistantService_Update_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AssistantServiceServer).Update(ctx, req.(*UpdateAssistantRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AssistantService_Delete_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(DeleteAssistantRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AssistantServiceServer).Delete(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AssistantService_Delete_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AssistantServiceServer).Delete(ctx, req.(*DeleteAssistantRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AssistantService_List_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ListAssistantsRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AssistantServiceServer).List(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AssistantService_List_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AssistantServiceServer).List(ctx, req.(*ListAssistantsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AssistantService_ListVersions_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ListAssistantVersionsRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AssistantServiceServer).ListVersions(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AssistantService_ListVersions_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AssistantServiceServer).ListVersions(ctx, req.(*ListAssistantVersionsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

// AssistantService_ServiceDesc is the grpc.ServiceDesc for AssistantService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var AssistantService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "yandex.cloud.ai.assistants.v1.AssistantService",
	HandlerType: (*AssistantServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Create",
			Handler:    _AssistantService_Create_Handler,
		},
		{
			MethodName: "Get",
			Handler:    _AssistantService_Get_Handler,
		},
		{
			MethodName: "Update",
			Handler:    _AssistantService_Update_Handler,
		},
		{
			MethodName: "Delete",
			Handler:    _AssistantService_Delete_Handler,
		},
		{
			MethodName: "List",
			Handler:    _AssistantService_List_Handler,
		},
		{
			MethodName: "ListVersions",
			Handler:    _AssistantService_ListVersions_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "yandex/cloud/ai/assistants/v1/assistant_service.proto",
}
