@marleena/trb-proto 1.0.51 → 1.0.53

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3480,7 +3480,8 @@ proto.trb.strategy.v1.GetBacktestResultRequest.toObject = function(includeInstan
3480
3480
  runId: jspb.Message.getFieldWithDefault(msg, 1, ""),
3481
3481
  includeEquity: jspb.Message.getBooleanFieldWithDefault(msg, 2, false),
3482
3482
  includeTrades: jspb.Message.getBooleanFieldWithDefault(msg, 3, false),
3483
- equityMaxPoints: jspb.Message.getFieldWithDefault(msg, 4, 0)
3483
+ equityMaxPoints: jspb.Message.getFieldWithDefault(msg, 4, 0),
3484
+ includeIndicators: jspb.Message.getBooleanFieldWithDefault(msg, 5, false)
3484
3485
  };
3485
3486
 
3486
3487
  if (includeInstance) {
@@ -3533,6 +3534,10 @@ proto.trb.strategy.v1.GetBacktestResultRequest.deserializeBinaryFromReader = fun
3533
3534
  var value = /** @type {number} */ (reader.readInt32());
3534
3535
  msg.setEquityMaxPoints(value);
3535
3536
  break;
3537
+ case 5:
3538
+ var value = /** @type {boolean} */ (reader.readBool());
3539
+ msg.setIncludeIndicators(value);
3540
+ break;
3536
3541
  default:
3537
3542
  reader.skipField();
3538
3543
  break;
@@ -3590,6 +3595,13 @@ proto.trb.strategy.v1.GetBacktestResultRequest.serializeBinaryToWriter = functio
3590
3595
  f
3591
3596
  );
3592
3597
  }
3598
+ f = message.getIncludeIndicators();
3599
+ if (f) {
3600
+ writer.writeBool(
3601
+ 5,
3602
+ f
3603
+ );
3604
+ }
3593
3605
  };
3594
3606
 
3595
3607
 
@@ -3665,13 +3677,31 @@ proto.trb.strategy.v1.GetBacktestResultRequest.prototype.setEquityMaxPoints = fu
3665
3677
  };
3666
3678
 
3667
3679
 
3680
+ /**
3681
+ * optional bool include_indicators = 5;
3682
+ * @return {boolean}
3683
+ */
3684
+ proto.trb.strategy.v1.GetBacktestResultRequest.prototype.getIncludeIndicators = function() {
3685
+ return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 5, false));
3686
+ };
3687
+
3688
+
3689
+ /**
3690
+ * @param {boolean} value
3691
+ * @return {!proto.trb.strategy.v1.GetBacktestResultRequest} returns this
3692
+ */
3693
+ proto.trb.strategy.v1.GetBacktestResultRequest.prototype.setIncludeIndicators = function(value) {
3694
+ return jspb.Message.setProto3BooleanField(this, 5, value);
3695
+ };
3696
+
3697
+
3668
3698
 
3669
3699
  /**
3670
3700
  * List of repeated fields within this message type.
3671
3701
  * @private {!Array<number>}
3672
3702
  * @const
3673
3703
  */
3674
- proto.trb.strategy.v1.GetBacktestResultResponse.repeatedFields_ = [3,4];
3704
+ proto.trb.strategy.v1.GetBacktestResultResponse.repeatedFields_ = [3,4,5];
3675
3705
 
3676
3706
 
3677
3707
 
@@ -3709,7 +3739,9 @@ metrics: (f = msg.getMetrics()) && strategy_backtest_pb.BacktestMetrics.toObject
3709
3739
  equityList: jspb.Message.toObjectList(msg.getEquityList(),
3710
3740
  strategy_backtest_pb.EquityPoint.toObject, includeInstance),
3711
3741
  tradesList: jspb.Message.toObjectList(msg.getTradesList(),
3712
- strategy_backtest_pb.TradeRecord.toObject, includeInstance)
3742
+ strategy_backtest_pb.TradeRecord.toObject, includeInstance),
3743
+ indicatorsList: jspb.Message.toObjectList(msg.getIndicatorsList(),
3744
+ strategy_backtest_pb.BacktestIndicatorSeries.toObject, includeInstance)
3713
3745
  };
3714
3746
 
3715
3747
  if (includeInstance) {
@@ -3766,6 +3798,11 @@ proto.trb.strategy.v1.GetBacktestResultResponse.deserializeBinaryFromReader = fu
3766
3798
  reader.readMessage(value,strategy_backtest_pb.TradeRecord.deserializeBinaryFromReader);
3767
3799
  msg.addTrades(value);
3768
3800
  break;
3801
+ case 5:
3802
+ var value = new strategy_backtest_pb.BacktestIndicatorSeries;
3803
+ reader.readMessage(value,strategy_backtest_pb.BacktestIndicatorSeries.deserializeBinaryFromReader);
3804
+ msg.addIndicators(value);
3805
+ break;
3769
3806
  default:
3770
3807
  reader.skipField();
3771
3808
  break;
@@ -3827,6 +3864,14 @@ proto.trb.strategy.v1.GetBacktestResultResponse.serializeBinaryToWriter = functi
3827
3864
  strategy_backtest_pb.TradeRecord.serializeBinaryToWriter
3828
3865
  );
3829
3866
  }
3867
+ f = message.getIndicatorsList();
3868
+ if (f.length > 0) {
3869
+ writer.writeRepeatedMessage(
3870
+ 5,
3871
+ f,
3872
+ strategy_backtest_pb.BacktestIndicatorSeries.serializeBinaryToWriter
3873
+ );
3874
+ }
3830
3875
  };
3831
3876
 
3832
3877
 
@@ -3980,6 +4025,44 @@ proto.trb.strategy.v1.GetBacktestResultResponse.prototype.clearTradesList = func
3980
4025
  };
3981
4026
 
3982
4027
 
4028
+ /**
4029
+ * repeated BacktestIndicatorSeries indicators = 5;
4030
+ * @return {!Array<!proto.trb.strategy.v1.BacktestIndicatorSeries>}
4031
+ */
4032
+ proto.trb.strategy.v1.GetBacktestResultResponse.prototype.getIndicatorsList = function() {
4033
+ return /** @type{!Array<!proto.trb.strategy.v1.BacktestIndicatorSeries>} */ (
4034
+ jspb.Message.getRepeatedWrapperField(this, strategy_backtest_pb.BacktestIndicatorSeries, 5));
4035
+ };
4036
+
4037
+
4038
+ /**
4039
+ * @param {!Array<!proto.trb.strategy.v1.BacktestIndicatorSeries>} value
4040
+ * @return {!proto.trb.strategy.v1.GetBacktestResultResponse} returns this
4041
+ */
4042
+ proto.trb.strategy.v1.GetBacktestResultResponse.prototype.setIndicatorsList = function(value) {
4043
+ return jspb.Message.setRepeatedWrapperField(this, 5, value);
4044
+ };
4045
+
4046
+
4047
+ /**
4048
+ * @param {!proto.trb.strategy.v1.BacktestIndicatorSeries=} opt_value
4049
+ * @param {number=} opt_index
4050
+ * @return {!proto.trb.strategy.v1.BacktestIndicatorSeries}
4051
+ */
4052
+ proto.trb.strategy.v1.GetBacktestResultResponse.prototype.addIndicators = function(opt_value, opt_index) {
4053
+ return jspb.Message.addToRepeatedWrapperField(this, 5, opt_value, proto.trb.strategy.v1.BacktestIndicatorSeries, opt_index);
4054
+ };
4055
+
4056
+
4057
+ /**
4058
+ * Clears the list making it empty but non-null.
4059
+ * @return {!proto.trb.strategy.v1.GetBacktestResultResponse} returns this
4060
+ */
4061
+ proto.trb.strategy.v1.GetBacktestResultResponse.prototype.clearIndicatorsList = function() {
4062
+ return this.setIndicatorsList([]);
4063
+ };
4064
+
4065
+
3983
4066
 
3984
4067
 
3985
4068
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@marleena/trb-proto",
3
- "version": "1.0.51",
3
+ "version": "1.0.53",
4
4
  "description": "Generated protobuf messages and gRPC-Web clients for TrB services",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -1,259 +0,0 @@
1
- /**
2
- * @fileoverview gRPC-Web generated client stub for trb.clickhouse.v1
3
- * @enhanceable
4
- * @public
5
- */
6
-
7
- // Code generated by protoc-gen-grpc-web. DO NOT EDIT.
8
- // versions:
9
- // protoc-gen-grpc-web v1.5.0
10
- // protoc v7.34.1
11
- // source: clickhouse/clickhouse.proto
12
-
13
-
14
- /* eslint-disable */
15
- // @ts-nocheck
16
-
17
-
18
- import * as grpcWeb from 'grpc-web';
19
-
20
- import * as api_tinvest_instruments_pb from '../api/tinvest/instruments_pb'; // proto import: "api/tinvest/instruments.proto"
21
- import * as clickhouse_clickhouse_pb from '../clickhouse/clickhouse_pb'; // proto import: "clickhouse/clickhouse.proto"
22
-
23
-
24
- export class ClickHouseClient {
25
- client_: grpcWeb.AbstractClientBase;
26
- hostname_: string;
27
- credentials_: null | { [index: string]: string; };
28
- options_: null | { [index: string]: any; };
29
-
30
- constructor (hostname: string,
31
- credentials?: null | { [index: string]: string; },
32
- options?: null | { [index: string]: any; }) {
33
- if (!options) options = {};
34
- if (!credentials) credentials = {};
35
- options['format'] = 'binary';
36
-
37
- this.client_ = new grpcWeb.GrpcWebClientBase(options);
38
- this.hostname_ = hostname.replace(/\/+$/, '');
39
- this.credentials_ = credentials;
40
- this.options_ = options;
41
- }
42
-
43
- methodDescriptorListInstruments = new grpcWeb.MethodDescriptor(
44
- '/trb.clickhouse.v1.ClickHouse/ListInstruments',
45
- grpcWeb.MethodType.UNARY,
46
- clickhouse_clickhouse_pb.ListInstrumentsRequest,
47
- clickhouse_clickhouse_pb.ListInstrumentsResponse,
48
- (request: clickhouse_clickhouse_pb.ListInstrumentsRequest) => {
49
- return request.serializeBinary();
50
- },
51
- clickhouse_clickhouse_pb.ListInstrumentsResponse.deserializeBinary
52
- );
53
-
54
- listInstruments(
55
- request: clickhouse_clickhouse_pb.ListInstrumentsRequest,
56
- metadata?: grpcWeb.Metadata | null): Promise<clickhouse_clickhouse_pb.ListInstrumentsResponse>;
57
-
58
- listInstruments(
59
- request: clickhouse_clickhouse_pb.ListInstrumentsRequest,
60
- metadata: grpcWeb.Metadata | null,
61
- callback: (err: grpcWeb.RpcError,
62
- response: clickhouse_clickhouse_pb.ListInstrumentsResponse) => void): grpcWeb.ClientReadableStream<clickhouse_clickhouse_pb.ListInstrumentsResponse>;
63
-
64
- listInstruments(
65
- request: clickhouse_clickhouse_pb.ListInstrumentsRequest,
66
- metadata?: grpcWeb.Metadata | null,
67
- callback?: (err: grpcWeb.RpcError,
68
- response: clickhouse_clickhouse_pb.ListInstrumentsResponse) => void) {
69
- if (callback !== undefined) {
70
- return this.client_.rpcCall(
71
- this.hostname_ +
72
- '/trb.clickhouse.v1.ClickHouse/ListInstruments',
73
- request,
74
- metadata || {},
75
- this.methodDescriptorListInstruments,
76
- callback);
77
- }
78
- return this.client_.unaryCall(
79
- this.hostname_ +
80
- '/trb.clickhouse.v1.ClickHouse/ListInstruments',
81
- request,
82
- metadata || {},
83
- this.methodDescriptorListInstruments);
84
- }
85
-
86
- methodDescriptorListInstrumentVersions = new grpcWeb.MethodDescriptor(
87
- '/trb.clickhouse.v1.ClickHouse/ListInstrumentVersions',
88
- grpcWeb.MethodType.UNARY,
89
- clickhouse_clickhouse_pb.ListInstrumentVersionsRequest,
90
- clickhouse_clickhouse_pb.ListInstrumentVersionsResponse,
91
- (request: clickhouse_clickhouse_pb.ListInstrumentVersionsRequest) => {
92
- return request.serializeBinary();
93
- },
94
- clickhouse_clickhouse_pb.ListInstrumentVersionsResponse.deserializeBinary
95
- );
96
-
97
- listInstrumentVersions(
98
- request: clickhouse_clickhouse_pb.ListInstrumentVersionsRequest,
99
- metadata?: grpcWeb.Metadata | null): Promise<clickhouse_clickhouse_pb.ListInstrumentVersionsResponse>;
100
-
101
- listInstrumentVersions(
102
- request: clickhouse_clickhouse_pb.ListInstrumentVersionsRequest,
103
- metadata: grpcWeb.Metadata | null,
104
- callback: (err: grpcWeb.RpcError,
105
- response: clickhouse_clickhouse_pb.ListInstrumentVersionsResponse) => void): grpcWeb.ClientReadableStream<clickhouse_clickhouse_pb.ListInstrumentVersionsResponse>;
106
-
107
- listInstrumentVersions(
108
- request: clickhouse_clickhouse_pb.ListInstrumentVersionsRequest,
109
- metadata?: grpcWeb.Metadata | null,
110
- callback?: (err: grpcWeb.RpcError,
111
- response: clickhouse_clickhouse_pb.ListInstrumentVersionsResponse) => void) {
112
- if (callback !== undefined) {
113
- return this.client_.rpcCall(
114
- this.hostname_ +
115
- '/trb.clickhouse.v1.ClickHouse/ListInstrumentVersions',
116
- request,
117
- metadata || {},
118
- this.methodDescriptorListInstrumentVersions,
119
- callback);
120
- }
121
- return this.client_.unaryCall(
122
- this.hostname_ +
123
- '/trb.clickhouse.v1.ClickHouse/ListInstrumentVersions',
124
- request,
125
- metadata || {},
126
- this.methodDescriptorListInstrumentVersions);
127
- }
128
-
129
- methodDescriptorUpsertInstruments = new grpcWeb.MethodDescriptor(
130
- '/trb.clickhouse.v1.ClickHouse/UpsertInstruments',
131
- grpcWeb.MethodType.UNARY,
132
- api_tinvest_instruments_pb.SharesResponse,
133
- clickhouse_clickhouse_pb.UpsertInstrumentsResponse,
134
- (request: api_tinvest_instruments_pb.SharesResponse) => {
135
- return request.serializeBinary();
136
- },
137
- clickhouse_clickhouse_pb.UpsertInstrumentsResponse.deserializeBinary
138
- );
139
-
140
- upsertInstruments(
141
- request: api_tinvest_instruments_pb.SharesResponse,
142
- metadata?: grpcWeb.Metadata | null): Promise<clickhouse_clickhouse_pb.UpsertInstrumentsResponse>;
143
-
144
- upsertInstruments(
145
- request: api_tinvest_instruments_pb.SharesResponse,
146
- metadata: grpcWeb.Metadata | null,
147
- callback: (err: grpcWeb.RpcError,
148
- response: clickhouse_clickhouse_pb.UpsertInstrumentsResponse) => void): grpcWeb.ClientReadableStream<clickhouse_clickhouse_pb.UpsertInstrumentsResponse>;
149
-
150
- upsertInstruments(
151
- request: api_tinvest_instruments_pb.SharesResponse,
152
- metadata?: grpcWeb.Metadata | null,
153
- callback?: (err: grpcWeb.RpcError,
154
- response: clickhouse_clickhouse_pb.UpsertInstrumentsResponse) => void) {
155
- if (callback !== undefined) {
156
- return this.client_.rpcCall(
157
- this.hostname_ +
158
- '/trb.clickhouse.v1.ClickHouse/UpsertInstruments',
159
- request,
160
- metadata || {},
161
- this.methodDescriptorUpsertInstruments,
162
- callback);
163
- }
164
- return this.client_.unaryCall(
165
- this.hostname_ +
166
- '/trb.clickhouse.v1.ClickHouse/UpsertInstruments',
167
- request,
168
- metadata || {},
169
- this.methodDescriptorUpsertInstruments);
170
- }
171
-
172
- methodDescriptorListLastDownloads = new grpcWeb.MethodDescriptor(
173
- '/trb.clickhouse.v1.ClickHouse/ListLastDownloads',
174
- grpcWeb.MethodType.UNARY,
175
- clickhouse_clickhouse_pb.ListLastDownloadsRequest,
176
- clickhouse_clickhouse_pb.ListLastDownloadsResponse,
177
- (request: clickhouse_clickhouse_pb.ListLastDownloadsRequest) => {
178
- return request.serializeBinary();
179
- },
180
- clickhouse_clickhouse_pb.ListLastDownloadsResponse.deserializeBinary
181
- );
182
-
183
- listLastDownloads(
184
- request: clickhouse_clickhouse_pb.ListLastDownloadsRequest,
185
- metadata?: grpcWeb.Metadata | null): Promise<clickhouse_clickhouse_pb.ListLastDownloadsResponse>;
186
-
187
- listLastDownloads(
188
- request: clickhouse_clickhouse_pb.ListLastDownloadsRequest,
189
- metadata: grpcWeb.Metadata | null,
190
- callback: (err: grpcWeb.RpcError,
191
- response: clickhouse_clickhouse_pb.ListLastDownloadsResponse) => void): grpcWeb.ClientReadableStream<clickhouse_clickhouse_pb.ListLastDownloadsResponse>;
192
-
193
- listLastDownloads(
194
- request: clickhouse_clickhouse_pb.ListLastDownloadsRequest,
195
- metadata?: grpcWeb.Metadata | null,
196
- callback?: (err: grpcWeb.RpcError,
197
- response: clickhouse_clickhouse_pb.ListLastDownloadsResponse) => void) {
198
- if (callback !== undefined) {
199
- return this.client_.rpcCall(
200
- this.hostname_ +
201
- '/trb.clickhouse.v1.ClickHouse/ListLastDownloads',
202
- request,
203
- metadata || {},
204
- this.methodDescriptorListLastDownloads,
205
- callback);
206
- }
207
- return this.client_.unaryCall(
208
- this.hostname_ +
209
- '/trb.clickhouse.v1.ClickHouse/ListLastDownloads',
210
- request,
211
- metadata || {},
212
- this.methodDescriptorListLastDownloads);
213
- }
214
-
215
- methodDescriptorListCandles = new grpcWeb.MethodDescriptor(
216
- '/trb.clickhouse.v1.ClickHouse/ListCandles',
217
- grpcWeb.MethodType.UNARY,
218
- clickhouse_clickhouse_pb.ListCandlesRequest,
219
- clickhouse_clickhouse_pb.ListCandlesResponse,
220
- (request: clickhouse_clickhouse_pb.ListCandlesRequest) => {
221
- return request.serializeBinary();
222
- },
223
- clickhouse_clickhouse_pb.ListCandlesResponse.deserializeBinary
224
- );
225
-
226
- listCandles(
227
- request: clickhouse_clickhouse_pb.ListCandlesRequest,
228
- metadata?: grpcWeb.Metadata | null): Promise<clickhouse_clickhouse_pb.ListCandlesResponse>;
229
-
230
- listCandles(
231
- request: clickhouse_clickhouse_pb.ListCandlesRequest,
232
- metadata: grpcWeb.Metadata | null,
233
- callback: (err: grpcWeb.RpcError,
234
- response: clickhouse_clickhouse_pb.ListCandlesResponse) => void): grpcWeb.ClientReadableStream<clickhouse_clickhouse_pb.ListCandlesResponse>;
235
-
236
- listCandles(
237
- request: clickhouse_clickhouse_pb.ListCandlesRequest,
238
- metadata?: grpcWeb.Metadata | null,
239
- callback?: (err: grpcWeb.RpcError,
240
- response: clickhouse_clickhouse_pb.ListCandlesResponse) => void) {
241
- if (callback !== undefined) {
242
- return this.client_.rpcCall(
243
- this.hostname_ +
244
- '/trb.clickhouse.v1.ClickHouse/ListCandles',
245
- request,
246
- metadata || {},
247
- this.methodDescriptorListCandles,
248
- callback);
249
- }
250
- return this.client_.unaryCall(
251
- this.hostname_ +
252
- '/trb.clickhouse.v1.ClickHouse/ListCandles',
253
- request,
254
- metadata || {},
255
- this.methodDescriptorListCandles);
256
- }
257
-
258
- }
259
-