Skip to content

Commit

Permalink
rename TypeVote to GovOffchainType
Browse files Browse the repository at this point in the history
  • Loading branch information
Sotatek-QuanLeA committed Nov 4, 2024
1 parent 1981578 commit 2e878b2
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
@FieldDefaults(level = AccessLevel.PRIVATE, makeFinal = true)
@RequiredArgsConstructor
@Getter
public enum TypeVote {
public enum GovOffchainType {
VOTING(1),
GOV_ACTION(2),
DREP_REGISTRATION(3),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import org.cardanofoundation.ledgersync.consumercommon.entity.compositekey.OffChainCommitteeDeregistrationId;
import org.cardanofoundation.ledgersync.consumercommon.entity.compositekey.OffChainFetchErrorId;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.CheckValid;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.TypeVote;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.GovOffchainType;
import org.cardanofoundation.ledgersync.scheduler.SchedulerProperties;
import org.cardanofoundation.ledgersync.scheduler.dto.anchor.CommitteeDeregistrationDTO;
import org.cardanofoundation.ledgersync.scheduler.dto.offchain.OffChainCommitteeDeregFetchResultDTO;
Expand Down Expand Up @@ -61,12 +61,12 @@ public OffChainFetchError extractFetchError(OffChainCommitteeDeregFetchResultDTO
OffChainFetchErrorId offChainVoteFetchErrorId = new OffChainFetchErrorId(
offChainAnchorData.getAnchorUrl(),
offChainAnchorData.getAnchorHash(),
TypeVote.COMMITTEE_DEREGISTRATION.getValue());
GovOffchainType.COMMITTEE_DEREGISTRATION.getValue());

offChainFetchError.setOffChainFetchErrorId(offChainVoteFetchErrorId);
offChainFetchError.setAnchorUrl(offChainAnchorData.getAnchorUrl());
offChainFetchError.setAnchorHash(offChainAnchorData.getAnchorHash());
offChainFetchError.setType(TypeVote.COMMITTEE_DEREGISTRATION.getValue());
offChainFetchError.setType(GovOffchainType.COMMITTEE_DEREGISTRATION.getValue());
offChainFetchError.setFetchError(offChainAnchorData.getFetchFailError());
return offChainFetchError;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import org.cardanofoundation.ledgersync.consumercommon.entity.OffChainFetchError;
import org.cardanofoundation.ledgersync.consumercommon.entity.compositekey.OffChainFetchErrorId;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.CheckValid;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.TypeVote;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.GovOffchainType;
import org.cardanofoundation.ledgersync.scheduler.SchedulerProperties;
import org.cardanofoundation.ledgersync.scheduler.dto.anchor.ConstitutionAnchorDTO;
import org.cardanofoundation.ledgersync.scheduler.dto.offchain.OffChainConstitutionFetchResultDTO;
Expand Down Expand Up @@ -50,12 +50,12 @@ public OffChainFetchError extractFetchError(OffChainConstitutionFetchResultDTO o
OffChainFetchErrorId offChainVoteFetchErrorId = new OffChainFetchErrorId(
offChainAnchorData.getAnchorUrl(),
offChainAnchorData.getAnchorHash(),
TypeVote.CONSTITUTION.getValue());
GovOffchainType.CONSTITUTION.getValue());

offChainVoteFetchError.setOffChainFetchErrorId(offChainVoteFetchErrorId);
offChainVoteFetchError.setAnchorUrl(offChainAnchorData.getAnchorUrl());
offChainVoteFetchError.setAnchorHash(offChainAnchorData.getAnchorHash());
offChainVoteFetchError.setType(TypeVote.CONSTITUTION.getValue());
offChainVoteFetchError.setType(GovOffchainType.CONSTITUTION.getValue());
offChainVoteFetchError.setFetchError(offChainAnchorData.getFetchFailError());
return offChainVoteFetchError;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import org.cardanofoundation.ledgersync.consumercommon.entity.compositekey.OffChainDRepRegistrationId;
import org.cardanofoundation.ledgersync.consumercommon.entity.compositekey.OffChainFetchErrorId;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.CheckValid;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.TypeVote;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.GovOffchainType;
import org.cardanofoundation.ledgersync.scheduler.SchedulerProperties;
import org.cardanofoundation.ledgersync.scheduler.dto.anchor.DRepRegistrationDTO;
import org.cardanofoundation.ledgersync.scheduler.dto.offchain.OffChainDRepRegistrationFetchResultDTO;
Expand Down Expand Up @@ -61,12 +61,12 @@ public OffChainFetchError extractFetchError(OffChainDRepRegistrationFetchResultD
OffChainFetchErrorId offChainVoteFetchErrorId = new OffChainFetchErrorId(
offChainAnchorData.getAnchorUrl(),
offChainAnchorData.getAnchorHash(),
TypeVote.DREP_REGISTRATION.getValue());
GovOffchainType.DREP_REGISTRATION.getValue());

offChainFetchError.setOffChainFetchErrorId(offChainVoteFetchErrorId);
offChainFetchError.setAnchorUrl(offChainAnchorData.getAnchorUrl());
offChainFetchError.setAnchorHash(offChainAnchorData.getAnchorHash());
offChainFetchError.setType(TypeVote.DREP_REGISTRATION.getValue());
offChainFetchError.setType(GovOffchainType.DREP_REGISTRATION.getValue());
offChainFetchError.setFetchError(offChainAnchorData.getFetchFailError());
return offChainFetchError;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import org.cardanofoundation.ledgersync.consumercommon.entity.compositekey.OffChainFetchErrorId;
import org.cardanofoundation.ledgersync.consumercommon.entity.compositekey.OffChainGovActionId;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.CheckValid;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.TypeVote;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.GovOffchainType;
import org.cardanofoundation.ledgersync.scheduler.SchedulerProperties;
import org.cardanofoundation.ledgersync.scheduler.dto.anchor.GovAnchorDTO;
import org.cardanofoundation.ledgersync.scheduler.dto.offchain.OffChainFetchResultDTO;
Expand Down Expand Up @@ -55,12 +55,12 @@ public OffChainFetchError extractFetchError(OffChainGovFetchResultDTO offChainAn
OffChainFetchErrorId offChainVoteFetchErrorId = new OffChainFetchErrorId(
offChainAnchorData.getAnchorUrl(),
offChainAnchorData.getAnchorHash(),
TypeVote.GOV_ACTION.getValue());
GovOffchainType.GOV_ACTION.getValue());

offChainFetchError.setOffChainFetchErrorId(offChainVoteFetchErrorId);
offChainFetchError.setAnchorUrl(offChainAnchorData.getAnchorUrl());
offChainFetchError.setAnchorHash(offChainAnchorData.getAnchorHash());
offChainFetchError.setType(TypeVote.GOV_ACTION.getValue());
offChainFetchError.setType(GovOffchainType.GOV_ACTION.getValue());
offChainFetchError.setFetchError(offChainAnchorData.getFetchFailError());
return offChainFetchError;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import org.cardanofoundation.ledgersync.consumercommon.entity.OffChainVotingData;
import org.cardanofoundation.ledgersync.consumercommon.entity.compositekey.OffChainFetchErrorId;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.CheckValid;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.TypeVote;
import org.cardanofoundation.ledgersync.consumercommon.enumeration.GovOffchainType;
import org.cardanofoundation.ledgersync.scheduler.SchedulerProperties;
import org.cardanofoundation.ledgersync.scheduler.dto.anchor.VotingDataAnchorDTO;
import org.cardanofoundation.ledgersync.scheduler.dto.offchain.OffChainFetchResultDTO;
Expand Down Expand Up @@ -50,12 +50,12 @@ public OffChainFetchError extractFetchError(OffChainVotingFetchResultDTO offChai
OffChainFetchErrorId offChainVoteFetchErrorId = new OffChainFetchErrorId(
offChainAnchorData.getAnchorUrl(),
offChainAnchorData.getAnchorHash(),
TypeVote.VOTING.getValue());
GovOffchainType.VOTING.getValue());

offChainVoteFetchError.setOffChainFetchErrorId(offChainVoteFetchErrorId);
offChainVoteFetchError.setAnchorUrl(offChainAnchorData.getAnchorUrl());
offChainVoteFetchError.setAnchorHash(offChainAnchorData.getAnchorHash());
offChainVoteFetchError.setType(TypeVote.VOTING.getValue());
offChainVoteFetchError.setType(GovOffchainType.VOTING.getValue());
offChainVoteFetchError.setFetchError(offChainAnchorData.getFetchFailError());
return offChainVoteFetchError;
}
Expand Down

0 comments on commit 2e878b2

Please sign in to comment.