Uses of Interface
ratpack.session.SessionKey
-
Packages that use SessionKey Package Description ratpack.session Objects for providingSessionsupport. -
-
Uses of SessionKey in ratpack.session
Methods in ratpack.session that return SessionKey Modifier and Type Method Description static <T> SessionKey<T>SessionKey. of(java.lang.Class<T> type)Creates a key of the given type with no name.static SessionKey<?>SessionKey. of(java.lang.String name)Creates a key of the given name with no type.static <T> SessionKey<T>SessionKey. of(java.lang.String name, java.lang.Class<T> type)Creates a key of the given name and type.static <T> SessionKey<T>SessionKey. ofType(java.lang.String name, T value)Creates a key of the given name, and the type of the given object (as provided byObject.getClass()).static <T> SessionKey<T>SessionKey. ofType(T value)Creates a key of type of the given object (as provided byObject.getClass()), and no name.Methods in ratpack.session that return types with arguments of type SessionKey Modifier and Type Method Description default Promise<java.util.Set<SessionKey<?>>>Session. getKeys()A convenience shorthand forSessionData.getKeys().java.util.Set<SessionKey<?>>SessionData. getKeys()The keys of all objects currently in the session.Methods in ratpack.session with parameters of type SessionKey Modifier and Type Method Description default <T> Promise<java.util.Optional<T>>Session. get(SessionKey<T> key)A convenience shorthand forSessionData.get(SessionKey).default <T> Promise<java.util.Optional<T>>Session. get(SessionKey<T> key, SessionSerializer serializer)A convenience shorthand forSessionData.get(SessionKey, SessionSerializer).default <T> java.util.Optional<T>SessionData. get(SessionKey<T> key)Fetch the object with the given key, using thedefault serializer.<T> java.util.Optional<T>SessionData. get(SessionKey<T> key, SessionSerializer serializer)Read the object with the given key.default OperationSession. remove(SessionKey<?> key)A convenience shorthand forSessionData.remove(SessionKey).voidSessionData. remove(SessionKey<?> key)Removes the object with the given key, if it exists.default <T> Promise<T>Session. require(SessionKey<T> key)A convenience shorthand forSessionData.require(SessionKey).default <T> Promise<T>Session. require(SessionKey<T> key, SessionSerializer serializer)A convenience shorthand forSessionData.require(SessionKey, SessionSerializer).default <T> TSessionData. require(SessionKey<T> key)LikeSessionData.get(SessionKey), but throwsNoSuchElementExceptionon the absence of a value.default <T> TSessionData. require(SessionKey<T> key, SessionSerializer serializer)LikeSessionData.get(SessionKey, SessionSerializer), but throwsNoSuchElementExceptionon the absence of a value.default <T> OperationSession. set(SessionKey<T> key, T value)A convenience shorthand forSessionData.set(SessionKey, Object).default <T> OperationSession. set(SessionKey<T> key, T value, SessionSerializer serializer)A convenience shorthand forSessionData.set(SessionKey, Object, SessionSerializer).default <T> voidSessionData. set(SessionKey<T> key, T value)Sets the value for the given key, using thedefault serializer.<T> voidSessionData. set(SessionKey<T> key, T value, SessionSerializer serializer)Sets the value for the given key.
-