Back to FabImage Library website

You are here: Start » Function Reference » All Functions » Array Basics » FisFilter_GetRandomElements

FisFilter_GetRandomElements


This is Filter Equivalent. This function may be present in generated code, but should not be used in hand-written code.

Header: STD.h
Namespace: fis
Module: FoundationLite

Get random array elements with repeating values or not.

Syntax

void fis::FisFilter_GetRandomElements
(
	const ftl::Array<Type>& inArray,
	const int inCount,
	const bool inUniqueIndex,
	ftl::Optional<int> inSeed,
	ftl::Array<Type>& outArray
)

Parameters

Name Type Range Default Description
Input value inArray const Array<Type>& Input array
Input value inCount const int 0 - Number or selected records
Input value inUniqueIndex const bool False Flag implying select unique indices
Input value inSeed Optional<int> NIL Random seed used to generate values
Output value outArray Array<Type>& Output array

Errors

List of possible exceptions:

Error type Description
DomainError Negative inCount in GetRandomElements.
DomainError Not enough items in the input array in GetRandomElements.