99 lines
		
	
	
		
			4.6 KiB
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			99 lines
		
	
	
		
			4.6 KiB
		
	
	
	
		
			Go
		
	
	
	
	
	
| // Code generated by goctl. DO NOT EDIT.
 | |
| // goctl 1.7.2
 | |
| // Source: sentinel.proto
 | |
| 
 | |
| package whitelist
 | |
| 
 | |
| import (
 | |
| 	"context"
 | |
| 
 | |
| 	"tianyuan-api/apps/sentinel/sentinel"
 | |
| 
 | |
| 	"github.com/zeromicro/go-zero/zrpc"
 | |
| 	"google.golang.org/grpc"
 | |
| )
 | |
| 
 | |
| type (
 | |
| 	AliTopUpNotifyRequest            = sentinel.AliTopUpNotifyRequest
 | |
| 	AliTopUpNotifyResponse           = sentinel.AliTopUpNotifyResponse
 | |
| 	AliTopUpRequest                  = sentinel.AliTopUpRequest
 | |
| 	AliTopUpResponse                 = sentinel.AliTopUpResponse
 | |
| 	CreateProductRequest             = sentinel.CreateProductRequest
 | |
| 	CreateSecretRequest              = sentinel.CreateSecretRequest
 | |
| 	CreateUserProductRequest         = sentinel.CreateUserProductRequest
 | |
| 	CreateWhitelistRequest           = sentinel.CreateWhitelistRequest
 | |
| 	DeleteProductRequest             = sentinel.DeleteProductRequest
 | |
| 	DeleteSecretRequest              = sentinel.DeleteSecretRequest
 | |
| 	DeleteUserProductRequest         = sentinel.DeleteUserProductRequest
 | |
| 	DeleteWhitelistRequest           = sentinel.DeleteWhitelistRequest
 | |
| 	GetRecordByCodeRequest           = sentinel.GetRecordByCodeRequest
 | |
| 	GetRecordByIdRequest             = sentinel.GetRecordByIdRequest
 | |
| 	GetSecretBySecretIdRequest       = sentinel.GetSecretBySecretIdRequest
 | |
| 	MatchResponse                    = sentinel.MatchResponse
 | |
| 	MatchWhitelistByIpRequest        = sentinel.MatchWhitelistByIpRequest
 | |
| 	MatchingUserIdProductCodeRequest = sentinel.MatchingUserIdProductCodeRequest
 | |
| 	PageListRequest                  = sentinel.PageListRequest
 | |
| 	Product                          = sentinel.Product
 | |
| 	ProductResponse                  = sentinel.ProductResponse
 | |
| 	Secret                           = sentinel.Secret
 | |
| 	SecretResponse                   = sentinel.SecretResponse
 | |
| 	UpdateProductRequest             = sentinel.UpdateProductRequest
 | |
| 	UpdateSecretRequest              = sentinel.UpdateSecretRequest
 | |
| 	UpdateUserProductRequest         = sentinel.UpdateUserProductRequest
 | |
| 	UpdateWhitelistRequest           = sentinel.UpdateWhitelistRequest
 | |
| 	UserProductEmptyResponse         = sentinel.UserProductEmptyResponse
 | |
| 	UserProductItem                  = sentinel.UserProductItem
 | |
| 	UserProductPageListResponse      = sentinel.UserProductPageListResponse
 | |
| 	UserProductResponse              = sentinel.UserProductResponse
 | |
| 	UserProuctPageListRequest        = sentinel.UserProuctPageListRequest
 | |
| 	UserProuctRequest                = sentinel.UserProuctRequest
 | |
| 	WhitePageListRequest             = sentinel.WhitePageListRequest
 | |
| 	Whitelist                        = sentinel.Whitelist
 | |
| 	WhitelistResponse                = sentinel.WhitelistResponse
 | |
| 
 | |
| 	WhitelistZrpcClient interface {
 | |
| 		// Whitelist methods
 | |
| 		CreateWhitelist(ctx context.Context, in *CreateWhitelistRequest, opts ...grpc.CallOption) (*Whitelist, error)
 | |
| 		UpdateWhitelist(ctx context.Context, in *UpdateWhitelistRequest, opts ...grpc.CallOption) (*Whitelist, error)
 | |
| 		DeleteWhitelist(ctx context.Context, in *DeleteWhitelistRequest, opts ...grpc.CallOption) (*Whitelist, error)
 | |
| 		GetWhitePageList(ctx context.Context, in *WhitePageListRequest, opts ...grpc.CallOption) (*WhitelistResponse, error)
 | |
| 		MatchWhitelistByIp(ctx context.Context, in *MatchWhitelistByIpRequest, opts ...grpc.CallOption) (*MatchResponse, error)
 | |
| 	}
 | |
| 
 | |
| 	defaultWhitelistZrpcClient struct {
 | |
| 		cli zrpc.Client
 | |
| 	}
 | |
| )
 | |
| 
 | |
| func NewWhitelistZrpcClient(cli zrpc.Client) WhitelistZrpcClient {
 | |
| 	return &defaultWhitelistZrpcClient{
 | |
| 		cli: cli,
 | |
| 	}
 | |
| }
 | |
| 
 | |
| // Whitelist methods
 | |
| func (m *defaultWhitelistZrpcClient) CreateWhitelist(ctx context.Context, in *CreateWhitelistRequest, opts ...grpc.CallOption) (*Whitelist, error) {
 | |
| 	client := sentinel.NewWhitelistClient(m.cli.Conn())
 | |
| 	return client.CreateWhitelist(ctx, in, opts...)
 | |
| }
 | |
| 
 | |
| func (m *defaultWhitelistZrpcClient) UpdateWhitelist(ctx context.Context, in *UpdateWhitelistRequest, opts ...grpc.CallOption) (*Whitelist, error) {
 | |
| 	client := sentinel.NewWhitelistClient(m.cli.Conn())
 | |
| 	return client.UpdateWhitelist(ctx, in, opts...)
 | |
| }
 | |
| 
 | |
| func (m *defaultWhitelistZrpcClient) DeleteWhitelist(ctx context.Context, in *DeleteWhitelistRequest, opts ...grpc.CallOption) (*Whitelist, error) {
 | |
| 	client := sentinel.NewWhitelistClient(m.cli.Conn())
 | |
| 	return client.DeleteWhitelist(ctx, in, opts...)
 | |
| }
 | |
| 
 | |
| func (m *defaultWhitelistZrpcClient) GetWhitePageList(ctx context.Context, in *WhitePageListRequest, opts ...grpc.CallOption) (*WhitelistResponse, error) {
 | |
| 	client := sentinel.NewWhitelistClient(m.cli.Conn())
 | |
| 	return client.GetWhitePageList(ctx, in, opts...)
 | |
| }
 | |
| 
 | |
| func (m *defaultWhitelistZrpcClient) MatchWhitelistByIp(ctx context.Context, in *MatchWhitelistByIpRequest, opts ...grpc.CallOption) (*MatchResponse, error) {
 | |
| 	client := sentinel.NewWhitelistClient(m.cli.Conn())
 | |
| 	return client.MatchWhitelistByIp(ctx, in, opts...)
 | |
| }
 |