2021-12-05 10:53:33 +00:00
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
package media_set
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.32.0 or later.
const _ = grpc . SupportPackageIsVersion7
// MediaSetServiceClient is the client API for MediaSetService 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.
type MediaSetServiceClient interface {
Get ( ctx context . Context , in * GetRequest , opts ... grpc . CallOption ) ( * MediaSet , error )
2021-12-17 16:30:53 +00:00
GetPeaks ( ctx context . Context , in * GetPeaksRequest , opts ... grpc . CallOption ) ( MediaSetService_GetPeaksClient , error )
GetPeaksForSegment ( ctx context . Context , in * GetPeaksForSegmentRequest , opts ... grpc . CallOption ) ( * GetPeaksForSegmentResponse , error )
2021-12-29 15:38:25 +00:00
GetAudioSegment ( ctx context . Context , in * GetAudioSegmentRequest , opts ... grpc . CallOption ) ( MediaSetService_GetAudioSegmentClient , error )
2021-12-05 10:53:33 +00:00
GetVideo ( ctx context . Context , in * GetVideoRequest , opts ... grpc . CallOption ) ( MediaSetService_GetVideoClient , error )
GetVideoThumbnail ( ctx context . Context , in * GetVideoThumbnailRequest , opts ... grpc . CallOption ) ( * GetVideoThumbnailResponse , error )
}
type mediaSetServiceClient struct {
cc grpc . ClientConnInterface
}
func NewMediaSetServiceClient ( cc grpc . ClientConnInterface ) MediaSetServiceClient {
return & mediaSetServiceClient { cc }
}
func ( c * mediaSetServiceClient ) Get ( ctx context . Context , in * GetRequest , opts ... grpc . CallOption ) ( * MediaSet , error ) {
out := new ( MediaSet )
err := c . cc . Invoke ( ctx , "/media_set.MediaSetService/Get" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
2021-12-17 16:30:53 +00:00
func ( c * mediaSetServiceClient ) GetPeaks ( ctx context . Context , in * GetPeaksRequest , opts ... grpc . CallOption ) ( MediaSetService_GetPeaksClient , error ) {
stream , err := c . cc . NewStream ( ctx , & MediaSetService_ServiceDesc . Streams [ 0 ] , "/media_set.MediaSetService/GetPeaks" , opts ... )
2021-12-05 10:53:33 +00:00
if err != nil {
return nil , err
}
2021-12-17 16:30:53 +00:00
x := & mediaSetServiceGetPeaksClient { stream }
2021-12-05 10:53:33 +00:00
if err := x . ClientStream . SendMsg ( in ) ; err != nil {
return nil , err
}
if err := x . ClientStream . CloseSend ( ) ; err != nil {
return nil , err
}
return x , nil
}
2021-12-17 16:30:53 +00:00
type MediaSetService_GetPeaksClient interface {
Recv ( ) ( * GetPeaksProgress , error )
2021-12-05 10:53:33 +00:00
grpc . ClientStream
}
2021-12-17 16:30:53 +00:00
type mediaSetServiceGetPeaksClient struct {
2021-12-05 10:53:33 +00:00
grpc . ClientStream
}
2021-12-17 16:30:53 +00:00
func ( x * mediaSetServiceGetPeaksClient ) Recv ( ) ( * GetPeaksProgress , error ) {
m := new ( GetPeaksProgress )
2021-12-05 10:53:33 +00:00
if err := x . ClientStream . RecvMsg ( m ) ; err != nil {
return nil , err
}
return m , nil
}
2021-12-17 16:30:53 +00:00
func ( c * mediaSetServiceClient ) GetPeaksForSegment ( ctx context . Context , in * GetPeaksForSegmentRequest , opts ... grpc . CallOption ) ( * GetPeaksForSegmentResponse , error ) {
out := new ( GetPeaksForSegmentResponse )
err := c . cc . Invoke ( ctx , "/media_set.MediaSetService/GetPeaksForSegment" , in , out , opts ... )
2021-12-05 10:53:33 +00:00
if err != nil {
return nil , err
}
return out , nil
}
2021-12-29 15:38:25 +00:00
func ( c * mediaSetServiceClient ) GetAudioSegment ( ctx context . Context , in * GetAudioSegmentRequest , opts ... grpc . CallOption ) ( MediaSetService_GetAudioSegmentClient , error ) {
stream , err := c . cc . NewStream ( ctx , & MediaSetService_ServiceDesc . Streams [ 1 ] , "/media_set.MediaSetService/GetAudioSegment" , opts ... )
if err != nil {
return nil , err
}
x := & mediaSetServiceGetAudioSegmentClient { stream }
if err := x . ClientStream . SendMsg ( in ) ; err != nil {
return nil , err
}
if err := x . ClientStream . CloseSend ( ) ; err != nil {
return nil , err
}
return x , nil
}
type MediaSetService_GetAudioSegmentClient interface {
Recv ( ) ( * GetAudioSegmentProgress , error )
grpc . ClientStream
}
type mediaSetServiceGetAudioSegmentClient struct {
grpc . ClientStream
}
func ( x * mediaSetServiceGetAudioSegmentClient ) Recv ( ) ( * GetAudioSegmentProgress , error ) {
m := new ( GetAudioSegmentProgress )
if err := x . ClientStream . RecvMsg ( m ) ; err != nil {
return nil , err
}
return m , nil
}
2021-12-05 10:53:33 +00:00
func ( c * mediaSetServiceClient ) GetVideo ( ctx context . Context , in * GetVideoRequest , opts ... grpc . CallOption ) ( MediaSetService_GetVideoClient , error ) {
2021-12-29 15:38:25 +00:00
stream , err := c . cc . NewStream ( ctx , & MediaSetService_ServiceDesc . Streams [ 2 ] , "/media_set.MediaSetService/GetVideo" , opts ... )
2021-12-05 10:53:33 +00:00
if err != nil {
return nil , err
}
x := & mediaSetServiceGetVideoClient { stream }
if err := x . ClientStream . SendMsg ( in ) ; err != nil {
return nil , err
}
if err := x . ClientStream . CloseSend ( ) ; err != nil {
return nil , err
}
return x , nil
}
type MediaSetService_GetVideoClient interface {
Recv ( ) ( * GetVideoProgress , error )
grpc . ClientStream
}
type mediaSetServiceGetVideoClient struct {
grpc . ClientStream
}
func ( x * mediaSetServiceGetVideoClient ) Recv ( ) ( * GetVideoProgress , error ) {
m := new ( GetVideoProgress )
if err := x . ClientStream . RecvMsg ( m ) ; err != nil {
return nil , err
}
return m , nil
}
func ( c * mediaSetServiceClient ) GetVideoThumbnail ( ctx context . Context , in * GetVideoThumbnailRequest , opts ... grpc . CallOption ) ( * GetVideoThumbnailResponse , error ) {
out := new ( GetVideoThumbnailResponse )
err := c . cc . Invoke ( ctx , "/media_set.MediaSetService/GetVideoThumbnail" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
// MediaSetServiceServer is the server API for MediaSetService service.
// All implementations must embed UnimplementedMediaSetServiceServer
// for forward compatibility
type MediaSetServiceServer interface {
Get ( context . Context , * GetRequest ) ( * MediaSet , error )
2021-12-17 16:30:53 +00:00
GetPeaks ( * GetPeaksRequest , MediaSetService_GetPeaksServer ) error
GetPeaksForSegment ( context . Context , * GetPeaksForSegmentRequest ) ( * GetPeaksForSegmentResponse , error )
2021-12-29 15:38:25 +00:00
GetAudioSegment ( * GetAudioSegmentRequest , MediaSetService_GetAudioSegmentServer ) error
2021-12-05 10:53:33 +00:00
GetVideo ( * GetVideoRequest , MediaSetService_GetVideoServer ) error
GetVideoThumbnail ( context . Context , * GetVideoThumbnailRequest ) ( * GetVideoThumbnailResponse , error )
mustEmbedUnimplementedMediaSetServiceServer ( )
}
// UnimplementedMediaSetServiceServer must be embedded to have forward compatible implementations.
type UnimplementedMediaSetServiceServer struct {
}
func ( UnimplementedMediaSetServiceServer ) Get ( context . Context , * GetRequest ) ( * MediaSet , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method Get not implemented" )
}
2021-12-17 16:30:53 +00:00
func ( UnimplementedMediaSetServiceServer ) GetPeaks ( * GetPeaksRequest , MediaSetService_GetPeaksServer ) error {
return status . Errorf ( codes . Unimplemented , "method GetPeaks not implemented" )
2021-12-05 10:53:33 +00:00
}
2021-12-17 16:30:53 +00:00
func ( UnimplementedMediaSetServiceServer ) GetPeaksForSegment ( context . Context , * GetPeaksForSegmentRequest ) ( * GetPeaksForSegmentResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method GetPeaksForSegment not implemented" )
2021-12-05 10:53:33 +00:00
}
2021-12-29 15:38:25 +00:00
func ( UnimplementedMediaSetServiceServer ) GetAudioSegment ( * GetAudioSegmentRequest , MediaSetService_GetAudioSegmentServer ) error {
return status . Errorf ( codes . Unimplemented , "method GetAudioSegment not implemented" )
}
2021-12-05 10:53:33 +00:00
func ( UnimplementedMediaSetServiceServer ) GetVideo ( * GetVideoRequest , MediaSetService_GetVideoServer ) error {
return status . Errorf ( codes . Unimplemented , "method GetVideo not implemented" )
}
func ( UnimplementedMediaSetServiceServer ) GetVideoThumbnail ( context . Context , * GetVideoThumbnailRequest ) ( * GetVideoThumbnailResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method GetVideoThumbnail not implemented" )
}
func ( UnimplementedMediaSetServiceServer ) mustEmbedUnimplementedMediaSetServiceServer ( ) { }
// UnsafeMediaSetServiceServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to MediaSetServiceServer will
// result in compilation errors.
type UnsafeMediaSetServiceServer interface {
mustEmbedUnimplementedMediaSetServiceServer ( )
}
func RegisterMediaSetServiceServer ( s grpc . ServiceRegistrar , srv MediaSetServiceServer ) {
s . RegisterService ( & MediaSetService_ServiceDesc , srv )
}
func _MediaSetService_Get_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( GetRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( MediaSetServiceServer ) . Get ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/media_set.MediaSetService/Get" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( MediaSetServiceServer ) . Get ( ctx , req . ( * GetRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
2021-12-17 16:30:53 +00:00
func _MediaSetService_GetPeaks_Handler ( srv interface { } , stream grpc . ServerStream ) error {
m := new ( GetPeaksRequest )
2021-12-05 10:53:33 +00:00
if err := stream . RecvMsg ( m ) ; err != nil {
return err
}
2021-12-17 16:30:53 +00:00
return srv . ( MediaSetServiceServer ) . GetPeaks ( m , & mediaSetServiceGetPeaksServer { stream } )
2021-12-05 10:53:33 +00:00
}
2021-12-17 16:30:53 +00:00
type MediaSetService_GetPeaksServer interface {
Send ( * GetPeaksProgress ) error
2021-12-05 10:53:33 +00:00
grpc . ServerStream
}
2021-12-17 16:30:53 +00:00
type mediaSetServiceGetPeaksServer struct {
2021-12-05 10:53:33 +00:00
grpc . ServerStream
}
2021-12-17 16:30:53 +00:00
func ( x * mediaSetServiceGetPeaksServer ) Send ( m * GetPeaksProgress ) error {
2021-12-05 10:53:33 +00:00
return x . ServerStream . SendMsg ( m )
}
2021-12-17 16:30:53 +00:00
func _MediaSetService_GetPeaksForSegment_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( GetPeaksForSegmentRequest )
2021-12-05 10:53:33 +00:00
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
2021-12-17 16:30:53 +00:00
return srv . ( MediaSetServiceServer ) . GetPeaksForSegment ( ctx , in )
2021-12-05 10:53:33 +00:00
}
info := & grpc . UnaryServerInfo {
Server : srv ,
2021-12-17 16:30:53 +00:00
FullMethod : "/media_set.MediaSetService/GetPeaksForSegment" ,
2021-12-05 10:53:33 +00:00
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
2021-12-17 16:30:53 +00:00
return srv . ( MediaSetServiceServer ) . GetPeaksForSegment ( ctx , req . ( * GetPeaksForSegmentRequest ) )
2021-12-05 10:53:33 +00:00
}
return interceptor ( ctx , in , info , handler )
}
2021-12-29 15:38:25 +00:00
func _MediaSetService_GetAudioSegment_Handler ( srv interface { } , stream grpc . ServerStream ) error {
m := new ( GetAudioSegmentRequest )
if err := stream . RecvMsg ( m ) ; err != nil {
return err
}
return srv . ( MediaSetServiceServer ) . GetAudioSegment ( m , & mediaSetServiceGetAudioSegmentServer { stream } )
}
type MediaSetService_GetAudioSegmentServer interface {
Send ( * GetAudioSegmentProgress ) error
grpc . ServerStream
}
type mediaSetServiceGetAudioSegmentServer struct {
grpc . ServerStream
}
func ( x * mediaSetServiceGetAudioSegmentServer ) Send ( m * GetAudioSegmentProgress ) error {
return x . ServerStream . SendMsg ( m )
}
2021-12-05 10:53:33 +00:00
func _MediaSetService_GetVideo_Handler ( srv interface { } , stream grpc . ServerStream ) error {
m := new ( GetVideoRequest )
if err := stream . RecvMsg ( m ) ; err != nil {
return err
}
return srv . ( MediaSetServiceServer ) . GetVideo ( m , & mediaSetServiceGetVideoServer { stream } )
}
type MediaSetService_GetVideoServer interface {
Send ( * GetVideoProgress ) error
grpc . ServerStream
}
type mediaSetServiceGetVideoServer struct {
grpc . ServerStream
}
func ( x * mediaSetServiceGetVideoServer ) Send ( m * GetVideoProgress ) error {
return x . ServerStream . SendMsg ( m )
}
func _MediaSetService_GetVideoThumbnail_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( GetVideoThumbnailRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( MediaSetServiceServer ) . GetVideoThumbnail ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/media_set.MediaSetService/GetVideoThumbnail" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( MediaSetServiceServer ) . GetVideoThumbnail ( ctx , req . ( * GetVideoThumbnailRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
// MediaSetService_ServiceDesc is the grpc.ServiceDesc for MediaSetService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var MediaSetService_ServiceDesc = grpc . ServiceDesc {
ServiceName : "media_set.MediaSetService" ,
HandlerType : ( * MediaSetServiceServer ) ( nil ) ,
Methods : [ ] grpc . MethodDesc {
{
MethodName : "Get" ,
Handler : _MediaSetService_Get_Handler ,
} ,
{
2021-12-17 16:30:53 +00:00
MethodName : "GetPeaksForSegment" ,
Handler : _MediaSetService_GetPeaksForSegment_Handler ,
2021-12-05 10:53:33 +00:00
} ,
{
MethodName : "GetVideoThumbnail" ,
Handler : _MediaSetService_GetVideoThumbnail_Handler ,
} ,
} ,
Streams : [ ] grpc . StreamDesc {
{
2021-12-17 16:30:53 +00:00
StreamName : "GetPeaks" ,
Handler : _MediaSetService_GetPeaks_Handler ,
2021-12-05 10:53:33 +00:00
ServerStreams : true ,
} ,
2021-12-29 15:38:25 +00:00
{
StreamName : "GetAudioSegment" ,
Handler : _MediaSetService_GetAudioSegment_Handler ,
ServerStreams : true ,
} ,
2021-12-05 10:53:33 +00:00
{
StreamName : "GetVideo" ,
Handler : _MediaSetService_GetVideo_Handler ,
ServerStreams : true ,
} ,
} ,
Metadata : "media_set.proto" ,
}