PHP 클래스 Segment

파일 보기 프로젝트 열기: segmentio/analytics-php 1 사용 예제들

공개 메소드들

메소드 설명
alias ( array $message ) : boolean Aliases the user id from a temporary id to a permanent one
flush ( ) Flush the client
group ( array $message ) : boolean Tags traits about the group.
identify ( array $message ) : boolean Tags traits about the user.
init ( string $secret, array $options = [] ) Initializes the default client to use. Uses the socket consumer by default.
page ( array $message ) : boolean Tracks a page view
screen ( array $message ) : boolean Tracks a screen view
track ( array $message ) : boolean Tracks a user action
validate ( array $msg, string $type ) Validate common properties.

비공개 메소드들

메소드 설명
assert ( array $value, string $msg ) Assert value or throw.
checkClient ( ) Check the client.

메소드 상세

alias() 공개 정적인 메소드

Aliases the user id from a temporary id to a permanent one
public static alias ( array $message ) : boolean
$message array
리턴 boolean whether the alias call succeeded

flush() 공개 정적인 메소드

Flush the client
public static flush ( )

group() 공개 정적인 메소드

Tags traits about the group.
public static group ( array $message ) : boolean
$message array
리턴 boolean whether the group call succeeded

identify() 공개 정적인 메소드

Tags traits about the user.
public static identify ( array $message ) : boolean
$message array
리턴 boolean whether the identify call succeeded

init() 공개 정적인 메소드

Initializes the default client to use. Uses the socket consumer by default.
public static init ( string $secret, array $options = [] )
$secret string your project's secret key
$options array passed straight to the client

page() 공개 정적인 메소드

Tracks a page view
public static page ( array $message ) : boolean
$message array
리턴 boolean whether the page call succeeded

screen() 공개 정적인 메소드

Tracks a screen view
public static screen ( array $message ) : boolean
$message array
리턴 boolean whether the screen call succeeded

track() 공개 정적인 메소드

Tracks a user action
public static track ( array $message ) : boolean
$message array
리턴 boolean whether the track call succeeded

validate() 공개 정적인 메소드

Validate common properties.
public static validate ( array $msg, string $type )
$msg array
$type string