From bd0fe0ede228bc513a1238c88d8c87011b74856b Mon Sep 17 00:00:00 2001 From: lvlongxiang Date: Sun, 22 Dec 2024 14:13:59 +0000 Subject: [PATCH] address comment --- datafusion/functions-table/src/generate_series.rs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/datafusion/functions-table/src/generate_series.rs b/datafusion/functions-table/src/generate_series.rs index 711734c32ed2d..4187dcc0d31d2 100644 --- a/datafusion/functions-table/src/generate_series.rs +++ b/datafusion/functions-table/src/generate_series.rs @@ -30,20 +30,23 @@ use parking_lot::RwLock; use std::fmt; use std::sync::Arc; +/// Indicates the arguments used for generating a series. #[derive(Debug, Clone)] enum GenSeriesArgs { + /// ContainsNull signifies that at least one argument(start, end, and step) was null, thus no series will be generated. ContainsNull, + /// AllNotNullArgs holds the start, end, and step values for generating the series when all arguments are not null. AllNotNullArgs { start: i64, end: i64, step: i64 }, } -/// Table that generates a series of integers from `start`(inclusive) to `end`(inclusive) +/// Table that generates a series of integers from `start`(inclusive) to `end`(inclusive), incrementing by step #[derive(Debug, Clone)] struct GenerateSeriesTable { schema: SchemaRef, args: GenSeriesArgs, } -/// Table state that generates a series of integers from `start`(inclusive) to `end`(inclusive) +/// Table state that generates a series of integers from `start`(inclusive) to `end`(inclusive), incrementing by step #[derive(Debug, Clone)] struct GenerateSeriesState { schema: SchemaRef,