Interface StateRequest


public interface StateRequest
State request, as returned by Session.getStateRequest(). Cannot be directly manipulated by the client code, i.e. all methods are read-only.
Since:
0.7
  • Method Details

    • getSession

      Session getSession()
      User session to which this state request belongs.
      Returns:
      An object of type Session. Cannot be null.
      Since:
      0.7
    • getState

      State getState()
      The target state of this state request.
      Returns:
      An object of type State. Cannot be null.
      Since:
      0.7
    • getStatus

      StateRequest.Status getStatus()
      The current status of this state request.
      Returns:
      An object of type StateRequest.Status. Cannot be null.
      Since:
      0.9
    • getLiveExperiences

      Set<Experiment.Experience> getLiveExperiences()

      Targeted experiences in experiments instrumented on the target state. An experience is live iff a) this session has been targeted for it, b) its containing experiment is instrumented on this state, and c) is neither off nor disqualified in this session.

      Returns:
      A Set of Experiment.Experience objects. Cannot be null, but may be empty.
      Since:
      0.7
    • getLiveExperience

      Optional<Experiment.Experience> getLiveExperience(Experiment experiment)
      The live experience in a given experiment, if any.
      Parameters:
      experiment - Experiment
      Returns:
      An Optional, containing the live experience, if a live experience in the given experiment exists, or empty otherwise.
      Since:
      0.7
    • getResolvedParameters

      Map<String,String> getResolvedParameters()
      The resolved state parameters as an immutable map, containing the merged maps of the state parameters defined at the state level and at the state variant level, with the latter taking precedence over former.
      Returns:
      Immutable map keyed by parameter names.
      Since:
      0.7