We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
There was an error while loading.Please reload this page.
1 parent670ce91 commit4a570d2Copy full SHA for 4a570d2
src/main/java/io/api/etherscan/model/Log.java
@@ -67,16 +67,18 @@ public LocalDateTime getTimeStamp() {
67
}
68
69
/**
70
- *
71
- * @return
+ * Return the "timeStamp" field of the event record as a long-int representing the milliseconds
+ * since the Unix epoch (1970-01-01 00:00:00).
72
+ * @return milliseconds between Unix epoch and `timeStamp`. If field is empty or null, returns null
73
*/
74
publicLonggetTimeStampAsMillis() {
75
if (BasicUtils.isEmpty(timeStamp)) {
76
returnnull;
77
-return (timeStamp.charAt(0) =='0' &&timeStamp.charAt(1) =='x')
78
+longtsSecs = (timeStamp.charAt(0) =='0' &&timeStamp.charAt(1) =='x')
79
?BasicUtils.parseHex(timeStamp).longValue()
- :Long.parseLong(timeStamp) *1000;
80
+ :Long.parseLong(timeStamp);
81
+returntsSecs *1000;
82
83
84
publicStringgetData() {