-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5ff6d18
commit ba48f9b
Showing
3 changed files
with
16 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,17 @@ | ||
pub struct Config { | ||
pub block_production_interval: u64, | ||
pub difficulty: usize, | ||
pub block_reward: f64, | ||
pub genesis_block_producer: String, | ||
} | ||
|
||
impl Config { | ||
pub fn new(block_production_interval: u64) -> Self { | ||
pub fn new(block_production_interval: u64, difficulty: usize, block_reward: f64, genesis_block_producer: String) -> Self { | ||
Config { | ||
block_production_interval, | ||
difficulty, | ||
block_reward, | ||
genesis_block_producer, | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters