Share via


Type functions

These functions create and manipulate type values.

Name Description
Type.AddTableKey Add a key to a table type.
Type.ClosedRecord The given type must be a record type returns a closed version of the given record type (or the same type, if it is already closed)
Type.Facets Returns the facets of a type.
Type.ForFunction Creates a function type from the given .
Type.ForRecord Returns a Record type from a fields record.
Type.FunctionParameters Returns a record with field values set to the name of the parameters of a function type, and their values set to their corresponding types.
Type.FunctionRequiredParameters Returns a number indicating the minimum number of parameters required to invoke the a type of function.
Type.FunctionReturn Returns a type returned by a function type.
Type.Is Determines if a value of the first type is always compatible with the second type.
Type.IsNullable Returns true if a type is a nullable type; otherwise, false.
Type.IsOpenRecord Returns whether a record type is open.
Type.ListItem Returns an item type from a list type.
Type.NonNullable Returns the non nullable type from a type.
Type.OpenRecord Returns an opened version of a record type, or the same type, if it is already open.
Type.RecordFields Returns a record describing the fields of a record type with each field of the returned record type having a corresponding name and a value that is a record of the form [ Type = type, Optional = logical ].
Type.ReplaceFacets Replaces the facets of a type.
Type.ReplaceTableKeys Replaces the keys in a table type.
Type.TableColumn Returns the type of a column in a table.
Type.TableKeys Returns keys from a table type.
Type.TableRow Returns a row type from a table type.
Type.TableSchema Returns a table containing a description of the columns (i.e. the schema) of the specified table type.
Type.Union Returns the union of a list of types.