analytics

Version: stable

FUNCTION
init()
log_string()
log_int()
log_number()
log_table()
set_screen()
set_user_id()
set_user_property()
reset()
get_id()

Functions

init()

init()

Initialise analytics

PARAMETERS

None


log_string()

log_string(name,PARAMeter_name,PARAMeter_value)

Log an event with one string parameter. (Official docs https://firebase.google.com/docs/reference/cpp/namespace/firebase/logevent)

PARAMETERS

name string Event name
PARAMeter_name string Parameter name
PARAMeter_value string Parameter value

log_int()

log_int(name,PARAMeter_name,PARAMeter_value)

Log an event with one integer parameter. (Official docs https://firebase.google.com/docs/reference/cpp/namespace/firebase/logevent_4)

PARAMETERS

name string Event name
PARAMeter_name string Parameter name
PARAMeter_value number Parameter value

log_number()

log_number(name,PARAMeter_name,PARAMeter_value)

Log an event with one float parameter. (Official docs https://firebase.google.com/docs/reference/cpp/namespace/firebase/logevent_2)

PARAMETERS

name string Event name
PARAMeter_name string Parameter name
PARAMeter_value number Parameter value

log_table()

log_table(name,PARAMeters_table)

Log an event with table parameters. (Official docs https://firebase.google.com/docs/reference/cpp/namespace/firebase/logevent_6)

PARAMETERS

name string Event name
PARAMeters_table table Table with parameters (key-value pairs)

set_screen()

set_screen()

DEPRECATED. Use log_string(analytics.EVENT_SCREENVIEW, "screen name", "screen class").

PARAMETERS

None


set_user_id()

set_user_id(user_id)

Sets the user ID property. (Official docs https://firebase.google.com/docs/reference/cpp/namespace/firebase/setuserid)

PARAMETERS

user_id string User ID property

set_user_property()

set_user_property(name,property)

Set a user property to the given value. (Official docs https://firebase.google.com/docs/reference/cpp/namespace/firebase/setuserproperty)

PARAMETERS

name string User property name
property string User property value

reset()

reset()

Clears all data for this app from the device and resets the app instance id. (Official docs https://firebase.google.com/docs/reference/cpp/namespace/firebase/resetata)

PARAMETERS

None


get_id()

get_id(callback)

Get the instance ID from the service. (Official docs https://firebase.google.com/docs/reference/cpp/namespace/firebase/getnstanceid)

PARAMETERS

callback function Function to invoke with the id (self, id)