public class UuidJsonProvider<Event extends DeferredProcessingAware> extends AbstractFieldJsonProvider<Event>
| Modifier and Type | Field and Description |
|---|---|
static String |
FIELD_UUID |
static String |
STRATEGY_RANDOM
Type 4 UUID.
|
static String |
STRATEGY_TIME
Type 1 time based UUID.
|
context| Constructor and Description |
|---|
UuidJsonProvider() |
| Modifier and Type | Method and Description |
|---|---|
String |
getEthernet() |
String |
getStrategy() |
void |
setEthernet(String ethernet) |
void |
setStrategy(String strategy) |
void |
writeTo(JsonGenerator generator,
Event event)
Writes information about the event, to the given generator.
|
getFieldName, setFieldNameisStarted, prepareForDeferredProcessing, start, stopaddError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getDeclaredOrigin, getStatusManager, setContextclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, setContextpublic static final String FIELD_UUID
public static final String STRATEGY_RANDOM
public static final String STRATEGY_TIME
ethernet can be set to either 'interface' (to automatically pick a MAC address from a network interface)
or a MAC address string.public void writeTo(JsonGenerator generator, Event event) throws IOException
JsonProviderWhen called, the generator is assumed to be within a JSON object context (i.e. this provider should write fields and their values to the generator). Upon return, the generator should be within the same JSON object context.
generator - the JsonGenerator to produce JSON contentevent - the event to convert into JSONIOException - if an I/O error occurspublic String getStrategy()
public void setStrategy(String strategy)
public String getEthernet()
public void setEthernet(String ethernet)
Copyright © 2013–2021. All rights reserved.