Documentation ¶
Overview ¶
Package datafileprojectconfig //
Package datafileprojectconfig //
Index ¶
- func Parse(jsonDatafile []byte) (*entities.Datafile, error)
- type DatafileProjectConfig
- func (c DatafileProjectConfig) GetAccountID() string
- func (c DatafileProjectConfig) GetAnonymizeIP() bool
- func (c DatafileProjectConfig) GetAttributeByKey(key string) (entities.Attribute, error)
- func (c DatafileProjectConfig) GetAttributeID(key string) string
- func (c DatafileProjectConfig) GetAttributes() (attributeList []entities.Attribute)
- func (c DatafileProjectConfig) GetAudienceByID(audienceID string) (entities.Audience, error)
- func (c DatafileProjectConfig) GetAudienceList() (audienceList []entities.Audience)
- func (c DatafileProjectConfig) GetAudienceMap() map[string]entities.Audience
- func (c DatafileProjectConfig) GetBotFiltering() bool
- func (c DatafileProjectConfig) GetDatafile() string
- func (c DatafileProjectConfig) GetEnvironmentKey() string
- func (c DatafileProjectConfig) GetEventByKey(eventKey string) (entities.Event, error)
- func (c DatafileProjectConfig) GetEvents() (eventList []entities.Event)
- func (c DatafileProjectConfig) GetExperimentByKey(experimentKey string) (entities.Experiment, error)
- func (c DatafileProjectConfig) GetExperimentList() (experimentList []entities.Experiment)
- func (c DatafileProjectConfig) GetFeatureByKey(featureKey string) (entities.Feature, error)
- func (c DatafileProjectConfig) GetFeatureList() (featureList []entities.Feature)
- func (c DatafileProjectConfig) GetFlagVariationsMap() map[string][]entities.Variation
- func (c DatafileProjectConfig) GetGroupByID(groupID string) (entities.Group, error)
- func (c DatafileProjectConfig) GetProjectID() string
- func (c DatafileProjectConfig) GetRevision() string
- func (c DatafileProjectConfig) GetRolloutList() (rolloutList []entities.Rollout)
- func (c DatafileProjectConfig) GetSdkKey() string
- func (c DatafileProjectConfig) GetVariableByKey(featureKey, variableKey string) (entities.Variable, error)
- func (c DatafileProjectConfig) SendFlagDecisions() bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DatafileProjectConfig ¶
type DatafileProjectConfig struct {
// contains filtered or unexported fields
}
DatafileProjectConfig is a project config backed by a datafile
func NewDatafileProjectConfig ¶
func NewDatafileProjectConfig(jsonDatafile []byte, logger logging.OptimizelyLogProducer) (*DatafileProjectConfig, error)
NewDatafileProjectConfig initializes a new datafile from a json byte array using the default JSON datafile parser
func (DatafileProjectConfig) GetAccountID ¶
func (c DatafileProjectConfig) GetAccountID() string
GetAccountID returns accountID
func (DatafileProjectConfig) GetAnonymizeIP ¶
func (c DatafileProjectConfig) GetAnonymizeIP() bool
GetAnonymizeIP returns anonymizeIP
func (DatafileProjectConfig) GetAttributeByKey ¶
func (c DatafileProjectConfig) GetAttributeByKey(key string) (entities.Attribute, error)
GetAttributeByKey returns the attribute with the given key
func (DatafileProjectConfig) GetAttributeID ¶
func (c DatafileProjectConfig) GetAttributeID(key string) string
GetAttributeID returns attributeID
func (DatafileProjectConfig) GetAttributes ¶
func (c DatafileProjectConfig) GetAttributes() (attributeList []entities.Attribute)
GetAttributes returns attributes
func (DatafileProjectConfig) GetAudienceByID ¶
func (c DatafileProjectConfig) GetAudienceByID(audienceID string) (entities.Audience, error)
GetAudienceByID returns the audience with the given ID
func (DatafileProjectConfig) GetAudienceList ¶
func (c DatafileProjectConfig) GetAudienceList() (audienceList []entities.Audience)
GetAudienceList returns an array of all the audiences
func (DatafileProjectConfig) GetAudienceMap ¶
func (c DatafileProjectConfig) GetAudienceMap() map[string]entities.Audience
GetAudienceMap returns the audience map
func (DatafileProjectConfig) GetBotFiltering ¶
func (c DatafileProjectConfig) GetBotFiltering() bool
GetBotFiltering returns botFiltering
func (DatafileProjectConfig) GetDatafile ¶
func (c DatafileProjectConfig) GetDatafile() string
GetDatafile returns a string representation of the environment's datafile
func (DatafileProjectConfig) GetEnvironmentKey ¶
func (c DatafileProjectConfig) GetEnvironmentKey() string
GetEnvironmentKey returns current environment of the datafile.
func (DatafileProjectConfig) GetEventByKey ¶
func (c DatafileProjectConfig) GetEventByKey(eventKey string) (entities.Event, error)
GetEventByKey returns the event with the given key
func (DatafileProjectConfig) GetEvents ¶
func (c DatafileProjectConfig) GetEvents() (eventList []entities.Event)
GetEvents returns all events
func (DatafileProjectConfig) GetExperimentByKey ¶
func (c DatafileProjectConfig) GetExperimentByKey(experimentKey string) (entities.Experiment, error)
GetExperimentByKey returns the experiment with the given key
func (DatafileProjectConfig) GetExperimentList ¶
func (c DatafileProjectConfig) GetExperimentList() (experimentList []entities.Experiment)
GetExperimentList returns an array of all the experiments
func (DatafileProjectConfig) GetFeatureByKey ¶
func (c DatafileProjectConfig) GetFeatureByKey(featureKey string) (entities.Feature, error)
GetFeatureByKey returns the feature with the given key
func (DatafileProjectConfig) GetFeatureList ¶
func (c DatafileProjectConfig) GetFeatureList() (featureList []entities.Feature)
GetFeatureList returns an array of all the features
func (DatafileProjectConfig) GetFlagVariationsMap ¶
func (c DatafileProjectConfig) GetFlagVariationsMap() map[string][]entities.Variation
GetFlagVariationsMap returns map containing all variations for each flag
func (DatafileProjectConfig) GetGroupByID ¶
func (c DatafileProjectConfig) GetGroupByID(groupID string) (entities.Group, error)
GetGroupByID returns the group with the given ID
func (DatafileProjectConfig) GetProjectID ¶
func (c DatafileProjectConfig) GetProjectID() string
GetProjectID returns projectID
func (DatafileProjectConfig) GetRevision ¶
func (c DatafileProjectConfig) GetRevision() string
GetRevision returns revision
func (DatafileProjectConfig) GetRolloutList ¶
func (c DatafileProjectConfig) GetRolloutList() (rolloutList []entities.Rollout)
GetRolloutList returns an array of all the rollouts
func (DatafileProjectConfig) GetSdkKey ¶
func (c DatafileProjectConfig) GetSdkKey() string
GetSdkKey returns sdkKey for specific environment.
func (DatafileProjectConfig) GetVariableByKey ¶
func (c DatafileProjectConfig) GetVariableByKey(featureKey, variableKey string) (entities.Variable, error)
GetVariableByKey returns the featureVariable with the given key
func (DatafileProjectConfig) SendFlagDecisions ¶
func (c DatafileProjectConfig) SendFlagDecisions() bool
SendFlagDecisions determines whether impressions events are sent for ALL decision types