PHP Class SeatGeek\Sixpack\Session\Base

Afficher le fichier Open project: seatgeek/sixpack-php

Protected Properties

Свойство Type Description
$baseUrl configuration
$clientId
$cookiePrefix
$timeout

Méthodes publiques

Méthode Description
__construct ( $options = [] )
convert ( string $experiment, mixed $kpi = null ) : SeatGeek\Sixpack\Response\Conversion convert
getClientid ( )
getTimeout ( )
isForced ( $experiment )
participate ( string $experiment, array $alternatives, $traffic_fraction = 1 ) : SeatGeek\Sixpack\Response\Participation Participate in an experiment
setTimeout ( $milliseconds )
status ( )

Méthodes protégées

Méthode Description
forceAlternative ( string $experiment, array $alternatives ) : array Force the alternative
generateClientId ( )
getIpAddress ( )
getUserAgent ( )
retrieveClientId ( )
sendRequest ( string $endpoint, array $params = [] ) : array Send the request to sixpack
setClientId ( $clientId = null )
storeClientId ( $clientId )

Method Details

__construct() public méthode

public __construct ( $options = [] )

convert() public méthode

convert
public convert ( string $experiment, mixed $kpi = null ) : SeatGeek\Sixpack\Response\Conversion
$experiment string
$kpi mixed
Résultat SeatGeek\Sixpack\Response\Conversion

forceAlternative() protected méthode

Force the alternative
protected forceAlternative ( string $experiment, array $alternatives ) : array
$experiment string
$alternatives array
Résultat array

generateClientId() protected méthode

protected generateClientId ( )

getClientid() public méthode

public getClientid ( )

getIpAddress() protected méthode

protected getIpAddress ( )

getTimeout() public méthode

public getTimeout ( )

getUserAgent() protected méthode

protected getUserAgent ( )

isForced() public méthode

public isForced ( $experiment )

participate() public méthode

Participate in an experiment
public participate ( string $experiment, array $alternatives, $traffic_fraction = 1 ) : SeatGeek\Sixpack\Response\Participation
$experiment string name of the experiment
$alternatives array the alternatives to pick from
Résultat SeatGeek\Sixpack\Response\Participation

retrieveClientId() protected méthode

protected retrieveClientId ( )

sendRequest() protected méthode

Send the request to sixpack
protected sendRequest ( string $endpoint, array $params = [] ) : array
$endpoint string api end point
$params array
Résultat array

setClientId() protected méthode

protected setClientId ( $clientId = null )

setTimeout() public méthode

public setTimeout ( $milliseconds )

status() public méthode

public status ( )

storeClientId() protected méthode

protected storeClientId ( $clientId )

Property Details

$baseUrl protected_oe property

configuration
protected $baseUrl

$clientId protected_oe property

protected $clientId

$cookiePrefix protected_oe property

protected $cookiePrefix

$timeout protected_oe property

protected $timeout