public final class HibernateParams extends Object
Constructor and Description |
---|
HibernateParams() |
Modifier and Type | Method and Description |
---|---|
int |
getTimeToLive()
Returns the time to live in seconds.
|
static HibernateParams |
of(int timeToLive,
TimeUnit timeUnit)
Creates a holder for Hibernate params.
|
org.json.JSONObject |
toJson()
Converts values to JSON
|
public static final String TTL
public static HibernateParams of(int timeToLive, TimeUnit timeUnit)
timeToLive
- length of time the server should keep the session activetimeUnit
- unit for timeToLivepublic int getTimeToLive()
public org.json.JSONObject toJson()