C# Class GoogleAnalyticsUtils.EventsReporter

Reports events using the provided analytics reporter.
Inheritance: IEventsReporter
Show file Open project: GoogleCloudPlatform/google-cloud-visualstudio Class Usage Examples

Public Methods

Method Description
EventsReporter ( IAnalyticsReporter reporter ) : System
ReportEvent ( string source, string eventType, string eventName, bool userLoggedIn, string projectNumber = null, string>.Dictionary metadata = null ) : void

Private Methods

Method Description
EscapeValue ( string value ) : string

Escapes a value so it can be included in the GA hit and being able to parse them again on the backend Only the ',', '=' and '\\' characters need to be escaped as those are the separators for the values, in the string.

GetHash ( string projectId ) : string
GetPageViewURI ( string eventType, string eventName ) : string
SerializeEventMetadata ( string>.Dictionary metadata ) : string
SerializeMetadataEntry ( string>.KeyValuePair entry ) : string

Method Details

EventsReporter() public method

public EventsReporter ( IAnalyticsReporter reporter ) : System
reporter IAnalyticsReporter
return System

ReportEvent() public method

public ReportEvent ( string source, string eventType, string eventName, bool userLoggedIn, string projectNumber = null, string>.Dictionary metadata = null ) : void
source string
eventType string
eventName string
userLoggedIn bool
projectNumber string
metadata string>.Dictionary
return void