public class EventFactory extends Object
HoneyClient.buildEventFactory()
. Any properties declared on the EventFactory.Builder
take precedence
over ones from the original HoneyClient
instance.
An instance of EventFactory is immutable and threadsafe, but a modifiable copy can be obtained with copy()
.
Note: If you develop with Honeycomb SDKs in other programming languages, this Event Factory is usually simply called a "Builder".
Modifier and Type | Class | Description |
---|---|---|
static class |
EventFactory.Builder |
Helper class to construct an
EventFactory . |
Modifier and Type | Method | Description |
---|---|---|
EventFactory.Builder |
copy() |
Creates a builder for a new factory, pre-populated with the fields and settings of this factory instance,
that can be further customised.
|
Event |
createEvent() |
Returns an
Event populated with the settings and fields of this factory instance. |
void |
send(Map<String,?> fields) |
Provides a shortcut to sending an event by populating it with the settings and fields of this factory instance
and adding the provided map of fields.
|
public Event createEvent()
Event
populated with the settings and fields of this factory instance.public void send(Map<String,?> fields)
fields
- to provide to the event.IllegalArgumentException
- if client-side validation fails, see HoneyClient
's class
documentation for the "Event Validation" rules.public EventFactory.Builder copy()
Copyright © 2018 Honeycomb. All rights reserved.