jhalterman / expiringmap

A high performance thread-safe map that expires entries
Apache License 2.0
1k stars 142 forks source link

Overload put to accept a Duration #52

Open mishaxz opened 6 years ago

mishaxz commented 6 years ago

Would be nice to be able to specify an expiry time using a Duration object

losingsleeep commented 6 years ago

Seems that Duration class has been added since Java SE 8: Official Doc I think the project cannot depend on Java 8 because it obviously states the support of Java 6+ in the repository's README: "Supports Java 6+ though the documentation uses lambdas for simplicity."