Parameter
Last updated on
Oct 27, 2023
Description
Gets metadata values for element(s) in an array.
Returns
Struct of array metadata values.
History
Added in ColdFusion (2016 release) Update 2
Category
See also
Syntax
ArrayGetMetaData(array)
Parameters
|
Description |
array |
The input array. |
Example
<cfscript> inputs = ["2500.12", 4.0, "Yes", "False", "339090", {"q1": "Yes"}, ["1","yes","3","no","null","null"]]; metadata={items: ["numeric", "integer", "string", "boolean", "string", {q1: {type:"string",ignore:false}}, {items: ["integer","boolean","string","string","string","null"]}]}; ArraySetMetaData(inputs,metadata); writeoutput(serializeJSON(inputs)); writedump(ArrayGetMetaData(inputs)); </cfscript>
Output