Partilhar via


RegistryUsage Class

  • java.lang.Object
    • com.azure.resourcemanager.containerregistry.models.RegistryUsage

Implements

public final class RegistryUsage
implements JsonSerializable<RegistryUsage>

The quota usage for a container registry.

Constructor Summary

Constructor Description
RegistryUsage()

Creates an instance of RegistryUsage class.

Method Summary

Modifier and Type Method and Description
Long currentValue()

Get the currentValue property: The current value of the usage.

static RegistryUsage fromJson(JsonReader jsonReader)

Reads an instance of RegistryUsage from the JsonReader.

Long limit()

Get the limit property: The limit of the usage.

String name()

Get the name property: The name of the usage.

JsonWriter toJson(JsonWriter jsonWriter)
RegistryUsageUnit unit()

Get the unit property: The unit of measurement.

void validate()

Validates the instance.

RegistryUsage withCurrentValue(Long currentValue)

Set the currentValue property: The current value of the usage.

RegistryUsage withLimit(Long limit)

Set the limit property: The limit of the usage.

RegistryUsage withName(String name)

Set the name property: The name of the usage.

RegistryUsage withUnit(RegistryUsageUnit unit)

Set the unit property: The unit of measurement.

Methods inherited from java.lang.Object

Constructor Details

RegistryUsage

public RegistryUsage()

Creates an instance of RegistryUsage class.

Method Details

currentValue

public Long currentValue()

Get the currentValue property: The current value of the usage.

Returns:

the currentValue value.

fromJson

public static RegistryUsage fromJson(JsonReader jsonReader)

Reads an instance of RegistryUsage from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

limit

public Long limit()

Get the limit property: The limit of the usage.

Returns:

the limit value.

name

public String name()

Get the name property: The name of the usage.

Returns:

the name value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

unit

public RegistryUsageUnit unit()

Get the unit property: The unit of measurement.

Returns:

the unit value.

validate

public void validate()

Validates the instance.

withCurrentValue

public RegistryUsage withCurrentValue(Long currentValue)

Set the currentValue property: The current value of the usage.

Parameters:

currentValue - the currentValue value to set.

Returns:

the RegistryUsage object itself.

withLimit

public RegistryUsage withLimit(Long limit)

Set the limit property: The limit of the usage.

Parameters:

limit - the limit value to set.

Returns:

the RegistryUsage object itself.

withName

public RegistryUsage withName(String name)

Set the name property: The name of the usage.

Parameters:

name - the name value to set.

Returns:

the RegistryUsage object itself.

withUnit

public RegistryUsage withUnit(RegistryUsageUnit unit)

Set the unit property: The unit of measurement.

Parameters:

unit - the unit value to set.

Returns:

the RegistryUsage object itself.

Applies to