All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.spun.util.ThreadedWrapper Maven / Gradle / Ivy

There is a newer version: 24.9.0
Show newest version
package com.spun.util;

import java.util.function.Supplier;

public class ThreadedWrapper implements Wrapper
{
  private final ThreadLocal instance;
  public ThreadedWrapper(Supplier lambda)
  {
    this.instance = ThreadLocal.withInitial(lambda);
  }
  @Override
  public T get()
  {
    return instance.get();
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy