K - 远端键类型public interface IRemotingClockFactory<K>
IAutoRefreshTickClock| 限定符和类型 | 方法和说明 |
|---|---|
default IAutoRefreshTickClock |
createClock(K remotingKey)
创建远端时钟
为了使记号时钟的时间误差更小,使用此方法来获取远端时钟
|
default long |
currentTimeMicros(K remotingKey)
远端的当前微秒数
|
default long |
currentTimeMillis(K remotingKey)
远端的当前毫秒数
|
default long |
currentTimeNanos(K remotingKey)
远端的当前纳秒数
注意:值格式与 System.nanoTime() 并不相同 |
void |
destroyClock(K remotingKey)
销毁远端时钟
|
IAutoRefreshTickClock |
getClock(K remotingKey)
获取远端时钟
|
long |
getRemotingTime(K remotingKey)
获取远端时间,单位:毫秒
|
default Date |
now(K remotingKey)
远端的当前时间
|
@NonNull
long getRemotingTime(@NonNull
K remotingKey)
remotingKey - 远端键值@NonNull default IAutoRefreshTickClock createClock(@NonNull K remotingKey)
为了使记号时钟的时间误差更小,使用此方法来获取远端时钟
remotingKey - 远端键值@NonNull IAutoRefreshTickClock getClock(@NonNull K remotingKey)
remotingKey - 远端健值void destroyClock(@NonNull
K remotingKey)
remotingKey - 远端键值default long currentTimeMillis(@NonNull
K remotingKey)
remotingKey - 远端键值default long currentTimeMicros(@NonNull
K remotingKey)
remotingKey - 远端键值default long currentTimeNanos(@NonNull
K remotingKey)
System.nanoTime() 并不相同remotingKey - 远端键值Copyright © 2021–2024 EasyJ寮�婧愮ぞ鍖�. All rights reserved.