Function to find layers in the specified layer. For example,
this.parent specifies the parent layer of the script module as the layer to be searched in. If recursive is set to
true, sublayers will also be searched. The function returns an array with the Layer objects of the found layers. Particular layers can be searched by name or through a filter function. If searching by name, findLayers accepts only the Layer objects that match the specified name. The filter function uses the Layer object of each layer as argument. Only those Layer objects that return
true for the search criteria defined in the filter function will be accepted by findLayers. Without a name or filter function the Layer objects of all layers in the searched layers will be returned.
Available in: Controller, Processor.
|recursive||If set to ||boolean|
|nameOrFilterFunction||The name of the layers searched for or a filter function. Only the Layer objects that match the name or return ||string or function, optional|
Returns an array with the Layer objects of the found layers. Returns an empty table if no layers are found.