Partager via


ColumnDefinition Class

  • java.lang.Object
    • com.azure.resourcemanager.monitor.models.ColumnDefinition

Implements

public final class ColumnDefinition
implements JsonSerializable<ColumnDefinition>

Definition of custom data column.

Constructor Summary

Constructor Description
ColumnDefinition()

Creates an instance of ColumnDefinition class.

Method Summary

Modifier and Type Method and Description
static ColumnDefinition fromJson(JsonReader jsonReader)

Reads an instance of ColumnDefinition from the JsonReader.

String name()

Get the name property: The name of the column.

JsonWriter toJson(JsonWriter jsonWriter)
KnownColumnDefinitionType type()

Get the type property: The type of the column data.

void validate()

Validates the instance.

ColumnDefinition withName(String name)

Set the name property: The name of the column.

ColumnDefinition withType(KnownColumnDefinitionType type)

Set the type property: The type of the column data.

Methods inherited from java.lang.Object

Constructor Details

ColumnDefinition

public ColumnDefinition()

Creates an instance of ColumnDefinition class.

Method Details

fromJson

public static ColumnDefinition fromJson(JsonReader jsonReader)

Reads an instance of ColumnDefinition from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of ColumnDefinition 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 ColumnDefinition.

name

public String name()

Get the name property: The name of the column.

Returns:

the name value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

type

public KnownColumnDefinitionType type()

Get the type property: The type of the column data.

Returns:

the type value.

validate

public void validate()

Validates the instance.

withName

public ColumnDefinition withName(String name)

Set the name property: The name of the column.

Parameters:

name - the name value to set.

Returns:

the ColumnDefinition object itself.

withType

public ColumnDefinition withType(KnownColumnDefinitionType type)

Set the type property: The type of the column data.

Parameters:

type - the type value to set.

Returns:

the ColumnDefinition object itself.

Applies to