• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

lightningnetwork / lnd / 13408822928

19 Feb 2025 08:59AM UTC coverage: 41.123% (-17.7%) from 58.794%
13408822928

Pull #9521

github

web-flow
Merge d2f397b3c into 0e8786348
Pull Request #9521: unit: remove GOACC, use Go 1.20 native coverage functionality

92496 of 224923 relevant lines covered (41.12%)

18825.83 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

11.98
/lnrpc/stateservice.pb.go
1
// Code generated by protoc-gen-go. DO NOT EDIT.
2
// versions:
3
//         protoc-gen-go v1.33.0
4
//         protoc        v3.21.12
5
// source: stateservice.proto
6

7
package lnrpc
8

9
import (
10
        protoreflect "google.golang.org/protobuf/reflect/protoreflect"
11
        protoimpl "google.golang.org/protobuf/runtime/protoimpl"
12
        reflect "reflect"
13
        sync "sync"
14
)
15

16
const (
17
        // Verify that this generated code is sufficiently up-to-date.
18
        _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
19
        // Verify that runtime/protoimpl is sufficiently up-to-date.
20
        _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
21
)
22

23
type WalletState int32
24

25
const (
26
        // NON_EXISTING means that the wallet has not yet been initialized.
27
        WalletState_NON_EXISTING WalletState = 0
28
        // LOCKED means that the wallet is locked and requires a password to unlock.
29
        WalletState_LOCKED WalletState = 1
30
        // UNLOCKED means that the wallet was unlocked successfully, but RPC server
31
        // isn't ready.
32
        WalletState_UNLOCKED WalletState = 2
33
        // RPC_ACTIVE means that the lnd server is active but not fully ready for
34
        // calls.
35
        WalletState_RPC_ACTIVE WalletState = 3
36
        // SERVER_ACTIVE means that the lnd server is ready to accept calls.
37
        WalletState_SERVER_ACTIVE WalletState = 4
38
        // WAITING_TO_START means that node is waiting to become the leader in a
39
        // cluster and is not started yet.
40
        WalletState_WAITING_TO_START WalletState = 255
41
)
42

43
// Enum value maps for WalletState.
44
var (
45
        WalletState_name = map[int32]string{
46
                0:   "NON_EXISTING",
47
                1:   "LOCKED",
48
                2:   "UNLOCKED",
49
                3:   "RPC_ACTIVE",
50
                4:   "SERVER_ACTIVE",
51
                255: "WAITING_TO_START",
52
        }
53
        WalletState_value = map[string]int32{
54
                "NON_EXISTING":     0,
55
                "LOCKED":           1,
56
                "UNLOCKED":         2,
57
                "RPC_ACTIVE":       3,
58
                "SERVER_ACTIVE":    4,
59
                "WAITING_TO_START": 255,
60
        }
61
)
62

63
func (x WalletState) Enum() *WalletState {
×
64
        p := new(WalletState)
×
65
        *p = x
×
66
        return p
×
67
}
×
68

69
func (x WalletState) String() string {
×
70
        return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
×
71
}
×
72

73
func (WalletState) Descriptor() protoreflect.EnumDescriptor {
×
74
        return file_stateservice_proto_enumTypes[0].Descriptor()
×
75
}
×
76

77
func (WalletState) Type() protoreflect.EnumType {
×
78
        return &file_stateservice_proto_enumTypes[0]
×
79
}
×
80

81
func (x WalletState) Number() protoreflect.EnumNumber {
×
82
        return protoreflect.EnumNumber(x)
×
83
}
×
84

85
// Deprecated: Use WalletState.Descriptor instead.
86
func (WalletState) EnumDescriptor() ([]byte, []int) {
×
87
        return file_stateservice_proto_rawDescGZIP(), []int{0}
×
88
}
×
89

90
type SubscribeStateRequest struct {
91
        state         protoimpl.MessageState
92
        sizeCache     protoimpl.SizeCache
93
        unknownFields protoimpl.UnknownFields
94
}
95

96
func (x *SubscribeStateRequest) Reset() {
×
97
        *x = SubscribeStateRequest{}
×
98
        if protoimpl.UnsafeEnabled {
×
99
                mi := &file_stateservice_proto_msgTypes[0]
×
100
                ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
×
101
                ms.StoreMessageInfo(mi)
×
102
        }
×
103
}
104

105
func (x *SubscribeStateRequest) String() string {
×
106
        return protoimpl.X.MessageStringOf(x)
×
107
}
×
108

109
func (*SubscribeStateRequest) ProtoMessage() {}
×
110

111
func (x *SubscribeStateRequest) ProtoReflect() protoreflect.Message {
×
112
        mi := &file_stateservice_proto_msgTypes[0]
×
113
        if protoimpl.UnsafeEnabled && x != nil {
×
114
                ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
×
115
                if ms.LoadMessageInfo() == nil {
×
116
                        ms.StoreMessageInfo(mi)
×
117
                }
×
118
                return ms
×
119
        }
120
        return mi.MessageOf(x)
×
121
}
122

123
// Deprecated: Use SubscribeStateRequest.ProtoReflect.Descriptor instead.
124
func (*SubscribeStateRequest) Descriptor() ([]byte, []int) {
×
125
        return file_stateservice_proto_rawDescGZIP(), []int{0}
×
126
}
×
127

128
type SubscribeStateResponse struct {
129
        state         protoimpl.MessageState
130
        sizeCache     protoimpl.SizeCache
131
        unknownFields protoimpl.UnknownFields
132

133
        State WalletState `protobuf:"varint,1,opt,name=state,proto3,enum=lnrpc.WalletState" json:"state,omitempty"`
134
}
135

136
func (x *SubscribeStateResponse) Reset() {
×
137
        *x = SubscribeStateResponse{}
×
138
        if protoimpl.UnsafeEnabled {
×
139
                mi := &file_stateservice_proto_msgTypes[1]
×
140
                ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
×
141
                ms.StoreMessageInfo(mi)
×
142
        }
×
143
}
144

145
func (x *SubscribeStateResponse) String() string {
×
146
        return protoimpl.X.MessageStringOf(x)
×
147
}
×
148

149
func (*SubscribeStateResponse) ProtoMessage() {}
×
150

151
func (x *SubscribeStateResponse) ProtoReflect() protoreflect.Message {
×
152
        mi := &file_stateservice_proto_msgTypes[1]
×
153
        if protoimpl.UnsafeEnabled && x != nil {
×
154
                ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
×
155
                if ms.LoadMessageInfo() == nil {
×
156
                        ms.StoreMessageInfo(mi)
×
157
                }
×
158
                return ms
×
159
        }
160
        return mi.MessageOf(x)
×
161
}
162

163
// Deprecated: Use SubscribeStateResponse.ProtoReflect.Descriptor instead.
164
func (*SubscribeStateResponse) Descriptor() ([]byte, []int) {
×
165
        return file_stateservice_proto_rawDescGZIP(), []int{1}
×
166
}
×
167

168
func (x *SubscribeStateResponse) GetState() WalletState {
×
169
        if x != nil {
×
170
                return x.State
×
171
        }
×
172
        return WalletState_NON_EXISTING
×
173
}
174

175
type GetStateRequest struct {
176
        state         protoimpl.MessageState
177
        sizeCache     protoimpl.SizeCache
178
        unknownFields protoimpl.UnknownFields
179
}
180

181
func (x *GetStateRequest) Reset() {
×
182
        *x = GetStateRequest{}
×
183
        if protoimpl.UnsafeEnabled {
×
184
                mi := &file_stateservice_proto_msgTypes[2]
×
185
                ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
×
186
                ms.StoreMessageInfo(mi)
×
187
        }
×
188
}
189

190
func (x *GetStateRequest) String() string {
×
191
        return protoimpl.X.MessageStringOf(x)
×
192
}
×
193

194
func (*GetStateRequest) ProtoMessage() {}
×
195

196
func (x *GetStateRequest) ProtoReflect() protoreflect.Message {
×
197
        mi := &file_stateservice_proto_msgTypes[2]
×
198
        if protoimpl.UnsafeEnabled && x != nil {
×
199
                ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
×
200
                if ms.LoadMessageInfo() == nil {
×
201
                        ms.StoreMessageInfo(mi)
×
202
                }
×
203
                return ms
×
204
        }
205
        return mi.MessageOf(x)
×
206
}
207

208
// Deprecated: Use GetStateRequest.ProtoReflect.Descriptor instead.
209
func (*GetStateRequest) Descriptor() ([]byte, []int) {
×
210
        return file_stateservice_proto_rawDescGZIP(), []int{2}
×
211
}
×
212

213
type GetStateResponse struct {
214
        state         protoimpl.MessageState
215
        sizeCache     protoimpl.SizeCache
216
        unknownFields protoimpl.UnknownFields
217

218
        State WalletState `protobuf:"varint,1,opt,name=state,proto3,enum=lnrpc.WalletState" json:"state,omitempty"`
219
}
220

221
func (x *GetStateResponse) Reset() {
×
222
        *x = GetStateResponse{}
×
223
        if protoimpl.UnsafeEnabled {
×
224
                mi := &file_stateservice_proto_msgTypes[3]
×
225
                ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
×
226
                ms.StoreMessageInfo(mi)
×
227
        }
×
228
}
229

230
func (x *GetStateResponse) String() string {
×
231
        return protoimpl.X.MessageStringOf(x)
×
232
}
×
233

234
func (*GetStateResponse) ProtoMessage() {}
×
235

236
func (x *GetStateResponse) ProtoReflect() protoreflect.Message {
×
237
        mi := &file_stateservice_proto_msgTypes[3]
×
238
        if protoimpl.UnsafeEnabled && x != nil {
×
239
                ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
×
240
                if ms.LoadMessageInfo() == nil {
×
241
                        ms.StoreMessageInfo(mi)
×
242
                }
×
243
                return ms
×
244
        }
245
        return mi.MessageOf(x)
×
246
}
247

248
// Deprecated: Use GetStateResponse.ProtoReflect.Descriptor instead.
249
func (*GetStateResponse) Descriptor() ([]byte, []int) {
×
250
        return file_stateservice_proto_rawDescGZIP(), []int{3}
×
251
}
×
252

253
func (x *GetStateResponse) GetState() WalletState {
×
254
        if x != nil {
×
255
                return x.State
×
256
        }
×
257
        return WalletState_NON_EXISTING
×
258
}
259

260
var File_stateservice_proto protoreflect.FileDescriptor
261

262
var file_stateservice_proto_rawDesc = []byte{
263
        0x0a, 0x12, 0x73, 0x74, 0x61, 0x74, 0x65, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x70,
264
        0x72, 0x6f, 0x74, 0x6f, 0x12, 0x05, 0x6c, 0x6e, 0x72, 0x70, 0x63, 0x22, 0x17, 0x0a, 0x15, 0x53,
265
        0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71,
266
        0x75, 0x65, 0x73, 0x74, 0x22, 0x42, 0x0a, 0x16, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62,
267
        0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x28,
268
        0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x12, 0x2e,
269
        0x6c, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x57, 0x61, 0x6c, 0x6c, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74,
270
        0x65, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x22, 0x11, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x53,
271
        0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x3c, 0x0a, 0x10, 0x47,
272
        0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12,
273
        0x28, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x12,
274
        0x2e, 0x6c, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x57, 0x61, 0x6c, 0x6c, 0x65, 0x74, 0x53, 0x74, 0x61,
275
        0x74, 0x65, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x2a, 0x73, 0x0a, 0x0b, 0x57, 0x61, 0x6c,
276
        0x6c, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x0c, 0x4e, 0x4f, 0x4e, 0x5f,
277
        0x45, 0x58, 0x49, 0x53, 0x54, 0x49, 0x4e, 0x47, 0x10, 0x00, 0x12, 0x0a, 0x0a, 0x06, 0x4c, 0x4f,
278
        0x43, 0x4b, 0x45, 0x44, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x55, 0x4e, 0x4c, 0x4f, 0x43, 0x4b,
279
        0x45, 0x44, 0x10, 0x02, 0x12, 0x0e, 0x0a, 0x0a, 0x52, 0x50, 0x43, 0x5f, 0x41, 0x43, 0x54, 0x49,
280
        0x56, 0x45, 0x10, 0x03, 0x12, 0x11, 0x0a, 0x0d, 0x53, 0x45, 0x52, 0x56, 0x45, 0x52, 0x5f, 0x41,
281
        0x43, 0x54, 0x49, 0x56, 0x45, 0x10, 0x04, 0x12, 0x15, 0x0a, 0x10, 0x57, 0x41, 0x49, 0x54, 0x49,
282
        0x4e, 0x47, 0x5f, 0x54, 0x4f, 0x5f, 0x53, 0x54, 0x41, 0x52, 0x54, 0x10, 0xff, 0x01, 0x32, 0x95,
283
        0x01, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x4f, 0x0a, 0x0e, 0x53, 0x75, 0x62, 0x73,
284
        0x63, 0x72, 0x69, 0x62, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1c, 0x2e, 0x6c, 0x6e, 0x72,
285
        0x70, 0x63, 0x2e, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x53, 0x74, 0x61, 0x74,
286
        0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x6c, 0x6e, 0x72, 0x70, 0x63,
287
        0x2e, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52,
288
        0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x30, 0x01, 0x12, 0x3b, 0x0a, 0x08, 0x47, 0x65, 0x74,
289
        0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x16, 0x2e, 0x6c, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65,
290
        0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e,
291
        0x6c, 0x6e, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65,
292
        0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x27, 0x5a, 0x25, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62,
293
        0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x6e, 0x69, 0x6e, 0x67, 0x6e, 0x65,
294
        0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x6c, 0x6e, 0x64, 0x2f, 0x6c, 0x6e, 0x72, 0x70, 0x63, 0x62,
295
        0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
296
}
297

298
var (
299
        file_stateservice_proto_rawDescOnce sync.Once
300
        file_stateservice_proto_rawDescData = file_stateservice_proto_rawDesc
301
)
302

303
func file_stateservice_proto_rawDescGZIP() []byte {
×
304
        file_stateservice_proto_rawDescOnce.Do(func() {
×
305
                file_stateservice_proto_rawDescData = protoimpl.X.CompressGZIP(file_stateservice_proto_rawDescData)
×
306
        })
×
307
        return file_stateservice_proto_rawDescData
×
308
}
309

310
var file_stateservice_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
311
var file_stateservice_proto_msgTypes = make([]protoimpl.MessageInfo, 4)
312
var file_stateservice_proto_goTypes = []interface{}{
313
        (WalletState)(0),               // 0: lnrpc.WalletState
314
        (*SubscribeStateRequest)(nil),  // 1: lnrpc.SubscribeStateRequest
315
        (*SubscribeStateResponse)(nil), // 2: lnrpc.SubscribeStateResponse
316
        (*GetStateRequest)(nil),        // 3: lnrpc.GetStateRequest
317
        (*GetStateResponse)(nil),       // 4: lnrpc.GetStateResponse
318
}
319
var file_stateservice_proto_depIdxs = []int32{
320
        0, // 0: lnrpc.SubscribeStateResponse.state:type_name -> lnrpc.WalletState
321
        0, // 1: lnrpc.GetStateResponse.state:type_name -> lnrpc.WalletState
322
        1, // 2: lnrpc.State.SubscribeState:input_type -> lnrpc.SubscribeStateRequest
323
        3, // 3: lnrpc.State.GetState:input_type -> lnrpc.GetStateRequest
324
        2, // 4: lnrpc.State.SubscribeState:output_type -> lnrpc.SubscribeStateResponse
325
        4, // 5: lnrpc.State.GetState:output_type -> lnrpc.GetStateResponse
326
        4, // [4:6] is the sub-list for method output_type
327
        2, // [2:4] is the sub-list for method input_type
328
        2, // [2:2] is the sub-list for extension type_name
329
        2, // [2:2] is the sub-list for extension extendee
330
        0, // [0:2] is the sub-list for field type_name
331
}
332

333
func init() { file_stateservice_proto_init() }
14✔
334
func file_stateservice_proto_init() {
14✔
335
        if File_stateservice_proto != nil {
14✔
336
                return
×
337
        }
×
338
        if !protoimpl.UnsafeEnabled {
14✔
339
                file_stateservice_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
×
340
                        switch v := v.(*SubscribeStateRequest); i {
×
341
                        case 0:
×
342
                                return &v.state
×
343
                        case 1:
×
344
                                return &v.sizeCache
×
345
                        case 2:
×
346
                                return &v.unknownFields
×
347
                        default:
×
348
                                return nil
×
349
                        }
350
                }
351
                file_stateservice_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
×
352
                        switch v := v.(*SubscribeStateResponse); i {
×
353
                        case 0:
×
354
                                return &v.state
×
355
                        case 1:
×
356
                                return &v.sizeCache
×
357
                        case 2:
×
358
                                return &v.unknownFields
×
359
                        default:
×
360
                                return nil
×
361
                        }
362
                }
363
                file_stateservice_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
×
364
                        switch v := v.(*GetStateRequest); i {
×
365
                        case 0:
×
366
                                return &v.state
×
367
                        case 1:
×
368
                                return &v.sizeCache
×
369
                        case 2:
×
370
                                return &v.unknownFields
×
371
                        default:
×
372
                                return nil
×
373
                        }
374
                }
375
                file_stateservice_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
×
376
                        switch v := v.(*GetStateResponse); i {
×
377
                        case 0:
×
378
                                return &v.state
×
379
                        case 1:
×
380
                                return &v.sizeCache
×
381
                        case 2:
×
382
                                return &v.unknownFields
×
383
                        default:
×
384
                                return nil
×
385
                        }
386
                }
387
        }
388
        type x struct{}
14✔
389
        out := protoimpl.TypeBuilder{
14✔
390
                File: protoimpl.DescBuilder{
14✔
391
                        GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
14✔
392
                        RawDescriptor: file_stateservice_proto_rawDesc,
14✔
393
                        NumEnums:      1,
14✔
394
                        NumMessages:   4,
14✔
395
                        NumExtensions: 0,
14✔
396
                        NumServices:   1,
14✔
397
                },
14✔
398
                GoTypes:           file_stateservice_proto_goTypes,
14✔
399
                DependencyIndexes: file_stateservice_proto_depIdxs,
14✔
400
                EnumInfos:         file_stateservice_proto_enumTypes,
14✔
401
                MessageInfos:      file_stateservice_proto_msgTypes,
14✔
402
        }.Build()
14✔
403
        File_stateservice_proto = out.File
14✔
404
        file_stateservice_proto_rawDesc = nil
14✔
405
        file_stateservice_proto_goTypes = nil
14✔
406
        file_stateservice_proto_depIdxs = nil
14✔
407
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc