// 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/organizationmanager/v1/idp/synchronization_service.proto

package idp

import (
	context "context"
	operation "github.com/yandex-cloud/go-genproto/yandex/cloud/operation"
	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 (
	SynchronizationService_SetReplicationToken_FullMethodName           = "/yandex.cloud.organizationmanager.v1.idp.SynchronizationService/SetReplicationToken"
	SynchronizationService_ResetReplicationToken_FullMethodName         = "/yandex.cloud.organizationmanager.v1.idp.SynchronizationService/ResetReplicationToken"
	SynchronizationService_CreateSynchronizationSettings_FullMethodName = "/yandex.cloud.organizationmanager.v1.idp.SynchronizationService/CreateSynchronizationSettings"
	SynchronizationService_UpdateSynchronizationSettings_FullMethodName = "/yandex.cloud.organizationmanager.v1.idp.SynchronizationService/UpdateSynchronizationSettings"
	SynchronizationService_DeleteSynchronizationSettings_FullMethodName = "/yandex.cloud.organizationmanager.v1.idp.SynchronizationService/DeleteSynchronizationSettings"
	SynchronizationService_GetSynchronizationSettings_FullMethodName    = "/yandex.cloud.organizationmanager.v1.idp.SynchronizationService/GetSynchronizationSettings"
	SynchronizationService_ListSupportedAttributes_FullMethodName       = "/yandex.cloud.organizationmanager.v1.idp.SynchronizationService/ListSupportedAttributes"
)

// SynchronizationServiceClient is the client API for SynchronizationService 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.
//
// A set of methods for managing synchronization settings.
type SynchronizationServiceClient interface {
	// Sets the replication token for synchronization.
	SetReplicationToken(ctx context.Context, in *SetReplicationTokenRequest, opts ...grpc.CallOption) (*operation.Operation, error)
	// Resets the replication token for synchronization.
	ResetReplicationToken(ctx context.Context, in *ResetReplicationTokenRequest, opts ...grpc.CallOption) (*operation.Operation, error)
	// Creates synchronization settings for a subject container.
	CreateSynchronizationSettings(ctx context.Context, in *CreateSynchronizationSettingsRequest, opts ...grpc.CallOption) (*operation.Operation, error)
	// Updates synchronization settings for a subject container.
	UpdateSynchronizationSettings(ctx context.Context, in *UpdateSynchronizationSettingsRequest, opts ...grpc.CallOption) (*operation.Operation, error)
	// Deletes synchronization settings for a subject container.
	DeleteSynchronizationSettings(ctx context.Context, in *DeleteSynchronizationSettingsRequest, opts ...grpc.CallOption) (*operation.Operation, error)
	// Returns synchronization settings for a subject container.
	GetSynchronizationSettings(ctx context.Context, in *GetSynchronizationSettingsRequest, opts ...grpc.CallOption) (*SynchronizationSettings, error)
	// Lists supported attributes for synchronization.
	ListSupportedAttributes(ctx context.Context, in *ListSupportedAttributesRequest, opts ...grpc.CallOption) (*ListSupportedAttributesResponse, error)
}

type synchronizationServiceClient struct {
	cc grpc.ClientConnInterface
}

func NewSynchronizationServiceClient(cc grpc.ClientConnInterface) SynchronizationServiceClient {
	return &synchronizationServiceClient{cc}
}

func (c *synchronizationServiceClient) SetReplicationToken(ctx context.Context, in *SetReplicationTokenRequest, opts ...grpc.CallOption) (*operation.Operation, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(operation.Operation)
	err := c.cc.Invoke(ctx, SynchronizationService_SetReplicationToken_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *synchronizationServiceClient) ResetReplicationToken(ctx context.Context, in *ResetReplicationTokenRequest, opts ...grpc.CallOption) (*operation.Operation, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(operation.Operation)
	err := c.cc.Invoke(ctx, SynchronizationService_ResetReplicationToken_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *synchronizationServiceClient) CreateSynchronizationSettings(ctx context.Context, in *CreateSynchronizationSettingsRequest, opts ...grpc.CallOption) (*operation.Operation, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(operation.Operation)
	err := c.cc.Invoke(ctx, SynchronizationService_CreateSynchronizationSettings_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *synchronizationServiceClient) UpdateSynchronizationSettings(ctx context.Context, in *UpdateSynchronizationSettingsRequest, opts ...grpc.CallOption) (*operation.Operation, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(operation.Operation)
	err := c.cc.Invoke(ctx, SynchronizationService_UpdateSynchronizationSettings_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *synchronizationServiceClient) DeleteSynchronizationSettings(ctx context.Context, in *DeleteSynchronizationSettingsRequest, opts ...grpc.CallOption) (*operation.Operation, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(operation.Operation)
	err := c.cc.Invoke(ctx, SynchronizationService_DeleteSynchronizationSettings_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *synchronizationServiceClient) GetSynchronizationSettings(ctx context.Context, in *GetSynchronizationSettingsRequest, opts ...grpc.CallOption) (*SynchronizationSettings, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(SynchronizationSettings)
	err := c.cc.Invoke(ctx, SynchronizationService_GetSynchronizationSettings_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *synchronizationServiceClient) ListSupportedAttributes(ctx context.Context, in *ListSupportedAttributesRequest, opts ...grpc.CallOption) (*ListSupportedAttributesResponse, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(ListSupportedAttributesResponse)
	err := c.cc.Invoke(ctx, SynchronizationService_ListSupportedAttributes_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// SynchronizationServiceServer is the server API for SynchronizationService service.
// All implementations should embed UnimplementedSynchronizationServiceServer
// for forward compatibility.
//
// A set of methods for managing synchronization settings.
type SynchronizationServiceServer interface {
	// Sets the replication token for synchronization.
	SetReplicationToken(context.Context, *SetReplicationTokenRequest) (*operation.Operation, error)
	// Resets the replication token for synchronization.
	ResetReplicationToken(context.Context, *ResetReplicationTokenRequest) (*operation.Operation, error)
	// Creates synchronization settings for a subject container.
	CreateSynchronizationSettings(context.Context, *CreateSynchronizationSettingsRequest) (*operation.Operation, error)
	// Updates synchronization settings for a subject container.
	UpdateSynchronizationSettings(context.Context, *UpdateSynchronizationSettingsRequest) (*operation.Operation, error)
	// Deletes synchronization settings for a subject container.
	DeleteSynchronizationSettings(context.Context, *DeleteSynchronizationSettingsRequest) (*operation.Operation, error)
	// Returns synchronization settings for a subject container.
	GetSynchronizationSettings(context.Context, *GetSynchronizationSettingsRequest) (*SynchronizationSettings, error)
	// Lists supported attributes for synchronization.
	ListSupportedAttributes(context.Context, *ListSupportedAttributesRequest) (*ListSupportedAttributesResponse, error)
}

// UnimplementedSynchronizationServiceServer 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 UnimplementedSynchronizationServiceServer struct{}

func (UnimplementedSynchronizationServiceServer) SetReplicationToken(context.Context, *SetReplicationTokenRequest) (*operation.Operation, error) {
	return nil, status.Errorf(codes.Unimplemented, "method SetReplicationToken not implemented")
}
func (UnimplementedSynchronizationServiceServer) ResetReplicationToken(context.Context, *ResetReplicationTokenRequest) (*operation.Operation, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ResetReplicationToken not implemented")
}
func (UnimplementedSynchronizationServiceServer) CreateSynchronizationSettings(context.Context, *CreateSynchronizationSettingsRequest) (*operation.Operation, error) {
	return nil, status.Errorf(codes.Unimplemented, "method CreateSynchronizationSettings not implemented")
}
func (UnimplementedSynchronizationServiceServer) UpdateSynchronizationSettings(context.Context, *UpdateSynchronizationSettingsRequest) (*operation.Operation, error) {
	return nil, status.Errorf(codes.Unimplemented, "method UpdateSynchronizationSettings not implemented")
}
func (UnimplementedSynchronizationServiceServer) DeleteSynchronizationSettings(context.Context, *DeleteSynchronizationSettingsRequest) (*operation.Operation, error) {
	return nil, status.Errorf(codes.Unimplemented, "method DeleteSynchronizationSettings not implemented")
}
func (UnimplementedSynchronizationServiceServer) GetSynchronizationSettings(context.Context, *GetSynchronizationSettingsRequest) (*SynchronizationSettings, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetSynchronizationSettings not implemented")
}
func (UnimplementedSynchronizationServiceServer) ListSupportedAttributes(context.Context, *ListSupportedAttributesRequest) (*ListSupportedAttributesResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ListSupportedAttributes not implemented")
}
func (UnimplementedSynchronizationServiceServer) testEmbeddedByValue() {}

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

func RegisterSynchronizationServiceServer(s grpc.ServiceRegistrar, srv SynchronizationServiceServer) {
	// If the following call pancis, it indicates UnimplementedSynchronizationServiceServer 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(&SynchronizationService_ServiceDesc, srv)
}

func _SynchronizationService_SetReplicationToken_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(SetReplicationTokenRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SynchronizationServiceServer).SetReplicationToken(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: SynchronizationService_SetReplicationToken_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SynchronizationServiceServer).SetReplicationToken(ctx, req.(*SetReplicationTokenRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _SynchronizationService_ResetReplicationToken_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ResetReplicationTokenRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SynchronizationServiceServer).ResetReplicationToken(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: SynchronizationService_ResetReplicationToken_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SynchronizationServiceServer).ResetReplicationToken(ctx, req.(*ResetReplicationTokenRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _SynchronizationService_CreateSynchronizationSettings_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(CreateSynchronizationSettingsRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SynchronizationServiceServer).CreateSynchronizationSettings(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: SynchronizationService_CreateSynchronizationSettings_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SynchronizationServiceServer).CreateSynchronizationSettings(ctx, req.(*CreateSynchronizationSettingsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _SynchronizationService_UpdateSynchronizationSettings_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(UpdateSynchronizationSettingsRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SynchronizationServiceServer).UpdateSynchronizationSettings(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: SynchronizationService_UpdateSynchronizationSettings_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SynchronizationServiceServer).UpdateSynchronizationSettings(ctx, req.(*UpdateSynchronizationSettingsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _SynchronizationService_DeleteSynchronizationSettings_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(DeleteSynchronizationSettingsRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SynchronizationServiceServer).DeleteSynchronizationSettings(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: SynchronizationService_DeleteSynchronizationSettings_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SynchronizationServiceServer).DeleteSynchronizationSettings(ctx, req.(*DeleteSynchronizationSettingsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _SynchronizationService_GetSynchronizationSettings_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GetSynchronizationSettingsRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SynchronizationServiceServer).GetSynchronizationSettings(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: SynchronizationService_GetSynchronizationSettings_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SynchronizationServiceServer).GetSynchronizationSettings(ctx, req.(*GetSynchronizationSettingsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _SynchronizationService_ListSupportedAttributes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ListSupportedAttributesRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SynchronizationServiceServer).ListSupportedAttributes(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: SynchronizationService_ListSupportedAttributes_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SynchronizationServiceServer).ListSupportedAttributes(ctx, req.(*ListSupportedAttributesRequest))
	}
	return interceptor(ctx, in, info, handler)
}

// SynchronizationService_ServiceDesc is the grpc.ServiceDesc for SynchronizationService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var SynchronizationService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "yandex.cloud.organizationmanager.v1.idp.SynchronizationService",
	HandlerType: (*SynchronizationServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "SetReplicationToken",
			Handler:    _SynchronizationService_SetReplicationToken_Handler,
		},
		{
			MethodName: "ResetReplicationToken",
			Handler:    _SynchronizationService_ResetReplicationToken_Handler,
		},
		{
			MethodName: "CreateSynchronizationSettings",
			Handler:    _SynchronizationService_CreateSynchronizationSettings_Handler,
		},
		{
			MethodName: "UpdateSynchronizationSettings",
			Handler:    _SynchronizationService_UpdateSynchronizationSettings_Handler,
		},
		{
			MethodName: "DeleteSynchronizationSettings",
			Handler:    _SynchronizationService_DeleteSynchronizationSettings_Handler,
		},
		{
			MethodName: "GetSynchronizationSettings",
			Handler:    _SynchronizationService_GetSynchronizationSettings_Handler,
		},
		{
			MethodName: "ListSupportedAttributes",
			Handler:    _SynchronizationService_ListSupportedAttributes_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "yandex/cloud/organizationmanager/v1/idp/synchronization_service.proto",
}
