-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.sol
More file actions
1770 lines (1468 loc) · 51.6 KB
/
index.sol
File metadata and controls
1770 lines (1468 loc) · 51.6 KB
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
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// SPDX-License-Identifier: MIT
pragma solidity ^0.8;
/*
**************************************************************************************
**************************************************************************************
*/
contract Election {
struct Candidate {
uint256 id;
string name;
uint256 voteCount;
string details;
}
struct Voterss {
uint256 id;
string name;
uint256 age;
bool voted;
}
mapping(uint256 => Candidate) public candidates;
mapping(address => Voterss) public voters;
uint256 public candidatesCount;
uint256 public votersCount;
string candidate;
event votedEvent(uint256 indexed _candidateId);
function addCandidate(
uint256 _candidateId,
string memory _name,
string memory _details
) public {
candidatesCount++;
candidates[_candidateId] = Candidate(_candidateId, _name, 0, _details);
}
function addVoter(
uint256 _voterId,
string memory _name,
uint256 _age
) public {
votersCount++;
voters[msg.sender] = Voterss(_voterId, _name, _age, false);
}
function vote(uint256 _candidateId) public {
require(
_candidateId == candidates[_candidateId].id,
"you"
);
require(
!voters[msg.sender].voted,
"you have already voted"
);
require(voters[msg.sender].age >= 18, "you have lowest age");
candidates[_candidateId].voteCount++;
voters[msg.sender].voted = true;
emit votedEvent(_candidateId);
}
}
/*
imuttable in solidity
immutabity is used in that time when we want that the value is assign 1 time and it can not be changer
==> it have less cost than constant
==> the values must be assign,either in constructer level or either inline level
==> the immutable keyword is used
*/
contract immutableContract {
address public constant add2 = address(1);
address public immutable add3;
constructor(address _address) {
add3 = _address;
}
}
/*
**************************************************************************************
**************************************************************************************
*/
/*
how to send ether from one contract to another
OR
how to send ether from contract to other etherium address
3 ways to do this ==> send() call() transfer()
1)send
used for sended ether
==> send function will return bool value (true/false)
==> its is used in rare case
==> if we used it,so we can apply the reqiure function to revert the gas fees and also revert the changes which is
done in state varibles if it fail.
Limitation:
==> it have limit 2300 gas fees to perform operation if gas fees is greater than 2300 then it will return false
and show this kind of error : out of gas.
==> if the transiction is failed, then it will not revert the gas fees
syntex:
address ==>this will be payable receiver address
address.send(value);
example:
bool returnBool = recieveAddress.send(1 ether);
require(returnBool, "not sended");
*/
contract sendEitherContract {
address payable public recieveAddress =
payable(0x4B20993Bc481177ec7E8f571ceCaE8A9e22C02db);
// in this we can sended ether
function SendEither() public payable{
bool returnBool = recieveAddress.send(1 ether);
require(returnBool, "not sended");
}
// in this we can see the ether
function veiwEther() public view returns (uint256) {
return address(this).balance;
}
receive() external payable {}
}
/*
1)transfer
used for sended ether
==> transfer function will not return values
==> we cannot used the require function because it revert all the changes and gas fees if it fail automitically.
==> it have limit 2300 gas fees to perform operation if gas fees is greater than 2300,it will revert it.
syntex:
recieveAddress.send(1 ether);
*/
contract transferEitherContract {
address payable public recieveAddress =
payable(0x4B20993Bc481177ec7E8f571ceCaE8A9e22C02db);
// in this we can sended ether
function TransferEither() public payable {
recieveAddress.transfer(1 ether);
}
// in this we can see the ether
function veiwEther() public view returns (uint256) {
return address(this).balance;
}
receive() external payable {}
}
/*
1)call
used for sended either
==> call function will return 2 values
bool and data(hexadecimal format)
==> we can decide the gas limits by perform operation.
limitation:
==> we can used the require function to revert the transiction and gas fees
syntex:
(bool sent,) = recieverAddress.call{
val:________,
gas:________,
}(" ");
require(sent, "not sended");
if we can not declare the gas limit,then by default remixId gas limit is applaid which are 3000000
*/
contract transferEitherContract {
address payable public recieveAddress =
payable(0x4B20993Bc481177ec7E8f571ceCaE8A9e22C02db);
// in this we can sended ether
function callEither() public payable {
// return 2 values but in here we can catch one value
(bool sent, ) = recieveAddress.call{value: 1 ether}("");
require(sent, "not sended");
}
// in this we can see the ether
function veiwEther() public view returns (uint256) {
return address(this).balance;
}
receive() external payable {}
}
// how we send either by providing dynamically address as input
contract AllMethodContract {
// payable ==> the function will able to send and recieve ether
//address payable _address ==> convert the address type into payable
// msg.value ==> store the value which is located in remix id(deploy and run transiction level)
event log(uint256 value);
function sendEither(address payable _address) public payable {
// it will check that the ether is giong in this way or not
emit log(msg.value);
// msg.value will recieve dynamically either value and we convert it into payable
bool sent = _address.send(msg.value);
require(sent, "not sended");
}
// call function
function callEither(address payable _address) public payable {
// it will check that the ether is giong in this way or not
emit log(msg.value);
// msg.value will recieve dynamically either value and we convert it into payable
(bool sent, ) = _address.call{value: msg.value}("");
require(sent, "not sended");
}
// transsfer function
function TransferEither(address payable _address) public payable {
// it will check that the ether is giong in this way or not
emit log(msg.value);
_address.transfer(msg.value);
}
// in this we can see the ether
function veiwEther() public view returns (uint256) {
return address(this).balance;
}
receive() external payable {}
}
// how to recieve contract eth which is sended by other contract
// copy the contract address and paste in that contratc who send eth
contract SendEthContractToContract {
// in this we can see the ether
function veiwEther() public view returns (uint256) {
return address(this).balance;
}
receive() external payable {}
}
/*
**************************************************************************************
**************************************************************************************
*/
/*
fallback and recieve function
1)Fallback:
==> fallback excute in that time when we call function and the function is not available
==> we can make its visibilty external
==> it have no name
==> we can not pass any arguments in there
==> not return anything
==> it can be define one time per contract
==>its main use is directly send the eth to contract.
note:
it gives two things.
data(bytes format data) and either
==> we marked as payable
syntex:
fallback() external payable {}
2)recive:
All thing have same but there are little difference which are given
==>it will take only either
==>and its is mendatory payable the recieve function
note:
if we send data(hexadecimal format) then it will show that error
==>'Fallback' function is not defined
syntex:
receive() external payable {}
*/
/*
scenario:
if there have both fallback,recive function used within contract
==>if we send only ether,so it will be accepted by recieve function.
==>if we send data and ether combine,so it will be accepted by fallback function
*/
contract fallBackAndRecieveContract {
event log(string func, address send, uint256 val, bytes data);
//declared the fallBack function
/*in this we can recieve either but where we recive bytes data.
==> go to deploy section and deploy the function
==> in bottom you will see low level interection section
==> enter the data in hexadecimal format like 0x4536323,0x342354
==> the data will be sended
*/
fallback() external payable {
// msg.value ===> show sended either
// msg.sender ==> who send ether
// msg.data ==> show sended data
emit log("fallback", msg.sender, msg.value, msg.data);
}
// recieve function
receive() external payable {
// msg.value ===> show sended either
// msg.sender ==> who send ether
emit log(
"recieve",
msg.sender,
msg.value,
"recieve can not accept data"
);
}
// function checkBal() public view returns (uint256) {
// return address(this).balance;
// }
}
/*
**************************************************************************************
**************************************************************************************
*/
/*
Payable keyword
used:
to make the function and address payable.
we also make contructer payable
1)Address
if we make the address payable we send either to that address from the contract
note:
if we make the address payable we should used payable keyword before the visibility (public,private etc).
and also typeCast that address into payable,else it will throw error
syntex:
address payable public owner = payable(msg.sender);
3)constructer
if we send eth it one time during deploy we make construct payable
syntex:
constructor() payable {}
2)Function
if we make the function payable then we send either to that contract which the payable function present.
and we store the either in the contract
note:
1) the function should not used the view or pure keyword.
2) the color are red like when the function is payable.
the payable keyword is used when we make our function is payable
syntex:
function getEth() payable public{
code......
..........
}
*/
contract PayableContract {
// make the address payable
address payable public owner = payable(msg.sender);
constructor() payable {}
// declare the fuction payable
function getEth() public payable {}
// view the function that it recieve eth or not
function viewEth() public view returns (uint256) {
// in here this point to its parent where the fuction is present ===> PayableContract.
return address(this).balance;
}
}
/*
**************************************************************************************
**************************************************************************************
*/
// modifier
/*
special type of fuction like a constructer.
what a problem occurs:
==> when we need the same code in 20 function,then we write it,
and this will we create a lot of dublicacy.
by solving this probrem we can used ==> modifeir
==> constructer is also specail type of function,but in a contract there
one constructer
==> but in case of modifiar there are more than 1 modifier in a contract
note: when we apply modifier to a function so we write before the returns keyword.
i.e function fun1() public pure Modifier returns (string memory) { }
used:
used it that time when you know that the same code will be used again and again
syntex:
modifier modifierName {
starting code.......
...........
_;
ending code.......
...........
_;
}
used:
function fun1() public pure modifierName returns (string memory) {
code.......
}
working:
worked with 3 stages
1) ==> when function is calling so it will excute the modifier code first.
2) ==> when they reached to this symbol _; it will move to the function again and excute the function containing code
3) ==> after finish the function code, then it will move again to modifier and check if there have any code remaining it,if remaining excuted.
*/
contract ModifierContract {
// modifier is declared
modifier sameCode() {
for (uint256 i = 0; i < 10; i++) {
// code
}
_;
}
// used
function fun1() public pure sameCode returns (string memory) {
return "hello";
}
function fun2() public pure sameCode returns (uint256) {
return 20;
}
function fun3() public pure sameCode returns (bool) {
return true;
}
}
contract checkOwnerModifier {
address public owner = msg.sender;
// check the owner by using modifier
modifier checkOwner() {
require(owner == msg.sender, "not a vilid owner");
_;
}
function fun3() public view checkOwner returns (bool) {
return true;
}
// how to pass input in a modifier
uint256 public age = 0;
modifier AgeModifier(uint256 _x) {
age += _x;
_;
}
function changeAge(uint256 _y) public AgeModifier(_y) {}
}
/*
**************************************************************************************
**************************************************************************************
*/
// assert in solidity:
/*
assert() function have two purposes
1) to check bug in a code
2) to check secuirity
Note:
not so important,mainly used in rare case
syntex:
assert(condition);
*/
contract AssertContract {
address public owner = msg.sender;
uint256 public age = 20;
function checkOwner() public {
assert(msg.sender == owner);
age += 10;
}
}
/*
**************************************************************************************
**************************************************************************************
*/
// revert in solidity:
/*
revert() is used for error handling
we can pass revert inside the ifElse statement
syntex:
if(condition){
revert(message);
}
In this we have a condition if the condtion is false it will return the message.
*/
contract RevertContract {
address public owner = msg.sender;
uint256 public age = 20;
function checkInputValidation(uint256 _x) public {
if (_x < 5) {
revert("value is less than 5");
} else {
age += 5;
}
}
function checkOwner() public {
if (msg.sender != owner) {
revert("you are not the owner");
} else {
age -= 10;
}
}
/*
error throwError(); ----> custom build Error
in this we can can declared a custom build error and also we modify it.
it advantage is that it will reduce the gas cost
in this we can also pass arguments it behave like the events.
note: Errors can only be used with revert statements: "revert MyError();
syntex:
error throwError(); ----->this is declaration
function called() public{
if (_x < 5) {
revert throwError(); ----> called
}
}
Note:
if there have no arguments passed in the error during declation it give default error of the browser.
if we pass some arguments it throw that error which we define
error ----> keyword
throwError---->varaible name
declation:
error displayError(string name,string city); ----> behave like events
called:
revert displayError("ahmad","peshawar");
*/
// error throwError();
error throwError(string, uint256);
function customBuildError(uint256 _x) public {
if (_x < 5) {
// revert throwError();
revert throwError("ahmad", 56);
} else {
age += 5;
}
}
}
/*
**************************************************************************************
**************************************************************************************
*/
/*
How to manage error handling is solidty.
There are 3 ways to handle error.
1)----> require();
1)----> assert();
1)----> revert();
each have different uses.
*/
/*
require have used for two purposes
1)input Validation
2)access control
syntex
require(condtion,message);
In this we have a condition if the condtion is true then a block of code is excuted and if false it will return the message.
advantages:
1)if condition is false then it will return the remaining gas fees.
2)if condition is false all the changes which occurs in the states will revert to its initail state.
*/
contract RequiredContract {
address public owner = msg.sender;
uint256 public age = 30;
function checkInputValidation(uint256 _x) public {
require(_x > 5, "value of x is less then 5");
age += 5;
}
function checkOwner() public {
age -= 10;
require(msg.sender == owner, "not valid owner");
}
}
/*
**************************************************************************************
**************************************************************************************
*/
// calling parent funtion
// there are two ways to calling parent function
/*
1) --->direct calling
in direct calling there have perairity check
syntex
i.e A.fun1(); C.fun2()
2)---->calling parent using super keyword
in super calling it will work based on first come first out and right to left check.
it will check all the parent unless the required output is getted.
syntex
i.e super.fun1() super.fun2()
*/
contract A {
event Log(string name, uint256 age);
function fun1() public virtual {
emit Log("A.fun1", 34);
}
function fun2() public virtual {
emit Log("A.fun2", 35);
}
}
contract B is A {
function fun1() public virtual override {
emit Log("B.fun1", 44);
A.fun1(); //direct calling
}
function fun2() public virtual override {
emit Log("B.fun2", 45);
A.fun2(); //direct calling
}
}
contract C is A {
function fun1() public virtual override {
emit Log("C.fun1", 34);
super.fun1(); //direct calling using super.
// when there have single parent it behave like direct calling.
}
function fun2() public virtual override {
emit Log("C.fun2", 35);
super.fun2(); //direct calling using super.
// when there have single parent it behave like direct calling.
}
}
contract D is B, C {
function fun1() public override(B, C) {
emit Log("D.fun1", 80);
super.fun1(); // super calling using super keyword.
}
function fun2() public override(B, C) {
emit Log("D.fun2", 35);
super.fun2(); // super calling using super keyword.
}
}
/*
**************************************************************************************
**************************************************************************************
*/
// how to pass constructer values from child to parent in multiple inheratance
// 3 ways to pass values
// 2 ways are----static
// 1 ways are----dynamics
// where we assign the values without giving any arguments
// note: but we used it combine or even seperates
contract A {
string public name;
uint256 public age;
constructor(string memory _name, uint256 _age) {
name = _name;
age = _age;
}
}
contract B {
string public grade;
uint256 public sallary;
constructor(string memory _grade, uint256 _sallary) {
grade = _grade;
sallary = _sallary;
}
}
// Ist way to assign values -----------> static
// A()------> this will point the constructer of A
// B()------> this will point the constructer of B
// note: written near to contract(the contract nieghboor and each parent is separated by commas( , )
contract C is A("kamran", 32), B("B_grade", 40000) {
}
// 2nd way to assign values -----------> static
// A()------> this will point the constructer of A
// B()------> this will point the constructer of B
// written near to the constructer and there have no commas to seperate
contract D is A, B {
constructor() A("Bilal", 12) B("D_grade", 20000) {}
}
// 3rd way to assign values -----------> Dynamicallay
// A()------> this will point the constructer of A
// B()------> this will point the constructer of B
// written near to the constructer and there have no commas to seperate and the parameter which we recieve can pass to
// as argument to its parent because its parent also wants some arguments
contract E is A, B {
constructor(
string memory _name,
uint256 _age,
string memory _grade,
uint256 _sal
) A(_name, _age) B(_grade, _sal) {}
}
/*
**************************************************************************************
**************************************************************************************
*/
// multiple inheratance
// sequence its follow
// right to left and first to depth
// in multiple inheratance there have a little difference for declaring and using of
// virtual and override keyword which is mention below
// when overide is used
// if parent fuction have same name and fuctionalty, but when the child used it and make to add some additional logics in the same function
// without creating any new function in that time we used it the overide concept
contract A {
uint256 x;
constructor() {
x = 20;
}
function funcA() public pure returns (string memory) {
return "Hello A";
}
function funcOveride() public pure virtual returns (string memory) {
return "Contract A";
}
}
contract B is A {
string name;
constructor() {
name = "ahmad";
}
function funcB() public pure returns (string memory) {
return "this is B";
}
function funcOveride()
public
pure
virtual
override
returns (string memory)
{
return "Contract B";
}
}
// in here we can used the override keyword like this override(A,B) because
// in this C have multiple parents and we clearify that you have Multiple parents
contract C is A, B {
function funcOveride()
public
pure
virtual
override(A,B)
returns (string memory)
{
return "Contract C";
}
}
// functionality is same just declaration have a little differnce
contract D is A, B, C {
function funcOveride()
public
pure
override(A,B,C)
returns (string memory)
{
return "Contract D";
}
}
/*
**************************************************************************************
**************************************************************************************
*/
// Event in solidity
// when we store data only not accessed or not used just for the sake of information
// these data is not store in the blockchain but store in transiction log
// we can see its output in the transiction logs which is present in solidty terminal
//
contract eventContract {
// account, message, value is used just for readibilty, its not mandatory to assign such names
// note we can not call the values by its varaibles name,this is just for understanding
// declaration of events
event balance(address account, string message, uint256 value);
function setData(uint256 _val) public {
// by calling the events we used the [emit] keyword
emit balance(msg.sender, "hasValue", _val);
}
}
contract chatApp {
// the indexed keyword is used in that time when we apply to filter the record based on
// the given condition,this is mostly used in DApps
// note: we can declared the [indexed] keyword 3 times per emmit,else theey throw error
// only applicable for the emmit
event chat(
string indexed sender,
address indexed senderAddress,
string indexed reciver,
address recieverAddress,
string message,
uint256 time
);
function sendMessage(
string memory _sender,
string memory _reciever,
address _reciverAddress,
string memory _message
) public {
emit chat(
_sender,
msg.sender,
_reciever,
_reciverAddress,
_message,
block.timestamp
);
}
}
/*
**************************************************************************************
**************************************************************************************
*/
// inheratance in solidity
// when the child can carry his parent properties
// virtual
// the virtual keyword is used to allow access to its child that you will modify the changes
// this will be used only parent but if the children have sub children then it used
// virtual ----> for parent level we used it
// override
// override keyword is used to change and modify the data
// virtual and override are related and both used at a time
// the children who access the parent function and make to modify the function
// override -----> for children level we used it
contract GrandParent {
string public name;
function details(string memory _name) public returns (string memory){
name = _name;
return name;
}
function greet() public pure virtual returns (string memory) {
return "GrandParent";
}
}
contract Parent is GrandParent {
function greet() public pure virtual override returns (string memory) {
return "Parent";
}
}
contract child is Parent {
function greet() public pure override returns (string memory) {
return "child";
}
}
/*
**************************************************************************************
**************************************************************************************
*/
// visibility
// public private internal external
// 1)public
// this is accesable every where like within the function, outside the functiom,within inheratance,without inhearatance
// 2)private
// only accesable on that contract where they defined
// 3)external
// not allow with that contract where they define and also its children,but we can access outside from the contract
// internal
// within where they define and its child contract it will allow it
contract A {
string public stu1 = "ahmad";
string internal stu2 = "sudais";
string private stu3 = "imran";
// we can not used external with a dataTypes,because it can through error
// string external stu4 = "oziafa";
function viewPublic() public pure returns (string memory) {
return "public";
}
function viewPrivate() private pure returns (string memory) {
return "Private";
}
function viewInternal() internal pure returns (string memory) {
return "internal";
}
function viewExternal() external pure returns (string memory) {
return "external";
}
}
contract B is A {
function checkVisibility() public pure {
viewInternal();
viewPublic();
// not accessable here because its is children of contract A
// viewExternal();
// viewPrivate();
}
}
/*
**************************************************************************************
**************************************************************************************
*/