@DataSchema declarations

Edit pageLast modified: 16 June 2025

DataSchema can be used as an argument for cast and convertTo functions. It provides typed data access for raw dataframes you read from I/O sources and serves as a starting point for the compiler plugin to derive schema changes.

Example 1:

Generated code:

Example 2:

ColumnName annotation changes how generated extension properties pull the data from a dataframe:

Generated code:

Generated extension properties are used to access values in DataRow and to access columns in ColumnsScope, which is either DataFrame or ColumnSelectionDsl

DataRow:

DataFrame:

ColumnSelectionDsl: