-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support for conflux hardfork 2.4.0 (#52)
* support conflux-rust 2.4 rpc changes * support for 1559 transaction type * remove log
- Loading branch information
Showing
14 changed files
with
503 additions
and
13 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
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
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
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 |
---|---|---|
@@ -0,0 +1,47 @@ | ||
package conflux.web3j.response; | ||
import org.web3j.utils.Numeric; | ||
|
||
import java.math.BigInteger; | ||
import java.util.List; | ||
import java.util.stream.Collectors; | ||
|
||
public class FeeHistory { | ||
public static class Response extends CfxResponse<FeeHistory> {} | ||
|
||
private String oldestEpoch; | ||
private List<String> baseFeePerGas; | ||
private List<Float> gasUsedRatio; | ||
private List<String> reward; | ||
|
||
public BigInteger getOldestEpoch() { | ||
return Numeric.decodeQuantity(oldestEpoch); | ||
} | ||
|
||
public void setOldestEpoch(String oldestEpoch) { | ||
this.oldestEpoch = oldestEpoch; | ||
} | ||
|
||
public List<BigInteger> getBaseFeePerGas() { | ||
return baseFeePerGas.stream().map(Numeric::decodeQuantity).collect(Collectors.toList()); | ||
} | ||
|
||
public void setBaseFeePerGas(List<String> baseFeePerGas) { | ||
this.baseFeePerGas = baseFeePerGas; | ||
} | ||
|
||
public List<Float> getGasUsedRatio() { | ||
return gasUsedRatio; | ||
} | ||
|
||
public void setGasUsedRatio(List<Float> gasUsedRatio) { | ||
this.gasUsedRatio = gasUsedRatio; | ||
} | ||
|
||
public List<BigInteger> getReward() { | ||
return reward.stream().map(Numeric::decodeQuantity).collect(Collectors.toList()); | ||
} | ||
|
||
public void setReward(List<String> reward) { | ||
this.reward = reward; | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,46 @@ | ||
package conflux.web3j.response; | ||
|
||
import org.web3j.utils.Numeric; | ||
|
||
import java.math.BigInteger; | ||
|
||
public class ParamsOfVote { | ||
public static class Response extends CfxResponse<ParamsOfVote> {} | ||
|
||
private String baseFeeShareProp; | ||
private String interestRate; | ||
private String powBaseReward; | ||
private String storagePointProp; | ||
|
||
public BigInteger getBaseFeeShareProp() { | ||
return Numeric.decodeQuantity(baseFeeShareProp); | ||
} | ||
|
||
public void setBaseFeeShareProp(String baseFeeShareProp) { | ||
this.baseFeeShareProp = baseFeeShareProp; | ||
} | ||
|
||
public BigInteger getInterestRate() { | ||
return Numeric.decodeQuantity(interestRate); | ||
} | ||
|
||
public void setInterestRate(String interestRate) { | ||
this.interestRate = interestRate; | ||
} | ||
|
||
public BigInteger getPowBaseReward() { | ||
return Numeric.decodeQuantity(powBaseReward); | ||
} | ||
|
||
public void setPowBaseReward(String powBaseReward) { | ||
this.powBaseReward = powBaseReward; | ||
} | ||
|
||
public BigInteger getStoragePointProp() { | ||
return Numeric.decodeQuantity(storagePointProp); | ||
} | ||
|
||
public void setStoragePointProp(String storagePointProp) { | ||
this.storagePointProp = storagePointProp; | ||
} | ||
} |
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
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 |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package conflux.web3j.types; | ||
import java.util.List; | ||
|
||
public class AccessListEntry { | ||
|
||
private Address address; | ||
private List<String> storageKeys; | ||
|
||
public List<String> getStorageKeys() { | ||
return storageKeys; | ||
} | ||
|
||
public void setStorageKeys(List<String> storageKeys) { | ||
this.storageKeys = storageKeys; | ||
} | ||
|
||
public Address getAddress() { | ||
return address; | ||
} | ||
|
||
public void setAddress(CfxAddress address) { | ||
this.address = address; | ||
} | ||
} |
Oops, something went wrong.