Class ObservedEvent
java.lang.Object
com.azure.analytics.onlineexperimentation.models.ObservedEvent
- All Implemented Interfaces:
com.azure.json.JsonSerializable<ObservedEvent>
public final class ObservedEvent
extends Object
implements com.azure.json.JsonSerializable<ObservedEvent>
An event observed by a metric.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of ObservedEvent class.ObservedEvent(String eventName) Creates an instance of ObservedEvent class with the specified event name. -
Method Summary
Modifier and TypeMethodDescriptionstatic ObservedEventfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of ObservedEvent from the JsonReader.Get the eventName property: The name of the event.Get the filter property: [Optional] A condition to filter events.setEventName(String eventName) Set the eventName property: The name of the event.Set the filter property: [Optional] A condition to filter events.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
ObservedEvent
public ObservedEvent()Creates an instance of ObservedEvent class. -
ObservedEvent
Creates an instance of ObservedEvent class with the specified event name.- Parameters:
eventName- the name of the event.
-
-
Method Details
-
getEventName
Get the eventName property: The name of the event.- Returns:
- the eventName value.
-
setEventName
Set the eventName property: The name of the event.Required when create the resource.
- Parameters:
eventName- the eventName value to set.- Returns:
- the ObservedEvent object itself.
-
getFilter
Get the filter property: [Optional] A condition to filter events.- Returns:
- the filter value.
-
setFilter
Set the filter property: [Optional] A condition to filter events.- Parameters:
filter- the filter value to set.- Returns:
- the ObservedEvent object itself.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<ObservedEvent>- Throws:
IOException
-
fromJson
Reads an instance of ObservedEvent from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of ObservedEvent if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IOException- If an error occurs while reading the ObservedEvent.
-