Package com.segment.analytics.messages
Class TrackMessage
java.lang.Object
com.segment.analytics.messages.TrackMessage
- All Implemented Interfaces:
Message
public abstract class TrackMessage extends Object implements Message
The track API call is how you record any actions your users perform, along with any properties
that describe the action.
Use builder(java.lang.String)
to construct your own instances.
- See Also:
- Track
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
TrackMessage.Builder
Fluent API for creatingTrackMessage
instances.Nested classes/interfaces inherited from interface com.segment.analytics.messages.Message
Message.Type
-
Constructor Summary
Constructors Constructor Description TrackMessage()
-
Method Summary
Modifier and Type Method Description static TrackMessage.Builder
builder(String event)
Start building anTrackMessage
instance.abstract String
event()
abstract Map<String,?>
properties()
TrackMessage.Builder
toBuilder()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.segment.analytics.messages.Message
anonymousId, context, integrations, messageId, timestamp, type, userId
-
Constructor Details
-
TrackMessage
public TrackMessage()
-
-
Method Details
-
builder
Start building anTrackMessage
instance.- Parameters:
event
- The event is the name of the action that a user has performed.- Throws:
IllegalArgumentException
- if the event name is null or empty- See Also:
- Track Event
-
event
-
properties
-
toBuilder
-