Code example for AtomicLong

Methods: set

0
    ManualClock(long init) {
        time = new AtomicLong(init);
    } 
 
    void set(long t) {
        time.set(t);
    } 
 
    public long now() { 
        return time.get();
    } 
}