Package io.ryos.rhino.sdk.data
Class UserSessionImpl
- java.lang.Object
-
- io.ryos.rhino.sdk.data.ContextImpl
-
- io.ryos.rhino.sdk.data.UserSessionImpl
-
- All Implemented Interfaces:
Context
,UserSession
public class UserSessionImpl extends ContextImpl implements UserSession
User session is a stash to store objects and share them among scenarios or DSLs in every load generation cycle. Once load generation cycle completes, will be created before the simulation starts, and it will existing during the simulation execution.- Since:
- 1.1.0
- Author:
- Erhan Bagdemir
-
-
Constructor Summary
Constructors Constructor Description UserSessionImpl(User user)
UserSessionImpl(User user, SimulationSession session)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Optional<java.lang.String>
getRefreshToken()
Optional of refresh token.SimulationSession
getSimulationSession()
User
getUser()
Returns the user of the current session.java.util.Optional<java.lang.String>
getUserToken()
Optional of user token.-
Methods inherited from class io.ryos.rhino.sdk.data.ContextImpl
add, empty, get, isEmpty
-
-
-
-
Constructor Detail
-
UserSessionImpl
public UserSessionImpl(User user, SimulationSession session)
-
UserSessionImpl
public UserSessionImpl(User user)
-
-
Method Detail
-
getUser
public User getUser()
Description copied from interface:UserSession
Returns the user of the current session.- Specified by:
getUser
in interfaceUserSession
- Returns:
- The user of the current session.
-
getUserToken
public java.util.Optional<java.lang.String> getUserToken()
Description copied from interface:UserSession
Optional of user token.- Specified by:
getUserToken
in interfaceUserSession
- Returns:
Optional
type.
-
getRefreshToken
public java.util.Optional<java.lang.String> getRefreshToken()
Description copied from interface:UserSession
Optional of refresh token.- Specified by:
getRefreshToken
in interfaceUserSession
- Returns:
Optional
type.
-
getSimulationSession
public SimulationSession getSimulationSession()
- Specified by:
getSimulationSession
in interfaceUserSession
-
-