com.microsoft.graph.beta.generated.models.EducationModule Maven / Gradle / Ivy
package com.microsoft.graph.beta.models;
import com.microsoft.kiota.serialization.Parsable;
import com.microsoft.kiota.serialization.ParseNode;
import com.microsoft.kiota.serialization.SerializationWriter;
import java.time.OffsetDateTime;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;
@jakarta.annotation.Generated("com.microsoft.kiota")
public class EducationModule extends Entity implements Parsable {
/**
* Instantiates a new {@link EducationModule} and sets the default values.
*/
public EducationModule() {
super();
}
/**
* 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 EducationModule}
*/
@jakarta.annotation.Nonnull
public static EducationModule createFromDiscriminatorValue(@jakarta.annotation.Nonnull final ParseNode parseNode) {
Objects.requireNonNull(parseNode);
return new EducationModule();
}
/**
* Gets the createdBy property value. The display name of the user that created the module.
* @return a {@link IdentitySet}
*/
@jakarta.annotation.Nullable
public IdentitySet getCreatedBy() {
return this.backingStore.get("createdBy");
}
/**
* Gets the createdDateTime property value. Date time the module was created. The timestamp type represents date and time information using ISO 8601 format and is always in UTC. For example, midnight UTC on Jan 1, 2014, is 2014-01-01T00:00:00Z
* @return a {@link OffsetDateTime}
*/
@jakarta.annotation.Nullable
public OffsetDateTime getCreatedDateTime() {
return this.backingStore.get("createdDateTime");
}
/**
* Gets the description property value. Description of the module.
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getDescription() {
return this.backingStore.get("description");
}
/**
* Gets the displayName property value. Name of the module.
* @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>(super.getFieldDeserializers());
deserializerMap.put("createdBy", (n) -> { this.setCreatedBy(n.getObjectValue(IdentitySet::createFromDiscriminatorValue)); });
deserializerMap.put("createdDateTime", (n) -> { this.setCreatedDateTime(n.getOffsetDateTimeValue()); });
deserializerMap.put("description", (n) -> { this.setDescription(n.getStringValue()); });
deserializerMap.put("displayName", (n) -> { this.setDisplayName(n.getStringValue()); });
deserializerMap.put("isPinned", (n) -> { this.setIsPinned(n.getBooleanValue()); });
deserializerMap.put("lastModifiedBy", (n) -> { this.setLastModifiedBy(n.getObjectValue(IdentitySet::createFromDiscriminatorValue)); });
deserializerMap.put("lastModifiedDateTime", (n) -> { this.setLastModifiedDateTime(n.getOffsetDateTimeValue()); });
deserializerMap.put("resources", (n) -> { this.setResources(n.getCollectionOfObjectValues(EducationModuleResource::createFromDiscriminatorValue)); });
deserializerMap.put("resourcesFolderUrl", (n) -> { this.setResourcesFolderUrl(n.getStringValue()); });
deserializerMap.put("status", (n) -> { this.setStatus(n.getEnumValue(EducationModuleStatus::forValue)); });
return deserializerMap;
}
/**
* Gets the isPinned property value. Indicates whether the module is pinned or not.
* @return a {@link Boolean}
*/
@jakarta.annotation.Nullable
public Boolean getIsPinned() {
return this.backingStore.get("isPinned");
}
/**
* Gets the lastModifiedBy property value. The last user that modified the module.
* @return a {@link IdentitySet}
*/
@jakarta.annotation.Nullable
public IdentitySet getLastModifiedBy() {
return this.backingStore.get("lastModifiedBy");
}
/**
* Gets the lastModifiedDateTime property value. Date time the module was last modified. The timestamp type represents date and time information using ISO 8601 format and is always in UTC. For example, midnight UTC on Jan 1, 2014, is 2014-01-01T00:00:00Z
* @return a {@link OffsetDateTime}
*/
@jakarta.annotation.Nullable
public OffsetDateTime getLastModifiedDateTime() {
return this.backingStore.get("lastModifiedDateTime");
}
/**
* Gets the resources property value. Learning objects that are associated with this module. Only teachers can modify this list. Nullable.
* @return a {@link java.util.List}
*/
@jakarta.annotation.Nullable
public java.util.List getResources() {
return this.backingStore.get("resources");
}
/**
* Gets the resourcesFolderUrl property value. Folder URL where all the file resources for this module are stored.
* @return a {@link String}
*/
@jakarta.annotation.Nullable
public String getResourcesFolderUrl() {
return this.backingStore.get("resourcesFolderUrl");
}
/**
* Gets the status property value. Status of the module. You can't use a PATCH operation to update this value. Possible values are: draft and published.
* @return a {@link EducationModuleStatus}
*/
@jakarta.annotation.Nullable
public EducationModuleStatus getStatus() {
return this.backingStore.get("status");
}
/**
* 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);
super.serialize(writer);
writer.writeStringValue("description", this.getDescription());
writer.writeStringValue("displayName", this.getDisplayName());
writer.writeBooleanValue("isPinned", this.getIsPinned());
writer.writeCollectionOfObjectValues("resources", this.getResources());
}
/**
* Sets the createdBy property value. The display name of the user that created the module.
* @param value Value to set for the createdBy property.
*/
public void setCreatedBy(@jakarta.annotation.Nullable final IdentitySet value) {
this.backingStore.set("createdBy", value);
}
/**
* Sets the createdDateTime property value. Date time the module was created. The timestamp type represents date and time information using ISO 8601 format and is always in UTC. For example, midnight UTC on Jan 1, 2014, is 2014-01-01T00:00:00Z
* @param value Value to set for the createdDateTime property.
*/
public void setCreatedDateTime(@jakarta.annotation.Nullable final OffsetDateTime value) {
this.backingStore.set("createdDateTime", value);
}
/**
* Sets the description property value. Description of the module.
* @param value Value to set for the description property.
*/
public void setDescription(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("description", value);
}
/**
* Sets the displayName property value. Name of the module.
* @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 isPinned property value. Indicates whether the module is pinned or not.
* @param value Value to set for the isPinned property.
*/
public void setIsPinned(@jakarta.annotation.Nullable final Boolean value) {
this.backingStore.set("isPinned", value);
}
/**
* Sets the lastModifiedBy property value. The last user that modified the module.
* @param value Value to set for the lastModifiedBy property.
*/
public void setLastModifiedBy(@jakarta.annotation.Nullable final IdentitySet value) {
this.backingStore.set("lastModifiedBy", value);
}
/**
* Sets the lastModifiedDateTime property value. Date time the module was last modified. The timestamp type represents date and time information using ISO 8601 format and is always in UTC. For example, midnight UTC on Jan 1, 2014, is 2014-01-01T00:00:00Z
* @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 resources property value. Learning objects that are associated with this module. Only teachers can modify this list. Nullable.
* @param value Value to set for the resources property.
*/
public void setResources(@jakarta.annotation.Nullable final java.util.List value) {
this.backingStore.set("resources", value);
}
/**
* Sets the resourcesFolderUrl property value. Folder URL where all the file resources for this module are stored.
* @param value Value to set for the resourcesFolderUrl property.
*/
public void setResourcesFolderUrl(@jakarta.annotation.Nullable final String value) {
this.backingStore.set("resourcesFolderUrl", value);
}
/**
* Sets the status property value. Status of the module. You can't use a PATCH operation to update this value. Possible values are: draft and published.
* @param value Value to set for the status property.
*/
public void setStatus(@jakarta.annotation.Nullable final EducationModuleStatus value) {
this.backingStore.set("status", value);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy