You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Our Java library lets you record analytics data from your Java code. The requests hit our servers, and then we route your data to any analytics service you enable on your destinations page.
8
+
Segment's Java library lets you record analytics data from your Java code. The requests hit Segment's servers, and then route your data to any analytics service you enable on your destinations page.
9
9
10
10
This library is open-source, so you can [check it out on GitHub](https://github.com/segmentio/analytics-java).
11
11
@@ -60,10 +60,17 @@ The following examples use [Guava's](https://github.com/google/guava) immutable
60
60
61
61
### Regional configuration
62
62
{% include content/regional-config.md %}
63
-
## Identify
64
63
65
-
> note ""
66
-
> **Good to know**: For any of the different methods described on this page, you can replace the properties and traits in the code samples with variables that represent the data collected.
64
+
65
+
## Basic tracking methods
66
+
The basic tracking methods below serve as the building blocks of your Segment tracking. They include [Identify](#identify), [Track](#track), [Page](#page), [Group](#group), and [Alias](#alias). These methods correspond with those used in the [Segment Spec](/docs/connections/spec/). The documentation on this page explains how to use these methods in Analytics for Java.
67
+
68
+
> info ""
69
+
> For any of the different methods described on this page, you can replace the properties and traits in the code samples with variables that represent the data collected.
70
+
>
71
+
> Note that sending a property or trait with a null value won't be possible as Guava's immutable maps will reject the null value and the GSON library used to serialize the Java object will ignore it. As a workaround, you can send an empty string instead of a null value in on your properties or traits.
72
+
73
+
### Identify
67
74
68
75
`identify` lets you tie a user to their actions and record traits about them. It includes a unique User ID and any optional traits you know about them.
69
76
@@ -101,7 +108,7 @@ Read more in our [transformer reference section](/docs/connections/sources/catal
101
108
102
109
Find details on the **identify method payload** in our [Spec](/docs/connections/spec/identify/).
103
110
104
-
## Track
111
+
###Track
105
112
106
113
`track` lets you record the actions your users perform. Every action triggers what we call an "event", which can also have associated properties.
107
114
@@ -144,7 +151,7 @@ The `track` call has the following fields:
144
151
145
152
Find details on **best practices in event naming** as well as the **`track` method payload** in our [Spec](/docs/connections/spec/track/).
146
153
147
-
## Screen
154
+
###Screen
148
155
149
156
The [`screen`](/docs/connections/spec/screen/) method lets you record whenever a user sees a screen of your mobile app, along with optional extra information about the screen being viewed.
150
157
@@ -184,7 +191,7 @@ The `screen` call has the following fields:
184
191
185
192
Find details on the **`screen` payload** in our [Spec](/docs/connections/spec/screen/).
186
193
187
-
## Page
194
+
###Page
188
195
189
196
The [`page`](/docs/connections/spec/page/) method lets you record whenever a user sees a page of your website, along with optional extra information about the page being viewed.
190
197
@@ -222,7 +229,7 @@ The `page` call has the following fields:
222
229
223
230
Find details on the **`page` payload** in our [Spec](/docs/connections/spec/page/).
224
231
225
-
## Group
232
+
###Group
226
233
227
234
`group` lets you associate an [identified user](/docs/connections/sources/catalog/libraries/server/java/#identify) user with a group. A group could be a company, organization, account, project or team! It also lets you record custom traits about the group, like industry or number of employees.
228
235
@@ -260,7 +267,7 @@ The `group` call has the following fields:
260
267
261
268
Find more details about `group`, including the **`group` payload**, in our [Spec](/docs/connections/spec/group/).
262
269
263
-
## Alias
270
+
###Alias
264
271
265
272
`alias` is how you associate one identity with another. This is an advanced method, but it is required to manage user identities successfully in *some* of our destinations.
0 commit comments