CustomAlertRule Class

  • java.lang.Object
    • com.azure.resourcemanager.security.models.CustomAlertRule

Implements

public class CustomAlertRule
implements JsonSerializable<CustomAlertRule>

A custom alert rule.

Constructor Summary

Constructor Description
CustomAlertRule()

Creates an instance of CustomAlertRule class.

Method Summary

Modifier and Type Method and Description
String description()

Get the description property: The description of the custom alert.

String displayName()

Get the displayName property: The display name of the custom alert.

static CustomAlertRule fromJson(JsonReader jsonReader)

Reads an instance of CustomAlertRule from the JsonReader.

boolean isEnabled()

Get the isEnabled property: Status of the custom alert.

String ruleType()

Get the ruleType property: The type of the custom alert rule.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

CustomAlertRule withIsEnabled(boolean isEnabled)

Set the isEnabled property: Status of the custom alert.

Methods inherited from java.lang.Object

Constructor Details

CustomAlertRule

public CustomAlertRule()

Creates an instance of CustomAlertRule class.

Method Details

description

public String description()

Get the description property: The description of the custom alert.

Returns:

the description value.

displayName

public String displayName()

Get the displayName property: The display name of the custom alert.

Returns:

the displayName value.

fromJson

public static CustomAlertRule fromJson(JsonReader jsonReader)

Reads an instance of CustomAlertRule from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of CustomAlertRule if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

isEnabled

public boolean isEnabled()

Get the isEnabled property: Status of the custom alert.

Returns:

the isEnabled value.

ruleType

public String ruleType()

Get the ruleType property: The type of the custom alert rule.

Returns:

the ruleType value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

withIsEnabled

public CustomAlertRule withIsEnabled(boolean isEnabled)

Set the isEnabled property: Status of the custom alert.

Parameters:

isEnabled - the isEnabled value to set.

Returns:

the CustomAlertRule object itself.

Applies to