StructEach

Used to iterate over a struct and run the function closure for each key/value pair.

Method Signature

StructEach(struct=[structloose], callback=[function], parallel=[boolean], maxThreads=[integer], ordered=[boolean])

Arguments

ArgumentTypeRequiredDescriptionDefault

struct

struct

true

The target struct to iterate

callback

function

true

The function to invoke for each item. The function will be passed 3 arguments: the key, the value, the struct.

parallel

boolean

false

Specifies whether the items can be executed in parallel

false

maxThreads

integer

false

The maximum number of threads to use when parallel = true

ordered

boolean

false

(BoxLang only) whether parallel operations should execute and maintain order

false

Examples

Last updated

Logo

Copyright & Register Trademark by Ortus Solutions, Corp & Ortus Software, LLC