Data-Mate: `Function Configs Interfaces Function Definition Example`
function-configs/interfaces.FunctionDefinitionExample
Type parameters
Name | Type |
---|---|
T | extends Record <string , any > |
O | unknown |
Table of contents
Properties
Properties
args
• Readonly
args: T
The example arguments passed to the function
Defined in
data-mate/src/function-configs/interfaces.ts:41
config
• Readonly
config: Readonly
<Overwrite
<DataTypeConfig
, { fields
: ReadonlyDataTypeFields
}>>
The example data type config and children
Defined in
data-mate/src/function-configs/interfaces.ts:46
description
• Optional
Readonly
description: string
Optionally describe the behavior of this example
Defined in
data-mate/src/function-configs/interfaces.ts:83
fails
• Optional
Readonly
fails: boolean
If this is set to true, the output is not required. If output is specified it should be the error message
Defined in
data-mate/src/function-configs/interfaces.ts:78
field
• Optional
Readonly
field: string
The field to validate against and get the config for. Only required for field operations;
Defined in
data-mate/src/function-configs/interfaces.ts:52
input
• Readonly
input: unknown
An example input value that will be pretty printed for documentation.
Note
this is only a single value
Defined in
data-mate/src/function-configs/interfaces.ts:58
output
• Optional
Readonly
output: O
The outputted value that will be pretty printed for documentation. In the case of validators, this should be either the input or null (which indicates it is invalid)
Defined in
data-mate/src/function-configs/interfaces.ts:65
serialize_output
• Optional
Readonly
serialize_output: (output
: O
) => unknown
Type declaration
▸ (output
): unknown
Serialize the output for documentation or the function adapter. In the functionTestHarness this won't be called out the result from the dataFrameAdapter
Parameters
Name | Type |
---|---|
output | O |
Returns
unknown
Defined in
data-mate/src/function-configs/interfaces.ts:72
test_only
• Optional
Readonly
test_only: boolean
Setting this to true will be exclude it from the documentation