diff --git a/tang-commons/src/main/kotlin/com/tang/commons/kotlin/extensions/time/LocalDateTimeExtensions.kt b/tang-commons/src/main/kotlin/com/tang/commons/kotlin/extensions/time/LocalDateTimeExtensions.kt new file mode 100644 index 00000000..78706283 --- /dev/null +++ b/tang-commons/src/main/kotlin/com/tang/commons/kotlin/extensions/time/LocalDateTimeExtensions.kt @@ -0,0 +1,11 @@ +package com.tang.commons.kotlin.extensions.time + +import java.time.LocalDateTime + +/** + * @author Tang + */ + +val LocalDateTime.micro: Int get() = this.nano / 1000 + +val LocalDateTime.milli: Int get() = this.nano / 1000 / 1000