C++ Server-Side SDK
LaunchDarkly SDK
Public Member Functions | Friends | List of all members
launchdarkly::server_side::AllFlagsState::State Class Reference

#include <all_flags_state.hpp>

Public Member Functions

 State (std::uint64_t version, std::optional< std::int64_t > variation, std::optional< EvaluationReason > reason, bool track_events, bool track_reason, std::optional< std::uint64_t > debug_events_until_date)
 
 State (std::uint64_t version, std::optional< std::int64_t > variation, std::optional< EvaluationReason > reason, bool track_events, bool track_reason, std::optional< std::uint64_t > debug_events_until_date, std::vector< std::string > prerequisites)
 
std::uint64_t Version () const
 
std::optional< std::int64_t > Variation () const
 
std::optional< EvaluationReason > const & Reason () const
 
bool TrackEvents () const
 
bool TrackReason () const
 
std::optional< std::uint64_t > const & DebugEventsUntilDate () const
 
bool OmitDetails () const
 
std::vector< std::string > const & Prerequisites () const
 

Friends

class AllFlagsStateBuilder
 

Detailed Description

State contains information pertaining to a single feature flag.

Member Function Documentation

◆ DebugEventsUntilDate()

std::optional< std::uint64_t > const & launchdarkly::server_side::AllFlagsState::State::DebugEventsUntilDate ( ) const
Returns
The date on which debug mode expires for this flag, if enabled.

◆ OmitDetails()

bool launchdarkly::server_side::AllFlagsState::State::OmitDetails ( ) const
Returns
True if the options passed to AllFlagsState, combined with the obtained flag state, indicate that some metadata can be left out of the JSON serialization.

◆ Prerequisites()

std::vector< std::string > const & launchdarkly::server_side::AllFlagsState::State::Prerequisites ( ) const
Returns
The list of prerequisites for this flag in the order they were evaluated.

◆ Reason()

std::optional< EvaluationReason > const & launchdarkly::server_side::AllFlagsState::State::Reason ( ) const
Returns
The reason that the flag evaluation produced the specified variation.

◆ TrackEvents()

bool launchdarkly::server_side::AllFlagsState::State::TrackEvents ( ) const
Returns
True if a full feature event must be sent when evaluating this flag. This will be true if tracking was explicitly enabled for this flag for data export, or if the evaluation involved an experiment, or both.

◆ TrackReason()

bool launchdarkly::server_side::AllFlagsState::State::TrackReason ( ) const
Returns
True if the evaluation reason should always be included in any full feature event created for this flag, regardless of whether a VariationDetail method was called. This will be true if the evaluation involved an experiment.

◆ Variation()

std::optional< std::int64_t > launchdarkly::server_side::AllFlagsState::State::Variation ( ) const
Returns
The variation index that was selected for the specified evaluation context.

◆ Version()

std::uint64_t launchdarkly::server_side::AllFlagsState::State::Version ( ) const
Returns
The flag's version number when it was evaluated.

The documentation for this class was generated from the following files: