JLChen
2021-10-28 e96683081abd5c1a94608dd33d092d8f45371cd6
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
//
//  Copyright (c) 2015年 Dahua. All rights reserved.
//
 
#import "LCDevice.h"
 
#pragma mark - 设备基类
 
@implementation LCBasicDevice
 
@end
 
#pragma mark - Device
 
@implementation LCDevice
 
- (instancetype)init
{
    if (self = [super init]) {
        self.apList = @[].mutableCopy;
        self.channelList = @[].mutableCopy;
    }
    return self;
}
 
- (id)copyWithZone:(NSZone *)zone {
    LCDevice *device =[LCDevice new];
    
    device.deviceID = self.deviceID;
    device.isOnline = self.isOnline;
    device.status = self.status;
    device.channelNum = self.channelNum;
    device.baseline = self.baseline;
    device.deviceModel = self.deviceModel;
    device.deviceCatalog = self.deviceCatalog;
    device.deviceBrand = self.deviceBrand;
    device.deviceVersion = self.deviceVersion;
    device.deviceName = self.deviceName;
    device.dmsIP = self.dmsIP;
    device.ability = self.ability;
    device.isNeedUpdate = self.isNeedUpdate;
    device.isSharedTo = self.isSharedTo;
    device.isSharedFrom = self.isSharedFrom;
    device.shareState = self.shareState;
    device.beShareToState = self.beShareToState;
    device.ownerUsername = self.ownerUsername;
    device.ownerNickname = self.ownerNickname;
    device.urlShareUser = self.urlShareUser;
    device.urlDeviceLogo = self.urlDeviceLogo;
    device.urlPano = self.urlPano;
    device.channelList = [self.channelList copy];
    device.apList = [self.apList copy];
    device.shareTime = self.shareTime;
    device.deviceCategory = self.deviceCategory;
    device.zbList = [self.zbList copy];
    device.encryptMode = self.encryptMode;
    device.agEnableState = self.agEnableState;
    device.paasFlag = self.paasFlag;
    device.deviceUsername = self.deviceUsername;
    device.devicePassword = self.devicePassword;
    device.airDetectionList = self.airDetectionList;
 
    return device;
}
 
- (void)encodeWithCoder:(NSCoder *)aCoder {
    [aCoder encodeObject:self.deviceID forKey:@"deviceID"];
    [aCoder encodeBool:self.isOnline forKey:@"isOnline"];
    [aCoder encodeInt:self.status forKey:@"status"];
    [aCoder encodeInt:self.channelNum forKey:@"channelNum"];
    [aCoder encodeObject:self.baseline forKey:@"baseline"];
    [aCoder encodeObject:self.deviceModel forKey:@"deviceModel"];
    [aCoder encodeObject:self.deviceCatalog forKey:@"deviceCatalog"];
    [aCoder encodeObject:self.deviceBrand forKey:@"deviceBrand"];
    [aCoder encodeObject:self.deviceVersion forKey:@"deviceVersion"];
    [aCoder encodeObject:self.deviceName forKey:@"deviceName"];
    [aCoder encodeObject:self.dmsIP forKey:@"dmsIP"];
    [aCoder encodeObject:self.ability forKey:@"ability"];
    [aCoder encodeBool:self.isNeedUpdate forKey:@"isNeedUpdate"];
    [aCoder encodeBool:self.isSharedTo forKey:@"isSharedTo"];
    [aCoder encodeBool:self.isSharedFrom forKey:@"isSharedFrom"];
    [aCoder encodeInt:self.shareState forKey:@"shareState"];
    [aCoder encodeInt:self.beShareToState forKey:@"beShareToState"];
    [aCoder encodeObject:self.ownerUsername forKey:@"ownerUsername"];
    [aCoder encodeObject:self.ownerNickname forKey:@"ownerNickname"];
    [aCoder encodeObject:self.urlShareUser forKey:@"urlShareUser"];
    [aCoder encodeObject:self.urlDeviceLogo forKey:@"urlDeviceLogo"];
    [aCoder encodeObject:self.urlPano forKey:@"urlPano"];
    [aCoder encodeObject:self.channelList forKey:@"channelList"];
    [aCoder encodeObject:self.apList forKey:@"apList"];
    [aCoder encodeInt64:self.shareTime forKey:@"shareTime"];
    [aCoder encodeObject:self.deviceCategory forKey:@"deviceCategory"];
    [aCoder encodeObject:self.zbList forKey:@"zbList"];
    [aCoder encodeInt:self.encryptMode forKey:@"encryptMode"];
    [aCoder encodeInt:self.agEnableState forKey:@"agEnableState"];
    [aCoder encodeInt:self.paasFlag forKey:@"passFlag"];
    [aCoder encodeObject:self.deviceUsername forKey:@"deviceUsername"];
    [aCoder encodeObject:self.devicePassword forKey:@"devicePassword"];
    [aCoder encodeObject:self.airDetectionList forKey:@"airDetectionList"];
 
}
 
- (instancetype)initWithCoder:(NSCoder *)aDecoder {
    self = [super init];
    if (self)
    {
        self.deviceID = [aDecoder decodeObjectForKey:@"deviceID"];
        self.isOnline = [aDecoder decodeBoolForKey:@"isOnline"];
        self.status = [aDecoder decodeIntForKey:@"status"];
        self.channelNum = [aDecoder decodeIntForKey:@"channelNum"];
        self.baseline = [aDecoder decodeObjectForKey:@"baseline"];
        self.deviceModel = [aDecoder decodeObjectForKey:@"deviceModel"];
        self.deviceCatalog = [aDecoder decodeObjectForKey:@"deviceCatalog"];
        self.deviceBrand = [aDecoder decodeObjectForKey:@"deviceBrand"];
        self.deviceVersion = [aDecoder decodeObjectForKey:@"deviceVersion"];
        self.deviceName = [aDecoder decodeObjectForKey:@"deviceName"];
        self.dmsIP = [aDecoder decodeObjectForKey:@"dmsIP"];
        self.ability = [aDecoder decodeObjectForKey:@"ability"];
        self.isNeedUpdate = [aDecoder decodeBoolForKey:@"isNeedUpdate"];
        self.isSharedTo = [aDecoder decodeBoolForKey:@"isSharedTo"];
        self.isSharedFrom = [aDecoder decodeBoolForKey:@"isSharedFrom"];
        self.shareState = [aDecoder decodeIntForKey:@"shareState"];
        self.beShareToState = [aDecoder decodeIntForKey:@"beShareToState"];
        self.ownerUsername = [aDecoder decodeObjectForKey:@"ownerUsername"];
        self.ownerNickname = [aDecoder decodeObjectForKey:@"ownerNickname"];
        self.urlShareUser = [aDecoder decodeObjectForKey:@"urlShareUser"];
        self.urlDeviceLogo = [aDecoder decodeObjectForKey:@"urlDeviceLogo"];
        self.urlPano = [aDecoder decodeObjectForKey:@"urlPano"];
        self.channelList = [aDecoder decodeObjectForKey:@"channelList"];
        self.apList = [aDecoder decodeObjectForKey:@"apList"];
        self.shareTime = [aDecoder decodeInt64ForKey:@"shareTime"];
        self.deviceCategory = [aDecoder decodeObjectForKey:@"deviceCategory"];
        self.zbList = [aDecoder decodeObjectForKey:@"zbList"];
        self.encryptMode = [aDecoder decodeIntForKey:@"encryptMode"];
        self.agEnableState = [aDecoder decodeIntForKey:@"agEnableState"];
        self.paasFlag = [aDecoder decodeIntForKey:@"passFlag"];
        self.deviceUsername = [aDecoder decodeObjectForKey:@"deviceUsername"];
        self.devicePassword = [aDecoder decodeObjectForKey:@"devicePassword"];
        self.airDetectionList = [aDecoder decodeObjectForKey:@"airDetectionList"];
 
    }
    return self;
}
 
@end
#pragma mark - LCAirDetection
 
@implementation LCAirDetection
 
- (id)copyWithZone:(NSZone *)zone {
    LCAirDetection *airDetec = [LCAirDetection new];
    airDetec.type = self.type;
    airDetec.value = self.value;
    airDetec.qualityType = self.qualityType;
    airDetec.unit = self.unit;
    return airDetec;
}
 
- (void)encodeWithCoder:(NSCoder *)aCoder {
    
    [aCoder encodeObject:self.type forKey:@"type"];
    [aCoder encodeObject:self.value forKey:@"value"];
    [aCoder encodeObject:self.qualityType forKey:@"qualityType"];
    [aCoder encodeObject:self.unit forKey:@"unit"];
}
 
- (instancetype)initWithCoder:(NSCoder *)aDecoder {
    self = [super init];
    if (self)
    {
        self.type = [aDecoder decodeObjectForKey:@"type"];
        self.value = [aDecoder decodeObjectForKey:@"value"];
        self.qualityType = [aDecoder decodeObjectForKey:@"qualityType"];
        self.unit = [aDecoder decodeObjectForKey:@"unit"];
    }
    return self;
}
 
@end
 
 
@implementation LCAirDetectReportData
- (id)copyWithZone:(NSZone *)zone {
    LCAirDetectReportData *airDetec = [LCAirDetectReportData new];
    airDetec.utcTime = self.utcTime;
    airDetec.value = self.value;
    airDetec.minValue = self.minValue;
    airDetec.maxValue = self.maxValue;
    airDetec.qualityType = self.qualityType;
    airDetec.type = self.type;
    
    return airDetec;
}
 
- (void)encodeWithCoder:(NSCoder *)aCoder {
    
    [aCoder encodeObject:self.utcTime forKey:@"utcTime"];
    [aCoder encodeObject:self.value forKey:@"value"];
    [aCoder encodeObject:self.minValue forKey:@"minValue"];
    [aCoder encodeObject:self.maxValue forKey:@"maxValue"];
    [aCoder encodeObject:self.qualityType forKey:@"qualityType"];
    [aCoder encodeObject:self.type forKey:@"type"];
}
 
- (instancetype)initWithCoder:(NSCoder *)aDecoder {
    self = [super init];
    if (self)
    {
        self.utcTime = [aDecoder decodeObjectForKey:@"utcTime"];
        self.value = [aDecoder decodeObjectForKey:@"value"];
        self.minValue = [aDecoder decodeObjectForKey:@"minValue"];
        self.maxValue = [aDecoder decodeObjectForKey:@"maxValue"];
        self.qualityType = [aDecoder decodeObjectForKey:@"qualityType"];
        self.type = [aDecoder decodeObjectForKey:@"type"];
        
    }
    return self;
}
@end
 
@implementation LCAirDetectAllData
 
- (id)copyWithZone:(NSZone *)zone {
    LCAirDetectAllData *airDetec = [LCAirDetectAllData new];
    airDetec.type = self.type;
    airDetec.minRange = self.minRange;
    airDetec.maxRange = self.maxRange;
    airDetec.percision = self.percision;
    airDetec.unit = self.unit;
    airDetec.mode = self.mode;
    airDetec.space = [self.space copy];
    
    return airDetec;
}
 
- (void)encodeWithCoder:(NSCoder *)aCoder {
    
    [aCoder encodeObject:self.type forKey:@"type"];
    [aCoder encodeObject:self.minRange forKey:@"minRange"];
    [aCoder encodeObject:self.maxRange forKey:@"maxRange"];
    [aCoder encodeObject:self.percision forKey:@"percision"];
    [aCoder encodeObject:self.unit forKey:@"unit"];
    [aCoder encodeObject:self.mode forKey:@"mode"];
    [aCoder encodeObject:self.space forKey:@"space"];
}
 
- (instancetype)initWithCoder:(NSCoder *)aDecoder {
    self = [super init];
    if (self)
    {
        self.type = [aDecoder decodeObjectForKey:@"type"];
        self.minRange = [aDecoder decodeObjectForKey:@"minRange"];
        self.maxRange = [aDecoder decodeObjectForKey:@"maxRange"];
        self.percision = [aDecoder decodeObjectForKey:@"percision"];
        self.unit = [aDecoder decodeObjectForKey:@"unit"];
        self.mode = [aDecoder decodeObjectForKey:@"mode"];
        self.space = [aDecoder decodeObjectForKey:@"space"];
    }
    return self;
}
@end
 
 
#pragma mark - Channel
 
@implementation LCChannel
 
- (instancetype)init {
    
    if (self = [super init]) {
        self.dh_userInfo = [NSMutableDictionary new];
    }
    
    return self;
}
 
- (id)copyWithZone:(NSZone *)zone {
    LCChannel *channel = [LCChannel new];
    
    channel.picurl = self.picurl;
    channel.channelID = self.channelID;
    channel.channelName = self.channelName;
    channel.deviceID = self.deviceID;
    channel.functions = self.functions;
    channel.channelAbility = self.channelAbility;
    channel.isSharedTo = self.isSharedTo;
    channel.beShareToState = self.beShareToState;
    channel.isOnline = self.isOnline;
    channel.sdCardStatus = self.sdCardStatus;
    channel.csStatus = self.csStatus;
    channel.csExpireTime = self.csExpireTime;
    channel.alarmStatus = self.alarmStatus;
    channel.remindStatus = self.remindStatus;
    channel.publicExpire = self.publicExpire;
    channel.publicToken = self.publicToken;
    channel.lastOffLineTime = self.lastOffLineTime;
    channel.isFrameReversed = self.isFrameReversed;
    channel.csType = self.csType;
    channel.lc_shareState = self.lc_shareState;
    channel.encryptInfo = self.encryptInfo;
    channel.isCloseCamera = self.isCloseCamera;
    channel.dh_userInfo = self.dh_userInfo;
    return channel;
}
 
- (void)encodeWithCoder:(NSCoder *)aCoder {
    [aCoder encodeObject:self.picurl forKey:@"picurl"];
    [aCoder encodeInt:self.channelID forKey:@"channelID"];
    [aCoder encodeObject:self.channelName forKey:@"channelName"];
    [aCoder encodeObject:self.lastOffLineTime forKey:@"lastOffLineTime"];
    [aCoder encodeObject:self.csExpireTime forKey:@"csExpireTime"];
    [aCoder encodeObject:self.deviceID forKey:@"deviceID"];
    [aCoder encodeObject:self.functions forKey:@"functions"];
    [aCoder encodeObject:self.channelAbility forKey:@"channelAbility"];
    [aCoder encodeBool:self.isSharedTo forKey:@"isSharedTo"];
    [aCoder encodeInt:self.beShareToState forKey:@"beShareToState"];
    [aCoder encodeBool:self.isOnline forKey:@"isOnline"];
    [aCoder encodeInt:self.sdCardStatus forKey:@"sdCardStatus"];
    [aCoder encodeInt:self.csStatus forKey:@"csStatus"];
    [aCoder encodeInt:self.alarmStatus forKey:@"alarmStatus"];
    [aCoder encodeInt:self.remindStatus forKey:@"remindStatus"];
    [aCoder encodeInt64:self.publicExpire forKey:@"publicExpire"];
    [aCoder encodeObject:self.publicToken forKey:@"publicToken"];
    [aCoder encodeBool:self.isFrameReversed forKey:@"isFrameReversed"];
    [aCoder encodeInt:self.csType forKey:@"csType"];
    [aCoder encodeInt:self.lc_shareState forKey:@"lc_shareState"];
    [aCoder encodeObject:self.encryptInfo forKey:@"encryptInfo"];
    [aCoder encodeInt:self.isCloseCamera forKey:@"isCloseCamera"];
    [aCoder encodeObject:self.dh_userInfo forKey:@"dh_userInfo"];
}
 
- (instancetype)initWithCoder:(NSCoder *)aDecoder {
    self = [super init];
    if (self)
    {
        self.picurl = [aDecoder decodeObjectForKey:@"picurl"];
        self.channelID = [aDecoder decodeIntForKey:@"channelID"];
        self.channelName = [aDecoder decodeObjectForKey:@"channelName"];
        self.deviceID = [aDecoder decodeObjectForKey:@"deviceID"];
        self.functions = [aDecoder decodeObjectForKey:@"functions"];
        self.channelAbility = [aDecoder decodeObjectForKey:@"channelAbility"];
        self.isSharedTo = [aDecoder decodeBoolForKey:@"isSharedTo"];
        self.beShareToState = [aDecoder decodeIntForKey:@"beShareToState"];
        self.isOnline = [aDecoder decodeBoolForKey:@"isOnline"];
        self.sdCardStatus = [aDecoder decodeIntForKey:@"sdCardStatus"];
        self.csStatus = [aDecoder decodeIntForKey:@"csStatus"];
        self.csExpireTime = [aDecoder decodeObjectForKey:@"publicExpire"];
        self.alarmStatus = [aDecoder decodeIntForKey:@"alarmStatus"];
        self.remindStatus = [aDecoder decodeIntForKey:@"remindStatus"];
        self.publicExpire = [aDecoder decodeInt64ForKey:@"publicExpire"];
        self.publicToken = [aDecoder decodeObjectForKey:@"publicToken"];
        self.isFrameReversed = [aDecoder decodeBoolForKey:@"isFrameReversed"];
        self.csType = [aDecoder decodeIntForKey:@"csType"];
        self.lc_shareState = [aDecoder decodeIntForKey:@"lc_shareState"];
        self.encryptInfo = [aDecoder decodeObjectForKey:@"encryptInfo"];
        self.isCloseCamera = [aDecoder decodeIntForKey:@"isCloseCamera"];
        self.dh_userInfo = [aDecoder decodeObjectForKey:@"dh_userInfo"];
        self.lastOffLineTime = [aDecoder decodeObjectForKey:@"lastOffLineTime"];
    }
    return self;
}
 
- (id)lc_generateDHChannel {
    //在上层扩展中实现功能
    return nil;
}
 
#pragma mark - KVC
- (id)valueForUndefinedKey:(NSString *)key {
    return nil;
}
 
- (void)setValue:(id)value forUndefinedKey:(NSString *)key {
    
}
 
@end
 
#pragma mark - Other
 
@implementation LCDeviceShareInfo
 
@end
 
@implementation LCDeviceUpdateVersionList
 
@synthesize description, deviceId, version, url;
 
@end
 
//@implementation LCDeviceUpgradeInfo
//
//@synthesize status, version, percent;
//
//@end
 
@implementation LCDeviceWifiInfo
 
@synthesize enabled, deviceID;
 
@end
 
@implementation LCDeviceWifiStatus
 
@synthesize auth, SSID, BSSID, linkStatus, intensity;
 
@end
 
 
@implementation LCZBDevicePowerConsumptionMessage
@end
 
@implementation LCDevicePowerConsumptionMessage
@end
 
@implementation LCUserPowerConsumptionMessage
@end
 
@implementation LCChannelAlarmPlan
 
@synthesize channelID;
 
@end
 
@implementation LCAlarmRule
 
@synthesize period, beginTime, endTime, enable, bPlus;
 
- (id)copyWithZone:(NSZone *)zone {
    LCAlarmRule *rule = [[self class] allocWithZone:zone];
    rule.period = self.period;
    rule.beginTime = self.beginTime;
    rule.endTime = self.endTime;
    rule.enable = self.enable;
    rule.bPlus = self.bPlus;
    return rule;
}
 
- (id)mutableCopyWithZone:(NSZone *)zone {
    LCAlarmRule *rule = [[self class] allocWithZone:zone];
    rule.period = self.period;
    rule.beginTime = self.beginTime;
    rule.endTime = self.endTime;
    rule.enable = self.enable;
    rule.bPlus = self.bPlus;
    return rule;
}
 
@end
 
@implementation LCAlarmMode
 
@end
 
@implementation DeviceModelInfo
 
@end
@implementation PublicLiveInfo
 
@end
@implementation PublicLiveStream
 
@end
 
@implementation VideoParameter
 
@end
 
@implementation LCPermission
 
@end
 
@implementation LCWifiAutoPairInfo
 
@end
 
@implementation LCDeviceSharer
 
@end
 
@implementation LCWeatherInfo
 
@end
 
@implementation LCMotionDetectRulesInfo
 
@end
 
@implementation LCUnbindDeviceApplyListInfo
 
- (id)copyWithZone:(NSZone *)zone {
    LCUnbindDeviceApplyListInfo *applyInfo =[LCUnbindDeviceApplyListInfo new];
    
    applyInfo.deviceCode = self.deviceCode;
    applyInfo.applyID = self.applyID;
    applyInfo.status = self.status;
    applyInfo.startTime = self.startTime;
    applyInfo.updateTime = self.updateTime;
    
    return applyInfo;
}
 
- (void)encodeWithCoder:(NSCoder *)aCoder {
    [aCoder encodeObject:self.deviceCode forKey:@"deviceCode"];
    [aCoder encodeInt64:self.applyID forKey:@"applyID"];
    [aCoder encodeInt:self.status forKey:@"status"];
    [aCoder encodeInt64:self.startTime forKey:@"startTime"];
    [aCoder encodeInt64:self.updateTime forKey:@"updateTime"];
}
 
- (instancetype)initWithCoder:(NSCoder *)aDecoder {
    self = [super init];
    if (self)
    {
        self.deviceCode = [aDecoder decodeObjectForKey:@"deviceCode"];
        self.applyID = [aDecoder decodeInt64ForKey:@"applyID"];
        self.status = [aDecoder decodeIntForKey:@"status"];
        self.startTime = [aDecoder decodeInt64ForKey:@"startTime"];
        self.updateTime = [aDecoder decodeInt64ForKey:@"updateTime"];
    }
    return self;
}
 
 
@end
 
@implementation LCUnbindDeviceApplyInfo
 
 
@end
 
@implementation LCUnbindDeviceApplicationInfo
 
 
@end
 
@implementation LCGetDevModelInfo
 
- (void)encodeWithCoder:(NSCoder *)aCoder {
    [aCoder encodeInt64:self.modelId forKey:@"modelId"];
    [aCoder encodeObject:self.modelName forKey:@"modelName"];
    [aCoder encodeObject:self.deviceModel forKey:@"deviceModel"];
    [aCoder encodeObject:self.logoUrl forKey:@"logoUrl"];
}
 
- (instancetype)initWithCoder:(NSCoder *)aDecoder {
    self = [super init];
    if (self)
    {
        self.modelId = [aDecoder decodeInt64ForKey:@"modelId"];
        self.modelName = [aDecoder decodeObjectForKey:@"modelName"];
        self.deviceModel = [aDecoder decodeObjectForKey:@"deviceModel"];
        self.logoUrl = [aDecoder decodeObjectForKey:@"logoUrl"];
    }
    return self;
}
 
@end
 
@implementation LCGetDevModelInfoList
- (void)encodeWithCoder:(NSCoder *)aCoder {
    [aCoder encodeInt64:self.timeStamp forKey:@"timeStamp"];
    [aCoder encodeObject:self.modelsArray forKey:@"modelsArray"];
}
 
- (instancetype)initWithCoder:(NSCoder *)aDecoder {
    self = [super init];
    if (self)
    {
        self.timeStamp = [aDecoder decodeInt64ForKey:@"timeStamp"];
        self.modelsArray = [aDecoder decodeObjectForKey:@"modelsArray"];
    }
    return self;
}
 
@end
 
 
@implementation LCPanoUrlInfo
 
@end
 
@implementation LCDeviceCuriseInfo: NSObject
 
@end
 
@implementation LCDeviceCollectionInfo: NSObject
 
@end
 
@implementation LCDeviceCuriseConfig: NSObject
@end
 
@implementation LCShareStrategy: NSObject
@end
 
@implementation LCDevShareStrategy: NSObject
@end
 
@implementation LCReportStatisticData: NSObject
@end
 
@implementation LCReportStatisticNode :NSObject
@end
 
@implementation LCReportStrategy:NSObject
@end
 
@implementation LCStrategyDetail:NSObject
@end
 
@implementation LCOneDayStrategy:NSObject
@end
 
@implementation LCDevCloudStrategy:NSObject
@end
 
@implementation LCSnapKeyInfo:NSObject
@end
 
@implementation LCKeyEffectPeriod:NSObject
@end
 
@implementation LCSecretKeyInfo:NSObject
@end
 
@implementation LCHoveringAlarmInfo:NSObject
@end
 
@implementation LCDevicePowerInfo:NSObject
@end
 
@implementation LCDeviceFlushCellInfo:NSObject
@end
 
@implementation LCDeviceFlushInfo:NSObject
@end
 
@implementation LCDeviceGearInfo
@end
 
@implementation LCDeviceMotionDetectInfo
@end
 
@implementation DHQuerySirenStateResultObject
@end
 
@implementation LCDeviceZoomFocusInfo
@end
 
@implementation LCDeviceWifiStateFromServer
@end
 
@implementation LCDeviceWifiForRemoteDevice
@end
 
@implementation LCDeviceBatteryElectric
@end
 
@implementation LCDeviceRemoteDeviceElectric
@end
 
@implementation LCMotionDetectParamInfo
@end
 
@implementation DHSirenTimeInfo
@end
 
//MARK: 设备添加融合
 
@implementation DHUserDeviceBindInfo
 
- (instancetype)init {
    if (self = [super init]) {
        self.deviceExist = @"";
        self.bindStatus = @"";
        self.userAccount = @"";
        self.wifiConfigMode = @"";
        self.wifiTransferMode = @"";
        self.status = @"";
        self.deviceModel = @"";
        self.ability = @"";
        self.bindStatus = @"";
        self.bindStatus = @"";
        self.catalog = @"";
        self.accessType = @"";
        self.brand = @"";
        self.family = @"";
        self.modelName = @"";
        self.type = @"";
        self.deviceType = @"";
    }
    return self;
}
 
- (BOOL)isDeviceExist {
    return [_deviceExist caseInsensitiveCompare:@"exist"] == NSOrderedSame;
}
 
+ (NSDictionary *)mj_replacedKeyFromPropertyName {
    return @{@"deviceModel":@"deviceCodeModel",@"surpport":@"support",@"modelName":@"deviceModelName"};
}
 
@end
 
@implementation DHBindDeviceInfo
 
@end
 
@implementation DHBindDeviceSuccess
 
@end
 
@implementation DHDeviceTimeZone
 
- (NSInteger)areaIndex {
    return _area.integerValue;
}
 
- (NSInteger)timeZoneIndex {
    return _timeZone.integerValue;
}
 
+ (NSString *)dstTimeFormat {
    return @"MM-dd HH:mm:ss";
}
 
@end
 
@implementation DHDeviceTimeZoneQueryInfo
 
-(BOOL)isDayModel
{
    if ([self.mode isEqualToString:@"day"]) {
        return YES;
    }
    else
    {
        return NO;
    }
}
 
-(BOOL)isWeekModel
{
    if ([self.mode isEqualToString:@"week"]) {
        return YES;
    }
    else
    {
        return NO;
    }
}
 
@end
 
@implementation LCSearchLightWorkMode
 
@end
 
@implementation LCSearchLightModel
 
@end
 
@implementation LCLightTimeModel
 
@end
 
@implementation LCLightTimeWorkMode
 
@end
 
@implementation LCSirenContentModel
 
@end
 
@implementation LCSirenChannelModel
@end
 
@implementation LCSirenResponseModel
@end
 
@implementation LCBellContentModel
@end
 
@implementation DHIntelligentlockNotesInfo
 
- (NSString *)localKeyType {
    if ([self.keyType isEqualToString:@"card"]) {
        return @"卡";
    } else if ([self.keyType isEqualToString:@"fingerPrint"]) {
        return @"指纹";
    } else if ([self.keyType isEqualToString:@"password"]) {
        return @"密码";
    } else if ([self.keyType isEqualToString:@"face"]) {
        return @"人脸";
    }
    return self.keyType;
}
 
- (NSString *)localOperateType {
    if ([self.operateType isEqualToString:@"add"]) {
        return @"用户新增";
    } else if ([self.operateType isEqualToString:@"delete"]) {
        return @"用户删除";
    } else if ([self.operateType isEqualToString:@"deleteAll"]) {
        return @"全部删除";
    } else if ([self.operateType isEqualToString:@"modify"]) {
        return @"用户修改";
    } else if ([self.operateType isEqualToString:@"login"]) {
        return @"登录";
    } else {
        return @"用户新增";
    }
}
 
@end
 
@implementation NVMMode
@end
 
@implementation NVMChannelMode
@end