Documentation
¶
Index ¶
- Variables
- func RegisterTestProxyServer(s grpc.ServiceRegistrar, srv TestProxyServer)
- type PingMethod
- type SortMethod
- type SpeedTestMode
- func (SpeedTestMode) Descriptor() protoreflect.EnumDescriptor
- func (x SpeedTestMode) Enum() *SpeedTestMode
- func (SpeedTestMode) EnumDescriptor() ([]byte, []int)deprecated
- func (x SpeedTestMode) Number() protoreflect.EnumNumber
- func (x SpeedTestMode) String() string
- func (SpeedTestMode) Type() protoreflect.EnumType
- type TestProxyClient
- type TestProxyServer
- type TestProxy_StartTestClient
- type TestProxy_StartTestServer
- type TestReply
- func (*TestReply) Descriptor() ([]byte, []int)deprecated
- func (x *TestReply) GetAvgSpeed() int64
- func (x *TestReply) GetGroupName() string
- func (x *TestReply) GetId() int32
- func (x *TestReply) GetIsOk() bool
- func (x *TestReply) GetLink() string
- func (x *TestReply) GetMaxSpeed() int64
- func (x *TestReply) GetPing() string
- func (x *TestReply) GetProtocol() string
- func (x *TestReply) GetRemarks() string
- func (x *TestReply) GetTraffic() int64
- func (*TestReply) ProtoMessage()
- func (x *TestReply) ProtoReflect() protoreflect.Message
- func (x *TestReply) Reset()
- func (x *TestReply) String() string
- type TestRequest
- func (*TestRequest) Descriptor() ([]byte, []int)deprecated
- func (x *TestRequest) GetConcurrency() int32
- func (x *TestRequest) GetFontSize() uint32
- func (x *TestRequest) GetGroupName() string
- func (x *TestRequest) GetLanguage() string
- func (x *TestRequest) GetOutputMode() uint32
- func (x *TestRequest) GetPingMethod() PingMethod
- func (x *TestRequest) GetSortMethod() SortMethod
- func (x *TestRequest) GetSpeedTestMode() SpeedTestMode
- func (x *TestRequest) GetSubscription() string
- func (x *TestRequest) GetTestMode() uint32
- func (x *TestRequest) GetTheme() string
- func (x *TestRequest) GetTimeout() int64
- func (*TestRequest) ProtoMessage()
- func (x *TestRequest) ProtoReflect() protoreflect.Message
- func (x *TestRequest) Reset()
- func (x *TestRequest) String() string
- type UnimplementedTestProxyServer
- type UnsafeTestProxyServer
Constants ¶
This section is empty.
Variables ¶
var ( SpeedTestMode_name = map[int32]string{ 0: "pingonly", 1: "speedonly", 2: "all", } SpeedTestMode_value = map[string]int32{ "pingonly": 0, "speedonly": 1, "all": 2, } )
Enum value maps for SpeedTestMode.
var ( PingMethod_name = map[int32]string{ 0: "googleping", 1: "tcpping", } PingMethod_value = map[string]int32{ "googleping": 0, "tcpping": 1, } )
Enum value maps for PingMethod.
var ( SortMethod_name = map[int32]string{ 0: "speed", 1: "rspeed", 2: "ping", 3: "rping", } SortMethod_value = map[string]int32{ "speed": 0, "rspeed": 1, "ping": 2, "rping": 3, } )
Enum value maps for SortMethod.
var File_lite_proto protoreflect.FileDescriptor
var TestProxy_ServiceDesc = grpc.ServiceDesc{ ServiceName: "liteproxy.TestProxy", HandlerType: (*TestProxyServer)(nil), Methods: []grpc.MethodDesc{}, Streams: []grpc.StreamDesc{ { StreamName: "StartTest", Handler: _TestProxy_StartTest_Handler, ServerStreams: true, }, }, Metadata: "lite.proto", }
TestProxy_ServiceDesc is the grpc.ServiceDesc for TestProxy service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterTestProxyServer ¶
func RegisterTestProxyServer(s grpc.ServiceRegistrar, srv TestProxyServer)
Types ¶
type PingMethod ¶
type PingMethod int32
const ( PingMethod_googleping PingMethod = 0 PingMethod_tcpping PingMethod = 1 )
func (PingMethod) Descriptor ¶
func (PingMethod) Descriptor() protoreflect.EnumDescriptor
func (PingMethod) Enum ¶
func (x PingMethod) Enum() *PingMethod
func (PingMethod) EnumDescriptor
deprecated
func (PingMethod) EnumDescriptor() ([]byte, []int)
Deprecated: Use PingMethod.Descriptor instead.
func (PingMethod) Number ¶
func (x PingMethod) Number() protoreflect.EnumNumber
func (PingMethod) String ¶
func (x PingMethod) String() string
func (PingMethod) Type ¶
func (PingMethod) Type() protoreflect.EnumType
type SortMethod ¶
type SortMethod int32
const ( SortMethod_speed SortMethod = 0 SortMethod_rspeed SortMethod = 1 // reverse speed SortMethod_ping SortMethod = 2 SortMethod_rping SortMethod = 3 // reverse ping )
func (SortMethod) Descriptor ¶
func (SortMethod) Descriptor() protoreflect.EnumDescriptor
func (SortMethod) Enum ¶
func (x SortMethod) Enum() *SortMethod
func (SortMethod) EnumDescriptor
deprecated
func (SortMethod) EnumDescriptor() ([]byte, []int)
Deprecated: Use SortMethod.Descriptor instead.
func (SortMethod) Number ¶
func (x SortMethod) Number() protoreflect.EnumNumber
func (SortMethod) String ¶
func (x SortMethod) String() string
func (SortMethod) Type ¶
func (SortMethod) Type() protoreflect.EnumType
type SpeedTestMode ¶
type SpeedTestMode int32
const ( SpeedTestMode_pingonly SpeedTestMode = 0 SpeedTestMode_speedonly SpeedTestMode = 1 SpeedTestMode_all SpeedTestMode = 2 )
func (SpeedTestMode) Descriptor ¶
func (SpeedTestMode) Descriptor() protoreflect.EnumDescriptor
func (SpeedTestMode) Enum ¶
func (x SpeedTestMode) Enum() *SpeedTestMode
func (SpeedTestMode) EnumDescriptor
deprecated
func (SpeedTestMode) EnumDescriptor() ([]byte, []int)
Deprecated: Use SpeedTestMode.Descriptor instead.
func (SpeedTestMode) Number ¶
func (x SpeedTestMode) Number() protoreflect.EnumNumber
func (SpeedTestMode) String ¶
func (x SpeedTestMode) String() string
func (SpeedTestMode) Type ¶
func (SpeedTestMode) Type() protoreflect.EnumType
type TestProxyClient ¶
type TestProxyClient interface {
StartTest(ctx context.Context, in *TestRequest, opts ...grpc.CallOption) (TestProxy_StartTestClient, error)
}
TestProxyClient is the client API for TestProxy 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.
func NewTestProxyClient ¶
func NewTestProxyClient(cc grpc.ClientConnInterface) TestProxyClient
type TestProxyServer ¶
type TestProxyServer interface { StartTest(*TestRequest, TestProxy_StartTestServer) error // contains filtered or unexported methods }
TestProxyServer is the server API for TestProxy service. All implementations must embed UnimplementedTestProxyServer for forward compatibility
type TestProxy_StartTestClient ¶
type TestProxy_StartTestClient interface { Recv() (*TestReply, error) grpc.ClientStream }
type TestProxy_StartTestServer ¶
type TestProxy_StartTestServer interface { Send(*TestReply) error grpc.ServerStream }
type TestReply ¶
type TestReply struct { Id int32 `protobuf:"varint,1,opt,name=Id,proto3" json:"Id,omitempty"` GroupName string `protobuf:"bytes,2,opt,name=GroupName,proto3" json:"GroupName,omitempty"` Remarks string `protobuf:"bytes,3,opt,name=Remarks,proto3" json:"Remarks,omitempty"` Protocol string `protobuf:"bytes,4,opt,name=Protocol,proto3" json:"Protocol,omitempty"` // v2ray trojan ss ssr Ping string `protobuf:"bytes,5,opt,name=Ping,proto3" json:"Ping,omitempty"` AvgSpeed int64 `protobuf:"varint,6,opt,name=AvgSpeed,proto3" json:"AvgSpeed,omitempty"` MaxSpeed int64 `protobuf:"varint,7,opt,name=MaxSpeed,proto3" json:"MaxSpeed,omitempty"` IsOk bool `protobuf:"varint,8,opt,name=IsOk,proto3" json:"IsOk,omitempty"` Traffic int64 `protobuf:"varint,9,opt,name=Traffic,proto3" json:"Traffic,omitempty"` Link string `protobuf:"bytes,10,opt,name=Link,proto3" json:"Link,omitempty"` // contains filtered or unexported fields }
reply message
func (*TestReply) Descriptor
deprecated
func (*TestReply) GetAvgSpeed ¶
func (*TestReply) GetGroupName ¶
func (*TestReply) GetMaxSpeed ¶
func (*TestReply) GetProtocol ¶
func (*TestReply) GetRemarks ¶
func (*TestReply) GetTraffic ¶
func (*TestReply) ProtoMessage ¶
func (*TestReply) ProtoMessage()
func (*TestReply) ProtoReflect ¶
func (x *TestReply) ProtoReflect() protoreflect.Message
type TestRequest ¶
type TestRequest struct { GroupName string `protobuf:"bytes,1,opt,name=GroupName,proto3" json:"GroupName,omitempty"` SpeedTestMode SpeedTestMode `protobuf:"varint,2,opt,name=SpeedTestMode,proto3,enum=liteproxy.SpeedTestMode" json:"SpeedTestMode,omitempty"` PingMethod PingMethod `protobuf:"varint,3,opt,name=PingMethod,proto3,enum=liteproxy.PingMethod" json:"PingMethod,omitempty"` SortMethod SortMethod `protobuf:"varint,4,opt,name=SortMethod,proto3,enum=liteproxy.SortMethod" json:"SortMethod,omitempty"` Concurrency int32 `protobuf:"varint,5,opt,name=Concurrency,proto3" json:"Concurrency,omitempty"` TestMode uint32 `protobuf:"varint,6,opt,name=TestMode,proto3" json:"TestMode,omitempty"` // 0: all 1: speed only 2: ping only Subscription string `protobuf:"bytes,7,opt,name=Subscription,proto3" json:"Subscription,omitempty"` // subscription link, clash link, profile links Language string `protobuf:"bytes,8,opt,name=Language,proto3" json:"Language,omitempty"` FontSize uint32 `protobuf:"varint,9,opt,name=FontSize,proto3" json:"FontSize,omitempty"` Theme string `protobuf:"bytes,10,opt,name=Theme,proto3" json:"Theme,omitempty"` Timeout int64 `protobuf:"varint,11,opt,name=Timeout,proto3" json:"Timeout,omitempty"` OutputMode uint32 `protobuf:"varint,12,opt,name=OutputMode,proto3" json:"OutputMode,omitempty"` // 0: base64 1:file path 2: no pic 3: json 4: txt // contains filtered or unexported fields }
The request message containing the user's name.
func (*TestRequest) Descriptor
deprecated
func (*TestRequest) Descriptor() ([]byte, []int)
Deprecated: Use TestRequest.ProtoReflect.Descriptor instead.
func (*TestRequest) GetConcurrency ¶
func (x *TestRequest) GetConcurrency() int32
func (*TestRequest) GetFontSize ¶
func (x *TestRequest) GetFontSize() uint32
func (*TestRequest) GetGroupName ¶
func (x *TestRequest) GetGroupName() string
func (*TestRequest) GetLanguage ¶
func (x *TestRequest) GetLanguage() string
func (*TestRequest) GetOutputMode ¶ added in v0.15.0
func (x *TestRequest) GetOutputMode() uint32
func (*TestRequest) GetPingMethod ¶
func (x *TestRequest) GetPingMethod() PingMethod
func (*TestRequest) GetSortMethod ¶
func (x *TestRequest) GetSortMethod() SortMethod
func (*TestRequest) GetSpeedTestMode ¶
func (x *TestRequest) GetSpeedTestMode() SpeedTestMode
func (*TestRequest) GetSubscription ¶
func (x *TestRequest) GetSubscription() string
func (*TestRequest) GetTestMode ¶
func (x *TestRequest) GetTestMode() uint32
func (*TestRequest) GetTheme ¶
func (x *TestRequest) GetTheme() string
func (*TestRequest) GetTimeout ¶
func (x *TestRequest) GetTimeout() int64
func (*TestRequest) ProtoMessage ¶
func (*TestRequest) ProtoMessage()
func (*TestRequest) ProtoReflect ¶
func (x *TestRequest) ProtoReflect() protoreflect.Message
func (*TestRequest) Reset ¶
func (x *TestRequest) Reset()
func (*TestRequest) String ¶
func (x *TestRequest) String() string
type UnimplementedTestProxyServer ¶
type UnimplementedTestProxyServer struct { }
UnimplementedTestProxyServer must be embedded to have forward compatible implementations.
func (UnimplementedTestProxyServer) StartTest ¶
func (UnimplementedTestProxyServer) StartTest(*TestRequest, TestProxy_StartTestServer) error
type UnsafeTestProxyServer ¶
type UnsafeTestProxyServer interface {
// contains filtered or unexported methods
}
UnsafeTestProxyServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TestProxyServer will result in compilation errors.