M

Entity.Set``1

Description:
Stores the value of the field in the entity.
Remarks:

The template parameter must match the type of the field (specified when creating the Schema) exactly; this method does not perform data type conversions. The types for containers are IList for arrays and IDictionary for maps.

This method only modifies your copy of the Entity. Store the Entity in an element or another Entity to save the new value. Write access check is not performed on each call to Set. Instead, write access is checked when you try to save the Entity in an Element or another Entity.

Overloads (4):
Set``1(Field,FieldType,ForgeTypeId)
public void Set<FieldType>(
	Field field,
	FieldType value,
	ForgeTypeId unitTypeId
)
  • field
    The field to update.
  • value
  • unitTypeId
    Identifier of the unit from which the value will be converted before storing. Must be compatible with the spec specified when creating the Schema.
Return Value Set