aboutsummaryrefslogtreecommitdiffstats
path: root/src/remake
diff options
context:
space:
mode:
Diffstat (limited to 'src/remake')
-rw-r--r--src/remake/records.rs17
1 files changed, 1 insertions, 16 deletions
diff --git a/src/remake/records.rs b/src/remake/records.rs
index 720aea1..463d085 100644
--- a/src/remake/records.rs
+++ b/src/remake/records.rs
@@ -45,22 +45,7 @@ const DAY_MS: u64 = 24 * 60 * 60 * 1000;
// --- record types ------------------------------------------------------------
-/// An epoch in a record: generation plus hex-encoded snapshot hash.
-#[derive(Clone, Debug, PartialEq, Eq, Serialize, Deserialize)]
-#[serde(rename_all = "camelCase")]
-pub(crate) struct EpochRecord {
- pub(crate) generation: u64,
- pub(crate) id: String,
-}
-
-impl From<Epoch> for EpochRecord {
- fn from(epoch: Epoch) -> Self {
- Self {
- generation: epoch.generation,
- id: epoch.id_hex(),
- }
- }
-}
+pub(crate) use crate::document::replica::EpochRecord;
impl EpochRecord {
pub(crate) fn to_epoch(&self) -> Option<Epoch> {