From 612ad306605d0247fc6ff2f8baf8abc220d25988 Mon Sep 17 00:00:00 2001 From: CGQAQ Date: Tue, 27 Aug 2019 18:40:15 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- v2rayN/v2rayN/protos/Command.cs | 560 ---------------------------- v2rayN/v2rayN/protos/CommandGrpc.cs | 97 ----- 2 files changed, 657 deletions(-) delete mode 100644 v2rayN/v2rayN/protos/Command.cs delete mode 100644 v2rayN/v2rayN/protos/CommandGrpc.cs diff --git a/v2rayN/v2rayN/protos/Command.cs b/v2rayN/v2rayN/protos/Command.cs deleted file mode 100644 index 8c54f09b..00000000 --- a/v2rayN/v2rayN/protos/Command.cs +++ /dev/null @@ -1,560 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: command.proto -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.Protobuf; -using pbc = global::Google.Protobuf.Collections; -using pbr = global::Google.Protobuf.Reflection; -using scg = global::System.Collections.Generic; -namespace V2Ray.Core.App.Stats.Command { - - /// Holder for reflection information generated from command.proto - public static partial class CommandReflection { - - #region Descriptor - /// File descriptor for command.proto - public static pbr::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbr::FileDescriptor descriptor; - - static CommandReflection() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "Cg1jb21tYW5kLnByb3RvEhx2MnJheS5jb3JlLmFwcC5zdGF0cy5jb21tYW5k", - "Ii4KD0dldFN0YXRzUmVxdWVzdBIMCgRuYW1lGAEgASgJEg0KBXJlc2V0GAIg", - "ASgIIiMKBFN0YXQSDAoEbmFtZRgBIAEoCRINCgV2YWx1ZRgCIAEoAyJEChBH", - "ZXRTdGF0c1Jlc3BvbnNlEjAKBHN0YXQYASABKAsyIi52MnJheS5jb3JlLmFw", - "cC5zdGF0cy5jb21tYW5kLlN0YXQiCAoGQ29uZmlnMnsKDFN0YXRzU2Vydmlj", - "ZRJrCghHZXRTdGF0cxItLnYycmF5LmNvcmUuYXBwLnN0YXRzLmNvbW1hbmQu", - "R2V0U3RhdHNSZXF1ZXN0Gi4udjJyYXkuY29yZS5hcHAuc3RhdHMuY29tbWFu", - "ZC5HZXRTdGF0c1Jlc3BvbnNlIgBCTAogY29tLnYycmF5LmNvcmUuYXBwLnN0", - "YXRzLmNvbW1hbmRQAVoHY29tbWFuZKoCHFYyUmF5LkNvcmUuQXBwLlN0YXRz", - "LkNvbW1hbmRiBnByb3RvMw==")); - descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, - new pbr::FileDescriptor[] { }, - new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { - new pbr::GeneratedClrTypeInfo(typeof(global::V2Ray.Core.App.Stats.Command.GetStatsRequest), global::V2Ray.Core.App.Stats.Command.GetStatsRequest.Parser, new[]{ "Name", "Reset" }, null, null, null), - new pbr::GeneratedClrTypeInfo(typeof(global::V2Ray.Core.App.Stats.Command.Stat), global::V2Ray.Core.App.Stats.Command.Stat.Parser, new[]{ "Name", "Value" }, null, null, null), - new pbr::GeneratedClrTypeInfo(typeof(global::V2Ray.Core.App.Stats.Command.GetStatsResponse), global::V2Ray.Core.App.Stats.Command.GetStatsResponse.Parser, new[]{ "Stat" }, null, null, null), - new pbr::GeneratedClrTypeInfo(typeof(global::V2Ray.Core.App.Stats.Command.Config), global::V2Ray.Core.App.Stats.Command.Config.Parser, null, null, null, null) - })); - } - #endregion - - } - #region Messages - public sealed partial class GetStatsRequest : pb::IMessage { - private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetStatsRequest()); - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public static pb::MessageParser Parser { get { return _parser; } } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public static pbr::MessageDescriptor Descriptor { - get { return global::V2Ray.Core.App.Stats.Command.CommandReflection.Descriptor.MessageTypes[0]; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - pbr::MessageDescriptor pb::IMessage.Descriptor { - get { return Descriptor; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public GetStatsRequest() { - OnConstruction(); - } - - partial void OnConstruction(); - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public GetStatsRequest(GetStatsRequest other) : this() { - name_ = other.name_; - reset_ = other.reset_; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public GetStatsRequest Clone() { - return new GetStatsRequest(this); - } - - /// Field number for the "name" field. - public const int NameFieldNumber = 1; - private string name_ = ""; - /// - /// Name of the stat counter. - /// - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public string Name { - get { return name_; } - set { - name_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); - } - } - - /// Field number for the "reset" field. - public const int ResetFieldNumber = 2; - private bool reset_; - /// - /// Whether or not to reset the counter to fetching its value. - /// - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public bool Reset { - get { return reset_; } - set { - reset_ = value; - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override bool Equals(object other) { - return Equals(other as GetStatsRequest); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public bool Equals(GetStatsRequest other) { - if (ReferenceEquals(other, null)) { - return false; - } - if (ReferenceEquals(other, this)) { - return true; - } - if (Name != other.Name) return false; - if (Reset != other.Reset) return false; - return true; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override int GetHashCode() { - int hash = 1; - if (Name.Length != 0) hash ^= Name.GetHashCode(); - if (Reset != false) hash ^= Reset.GetHashCode(); - return hash; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override string ToString() { - return pb::JsonFormatter.ToDiagnosticString(this); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void WriteTo(pb::CodedOutputStream output) { - if (Name.Length != 0) { - output.WriteRawTag(10); - output.WriteString(Name); - } - if (Reset != false) { - output.WriteRawTag(16); - output.WriteBool(Reset); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public int CalculateSize() { - int size = 0; - if (Name.Length != 0) { - size += 1 + pb::CodedOutputStream.ComputeStringSize(Name); - } - if (Reset != false) { - size += 1 + 1; - } - return size; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void MergeFrom(GetStatsRequest other) { - if (other == null) { - return; - } - if (other.Name.Length != 0) { - Name = other.Name; - } - if (other.Reset != false) { - Reset = other.Reset; - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void MergeFrom(pb::CodedInputStream input) { - uint tag; - while ((tag = input.ReadTag()) != 0) { - switch(tag) { - default: - input.SkipLastField(); - break; - case 10: { - Name = input.ReadString(); - break; - } - case 16: { - Reset = input.ReadBool(); - break; - } - } - } - } - - } - - public sealed partial class Stat : pb::IMessage { - private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Stat()); - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public static pb::MessageParser Parser { get { return _parser; } } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public static pbr::MessageDescriptor Descriptor { - get { return global::V2Ray.Core.App.Stats.Command.CommandReflection.Descriptor.MessageTypes[1]; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - pbr::MessageDescriptor pb::IMessage.Descriptor { - get { return Descriptor; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public Stat() { - OnConstruction(); - } - - partial void OnConstruction(); - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public Stat(Stat other) : this() { - name_ = other.name_; - value_ = other.value_; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public Stat Clone() { - return new Stat(this); - } - - /// Field number for the "name" field. - public const int NameFieldNumber = 1; - private string name_ = ""; - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public string Name { - get { return name_; } - set { - name_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); - } - } - - /// Field number for the "value" field. - public const int ValueFieldNumber = 2; - private long value_; - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public long Value { - get { return value_; } - set { - value_ = value; - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override bool Equals(object other) { - return Equals(other as Stat); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public bool Equals(Stat other) { - if (ReferenceEquals(other, null)) { - return false; - } - if (ReferenceEquals(other, this)) { - return true; - } - if (Name != other.Name) return false; - if (Value != other.Value) return false; - return true; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override int GetHashCode() { - int hash = 1; - if (Name.Length != 0) hash ^= Name.GetHashCode(); - if (Value != 0L) hash ^= Value.GetHashCode(); - return hash; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override string ToString() { - return pb::JsonFormatter.ToDiagnosticString(this); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void WriteTo(pb::CodedOutputStream output) { - if (Name.Length != 0) { - output.WriteRawTag(10); - output.WriteString(Name); - } - if (Value != 0L) { - output.WriteRawTag(16); - output.WriteInt64(Value); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public int CalculateSize() { - int size = 0; - if (Name.Length != 0) { - size += 1 + pb::CodedOutputStream.ComputeStringSize(Name); - } - if (Value != 0L) { - size += 1 + pb::CodedOutputStream.ComputeInt64Size(Value); - } - return size; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void MergeFrom(Stat other) { - if (other == null) { - return; - } - if (other.Name.Length != 0) { - Name = other.Name; - } - if (other.Value != 0L) { - Value = other.Value; - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void MergeFrom(pb::CodedInputStream input) { - uint tag; - while ((tag = input.ReadTag()) != 0) { - switch(tag) { - default: - input.SkipLastField(); - break; - case 10: { - Name = input.ReadString(); - break; - } - case 16: { - Value = input.ReadInt64(); - break; - } - } - } - } - - } - - public sealed partial class GetStatsResponse : pb::IMessage { - private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new GetStatsResponse()); - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public static pb::MessageParser Parser { get { return _parser; } } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public static pbr::MessageDescriptor Descriptor { - get { return global::V2Ray.Core.App.Stats.Command.CommandReflection.Descriptor.MessageTypes[2]; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - pbr::MessageDescriptor pb::IMessage.Descriptor { - get { return Descriptor; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public GetStatsResponse() { - OnConstruction(); - } - - partial void OnConstruction(); - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public GetStatsResponse(GetStatsResponse other) : this() { - Stat = other.stat_ != null ? other.Stat.Clone() : null; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public GetStatsResponse Clone() { - return new GetStatsResponse(this); - } - - /// Field number for the "stat" field. - public const int StatFieldNumber = 1; - private global::V2Ray.Core.App.Stats.Command.Stat stat_; - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public global::V2Ray.Core.App.Stats.Command.Stat Stat { - get { return stat_; } - set { - stat_ = value; - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override bool Equals(object other) { - return Equals(other as GetStatsResponse); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public bool Equals(GetStatsResponse other) { - if (ReferenceEquals(other, null)) { - return false; - } - if (ReferenceEquals(other, this)) { - return true; - } - if (!object.Equals(Stat, other.Stat)) return false; - return true; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override int GetHashCode() { - int hash = 1; - if (stat_ != null) hash ^= Stat.GetHashCode(); - return hash; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override string ToString() { - return pb::JsonFormatter.ToDiagnosticString(this); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void WriteTo(pb::CodedOutputStream output) { - if (stat_ != null) { - output.WriteRawTag(10); - output.WriteMessage(Stat); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public int CalculateSize() { - int size = 0; - if (stat_ != null) { - size += 1 + pb::CodedOutputStream.ComputeMessageSize(Stat); - } - return size; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void MergeFrom(GetStatsResponse other) { - if (other == null) { - return; - } - if (other.stat_ != null) { - if (stat_ == null) { - stat_ = new global::V2Ray.Core.App.Stats.Command.Stat(); - } - Stat.MergeFrom(other.Stat); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void MergeFrom(pb::CodedInputStream input) { - uint tag; - while ((tag = input.ReadTag()) != 0) { - switch(tag) { - default: - input.SkipLastField(); - break; - case 10: { - if (stat_ == null) { - stat_ = new global::V2Ray.Core.App.Stats.Command.Stat(); - } - input.ReadMessage(stat_); - break; - } - } - } - } - - } - - public sealed partial class Config : pb::IMessage { - private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Config()); - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public static pb::MessageParser Parser { get { return _parser; } } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public static pbr::MessageDescriptor Descriptor { - get { return global::V2Ray.Core.App.Stats.Command.CommandReflection.Descriptor.MessageTypes[3]; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - pbr::MessageDescriptor pb::IMessage.Descriptor { - get { return Descriptor; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public Config() { - OnConstruction(); - } - - partial void OnConstruction(); - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public Config(Config other) : this() { - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public Config Clone() { - return new Config(this); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override bool Equals(object other) { - return Equals(other as Config); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public bool Equals(Config other) { - if (ReferenceEquals(other, null)) { - return false; - } - if (ReferenceEquals(other, this)) { - return true; - } - return true; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override int GetHashCode() { - int hash = 1; - return hash; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public override string ToString() { - return pb::JsonFormatter.ToDiagnosticString(this); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void WriteTo(pb::CodedOutputStream output) { - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public int CalculateSize() { - int size = 0; - return size; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void MergeFrom(Config other) { - if (other == null) { - return; - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - public void MergeFrom(pb::CodedInputStream input) { - uint tag; - while ((tag = input.ReadTag()) != 0) { - switch(tag) { - default: - input.SkipLastField(); - break; - } - } - } - - } - - #endregion - -} - -#endregion Designer generated code diff --git a/v2rayN/v2rayN/protos/CommandGrpc.cs b/v2rayN/v2rayN/protos/CommandGrpc.cs deleted file mode 100644 index 6fdec4d6..00000000 --- a/v2rayN/v2rayN/protos/CommandGrpc.cs +++ /dev/null @@ -1,97 +0,0 @@ -// -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: command.proto -// -#pragma warning disable 1591 -#region Designer generated code - -using grpc = global::Grpc.Core; - -namespace V2Ray.Core.App.Stats.Command { - public static partial class StatsService - { - static readonly string __ServiceName = "v2ray.core.app.stats.command.StatsService"; - - static readonly grpc::Marshaller __Marshaller_GetStatsRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::V2Ray.Core.App.Stats.Command.GetStatsRequest.Parser.ParseFrom); - static readonly grpc::Marshaller __Marshaller_GetStatsResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::V2Ray.Core.App.Stats.Command.GetStatsResponse.Parser.ParseFrom); - - static readonly grpc::Method __Method_GetStats = new grpc::Method( - grpc::MethodType.Unary, - __ServiceName, - "GetStats", - __Marshaller_GetStatsRequest, - __Marshaller_GetStatsResponse); - - /// Service descriptor - public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor - { - get { return global::V2Ray.Core.App.Stats.Command.CommandReflection.Descriptor.Services[0]; } - } - - /// Base class for server-side implementations of StatsService - public abstract partial class StatsServiceBase - { - public virtual global::System.Threading.Tasks.Task GetStats(global::V2Ray.Core.App.Stats.Command.GetStatsRequest request, grpc::ServerCallContext context) - { - throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, "")); - } - - } - - /// Client for StatsService - public partial class StatsServiceClient : grpc::ClientBase - { - /// Creates a new client for StatsService - /// The channel to use to make remote calls. - public StatsServiceClient(grpc::Channel channel) : base(channel) - { - } - /// Creates a new client for StatsService that uses a custom CallInvoker. - /// The callInvoker to use to make remote calls. - public StatsServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker) - { - } - /// Protected parameterless constructor to allow creation of test doubles. - protected StatsServiceClient() : base() - { - } - /// Protected constructor to allow creation of configured clients. - /// The client configuration. - protected StatsServiceClient(ClientBaseConfiguration configuration) : base(configuration) - { - } - - public virtual global::V2Ray.Core.App.Stats.Command.GetStatsResponse GetStats(global::V2Ray.Core.App.Stats.Command.GetStatsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) - { - return GetStats(request, new grpc::CallOptions(headers, deadline, cancellationToken)); - } - public virtual global::V2Ray.Core.App.Stats.Command.GetStatsResponse GetStats(global::V2Ray.Core.App.Stats.Command.GetStatsRequest request, grpc::CallOptions options) - { - return CallInvoker.BlockingUnaryCall(__Method_GetStats, null, options, request); - } - public virtual grpc::AsyncUnaryCall GetStatsAsync(global::V2Ray.Core.App.Stats.Command.GetStatsRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken)) - { - return GetStatsAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken)); - } - public virtual grpc::AsyncUnaryCall GetStatsAsync(global::V2Ray.Core.App.Stats.Command.GetStatsRequest request, grpc::CallOptions options) - { - return CallInvoker.AsyncUnaryCall(__Method_GetStats, null, options, request); - } - /// Creates a new instance of client from given ClientBaseConfiguration. - protected override StatsServiceClient NewInstance(ClientBaseConfiguration configuration) - { - return new StatsServiceClient(configuration); - } - } - - /// Creates service definition that can be registered with a server - /// An object implementing the server-side handling logic. - public static grpc::ServerServiceDefinition BindService(StatsServiceBase serviceImpl) - { - return grpc::ServerServiceDefinition.CreateBuilder() - .AddMethod(__Method_GetStats, serviceImpl.GetStats).Build(); - } - - } -} -#endregion