Coverage Summary for Class: RemascConfig (co.rsk.config)
Class |
Class, %
|
Method, %
|
Line, %
|
RemascConfig |
0%
(0/1)
|
0%
(0/12)
|
0%
(0/19)
|
1 /*
2 * This file is part of RskJ
3 * Copyright (C) 2017 RSK Labs Ltd.
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU Lesser General Public License as published by
7 * the Free Software Foundation, either version 3 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 */
18
19 package co.rsk.config;
20
21 import co.rsk.core.RskAddress;
22
23 /**
24 * Created by mario on 12/12/16.
25 */
26 public class RemascConfig {
27 // Number of blocks until mining fees are processed
28 private long maturity;
29
30 // Number of blocks block reward is split into
31 private long syntheticSpan;
32
33 // RSK labs address.
34 // Note that his has to be a basic type (such as String) because RemascConfig
35 // is deserialized automatically from JSON.
36 private String rskLabsAddress;
37
38 // RSK labs address.
39 // Note that his has to be a basic type (such as String) because RemascConfig
40 // is deserialized automatically from JSON.
41 private String rskLabsAddressRskip218;
42
43 // RSK labs cut. Available reward / rskLabsDivisor is what RSK gets.
44 private long rskLabsDivisor = 5;
45
46 // Federation cut. Available reward / rskFederationDivisor is what Federation gets.
47 private long federationDivisor = 100;
48
49 // Punishment in case of broken selection rule. The punishment applied is available reward / punishmentDivisor.
50 private long punishmentDivisor = 10;
51
52 // Reward to block miners who included uncles in their blocks. Available reward / publishersDivisor is the total reward.
53 private long publishersDivisor = 10;
54
55 private long lateUncleInclusionPunishmentDivisor = 20;
56
57 // Multiplier and Divisor for paid fees comparison in selection rule
58 private long paidFeesMultiplier = 2;
59 private long paidFeesDivisor = 1;
60
61 public long getPaidFeesMultiplier() { return paidFeesMultiplier; }
62
63 public long getPaidFeesDivisor() { return paidFeesDivisor; }
64
65 public long getMaturity() {
66 return maturity;
67 }
68
69 public long getSyntheticSpan() {
70 return syntheticSpan;
71 }
72
73 public RskAddress getRskLabsAddress() {
74 return new RskAddress(this.rskLabsAddress);
75 }
76
77 public RskAddress getRskLabsAddressRskip218() {
78 return new RskAddress(this.rskLabsAddressRskip218);
79 }
80
81 public long getRskLabsDivisor() {
82 return rskLabsDivisor;
83 }
84
85 public long getFederationDivisor() {
86 return federationDivisor;
87 }
88
89 public long getPunishmentDivisor() {
90 return punishmentDivisor;
91 }
92
93 public long getLateUncleInclusionPunishmentDivisor() { return this.lateUncleInclusionPunishmentDivisor; }
94
95 public long getPublishersDivisor() {
96 return publishersDivisor;
97 }
98
99 }