com.microsoft.graph.beta.generated.models.Account Maven / Gradle / Ivy
package com.microsoft.graph.beta.models;
import com.microsoft.kiota.serialization.AdditionalDataHolder;
import com.microsoft.kiota.serialization.Parsable;
import com.microsoft.kiota.serialization.ParseNode;
import com.microsoft.kiota.serialization.SerializationWriter;
import com.microsoft.kiota.store.BackedModel;
import com.microsoft.kiota.store.BackingStore;
import com.microsoft.kiota.store.BackingStoreFactorySingleton;
import java.time.OffsetDateTime;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;
import java.util.UUID;
@jakarta.annotation.Generated("com.microsoft.kiota")
public class Account implements AdditionalDataHolder, BackedModel, Parsable {
/**
* Stores model information.
*/
@jakarta.annotation.Nonnull
protected BackingStore backingStore;
/**
* Instantiates a new {@link Account} and sets the default values.
*/
public Account() {
this.backingStore = BackingStoreFactorySingleton.instance.createBackingStore();
this.setAdditionalData(new HashMap<>());
}
/**
* Creates a new instance of the appropriate class based on discriminator value
* @param parseNode The parse node to use to read the discriminator value and create the object
* @return a {@link Account}
*/
@jakarta.annotation.Nonnull
public static Account createFromDiscriminatorValue(@jakarta.annotation.Nonnull final ParseNode parseNode) {
Objects.requireNonNull(parseNode);
return new Account();
}
/**
* Gets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
* @return a {@link Map}
*/
@jakarta.annotation.Nonnull
public Map getAdditionalData() {
Map value = this.backingStore.get("additionalData");
if(value == null) {
value = new HashMap<>();
this.setAdditionalData(value);
}
return value;
}
/**
* Gets the backingStore property value. Stores model information.
* @return a {@link BackingStore}
*/
@jakarta.annotation.Nonnull
public BackingStore getBackingStore() {
return this.backingStore;
}
/**
* Gets the blocked property value. The blocked property
* @return a {@link Boolean}
*/
@jakarta.annotation.Nullable
public Boolean getBlocked() {
return this.backingStore.get("blocked");
}
/**
* Gets the category property value. The category property
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getCategory() {
return this.backingStore.get("category");
}
/**
* Gets the displayName property value. The displayName property
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getDisplayName() {
return this.backingStore.get("displayName");
}
/**
* The deserialization information for the current model
* @return a {@link Map>}
*/
@jakarta.annotation.Nonnull
public Map> getFieldDeserializers() {
final HashMap> deserializerMap = new HashMap>(8);
deserializerMap.put("blocked", (n) -> { this.setBlocked(n.getBooleanValue()); });
deserializerMap.put("category", (n) -> { this.setCategory(n.getStringValue()); });
deserializerMap.put("displayName", (n) -> { this.setDisplayName(n.getStringValue()); });
deserializerMap.put("id", (n) -> { this.setId(n.getUUIDValue()); });
deserializerMap.put("lastModifiedDateTime", (n) -> { this.setLastModifiedDateTime(n.getOffsetDateTimeValue()); });
deserializerMap.put("number", (n) -> { this.setNumber(n.getStringValue()); });
deserializerMap.put("@odata.type", (n) -> { this.setOdataType(n.getStringValue()); });
deserializerMap.put("subCategory", (n) -> { this.setSubCategory(n.getStringValue()); });
return deserializerMap;
}
/**
* Gets the id property value. The id property
* @return a {@link UUID}
*/
@jakarta.annotation.Nullable
public UUID getId() {
return this.backingStore.get("id");
}
/**
* Gets the lastModifiedDateTime property value. The lastModifiedDateTime property
* @return a {@link OffsetDateTime}
*/
@jakarta.annotation.Nullable
public OffsetDateTime getLastModifiedDateTime() {
return this.backingStore.get("lastModifiedDateTime");
}
/**
* Gets the number property value. The number property
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getNumber() {
return this.backingStore.get("number");
}
/**
* Gets the @odata.type property value. The OdataType property
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getOdataType() {
return this.backingStore.get("odataType");
}
/**
* Gets the subCategory property value. The subCategory property
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getSubCategory() {
return this.backingStore.get("subCategory");
}
/**
* Serializes information the current object
* @param writer Serialization writer to use to serialize this model
*/
public void serialize(@jakarta.annotation.Nonnull final SerializationWriter writer) {
Objects.requireNonNull(writer);
writer.writeBooleanValue("blocked", this.getBlocked());
writer.writeStringValue("category", this.getCategory());
writer.writeStringValue("displayName", this.getDisplayName());
writer.writeUUIDValue("id", this.getId());
writer.writeOffsetDateTimeValue("lastModifiedDateTime", this.getLastModifiedDateTime());
writer.writeStringValue("number", this.getNumber());
writer.writeStringValue("@odata.type", this.getOdataType());
writer.writeStringValue("subCategory", this.getSubCategory());
writer.writeAdditionalData(this.getAdditionalData());
}
/**
* Sets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
* @param value Value to set for the AdditionalData property.
*/
public void setAdditionalData(@jakarta.annotation.Nullable final Map value) {
this.backingStore.set("additionalData", value);
}
/**
* Sets the backingStore property value. Stores model information.
* @param value Value to set for the backingStore property.
*/
public void setBackingStore(@jakarta.annotation.Nonnull final BackingStore value) {
Objects.requireNonNull(value);
this.backingStore = value;
}
/**
* Sets the blocked property value. The blocked property
* @param value Value to set for the blocked property.
*/
public void setBlocked(@jakarta.annotation.Nullable final Boolean value) {
this.backingStore.set("blocked", value);
}
/**
* Sets the category property value. The category property
* @param value Value to set for the category property.
*/
public void setCategory(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("category", value);
}
/**
* Sets the displayName property value. The displayName property
* @param value Value to set for the displayName property.
*/
public void setDisplayName(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("displayName", value);
}
/**
* Sets the id property value. The id property
* @param value Value to set for the id property.
*/
public void setId(@jakarta.annotation.Nullable final UUID value) {
this.backingStore.set("id", value);
}
/**
* Sets the lastModifiedDateTime property value. The lastModifiedDateTime property
* @param value Value to set for the lastModifiedDateTime property.
*/
public void setLastModifiedDateTime(@jakarta.annotation.Nullable final OffsetDateTime value) {
this.backingStore.set("lastModifiedDateTime", value);
}
/**
* Sets the number property value. The number property
* @param value Value to set for the number property.
*/
public void setNumber(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("number", value);
}
/**
* Sets the @odata.type property value. The OdataType property
* @param value Value to set for the @odata.type property.
*/
public void setOdataType(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("odataType", value);
}
/**
* Sets the subCategory property value. The subCategory property
* @param value Value to set for the subCategory property.
*/
public void setSubCategory(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("subCategory", value);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy