coder.dictionary.Entry.set - Set value of code definition property - MATLAB (original) (raw)
Class: coder.dictionary.Entry
Namespace: coder.dictionary
Set value of code definition property
Syntax
set(entryObj,Name1,Value1,...,NameN,ValueN)
Description
set([entryObj](#mw%5Ff2a2e0fc-1916-44a3-bcd5-5bcc134fc32e),[Name1,Value1,...,NameN,ValueN](#mw%5F7faf4813-f249-4bb5-931a-c7aa969eb589))
sets the properties to the specified values for the Embedded Coder Dictionary definition thatentryObj
represents.
Input Arguments
Embedded Coder Dictionary entry that represents the code definition, specified as acoder.dictionary.Entry object. Before you use this function, represent the code definition by using a coder.dictionary.Entry
object. Use, for example, the addEntry function.
Property specifications for the definition, specified as one or more name-value pairs representing names and values of properties of the code definition. For a list of the properties of an Embedded Coder Dictionary definition, see coder.dictionary.Entry.
Example: 'MemorySection','memSect1'
Example: 'DataScope','Exported'
Examples
Open the model RollAxisAutopilot
and represent the Embedded Coder Dictionary by using a coder.Dictionary
object. Use this object to access the Storage Classes section of the dictionary and represent the section by using a coder.dictionary.Section
object.
openExample('RollAxisAutopilot') coderDictionary = coder.dictionary.open('RollAxisAutopilot'); storageClassesSect = getSection(coderDictionary, 'StorageClasses');
Represent the example storage class ParamStruct
by using acoder.dictionary.Entry
object.
entryObj = getEntry(storageClassesSect,'ParamStruct');
Change the value of the HeaderFile
property of the storage class definition from $N.h
to $N_params.h
.
set(entryObj,'HeaderFile','$N_params.h')
Version History
Introduced in R2019b