Table of Contents

Class WindowFunctionTypeExtensions

Namespace
Datafication.Core.Data
Assembly
Datafication.Core.dll

Helper methods for WindowFunctionType validation and metadata.

public static class WindowFunctionTypeExtensions
Inheritance
object
WindowFunctionTypeExtensions

Methods

GenerateColumnName(WindowFunctionType, string, int?)

Generates default result column name based on function type and parameters.

public static string GenerateColumnName(this WindowFunctionType type, string sourceColumn, int? parameter)

Parameters

type WindowFunctionType

The window function type

sourceColumn string

The source column name (may be null for RowNumber)

parameter int?

The window size or offset parameter (may be null)

Returns

string

A generated column name

GetDescription(WindowFunctionType)

Gets a human-readable description of the window function.

public static string GetDescription(this WindowFunctionType type)

Parameters

type WindowFunctionType

The window function type

Returns

string

A description string

RequiresNumericColumn(WindowFunctionType)

Determines if window function requires numeric column type.

public static bool RequiresNumericColumn(this WindowFunctionType type)

Parameters

type WindowFunctionType

The window function type

Returns

bool

True if numeric column is required, false otherwise

RequiresOffset(WindowFunctionType)

Determines if window function requires offset parameter.

public static bool RequiresOffset(this WindowFunctionType type)

Parameters

type WindowFunctionType

The window function type

Returns

bool

True if offset is required, false otherwise

RequiresPercentileParameter(WindowFunctionType)

Determines if window function requires percentile parameter.

public static bool RequiresPercentileParameter(this WindowFunctionType type)

Parameters

type WindowFunctionType

The window function type

Returns

bool

True if percentile parameter is required, false otherwise

RequiresSourceColumn(WindowFunctionType)

Determines if window function requires source column.

public static bool RequiresSourceColumn(this WindowFunctionType type)

Parameters

type WindowFunctionType

The window function type

Returns

bool

True if source column is required, false otherwise

RequiresWindowSize(WindowFunctionType)

Determines if window function requires window size parameter.

public static bool RequiresWindowSize(this WindowFunctionType type)

Parameters

type WindowFunctionType

The window function type

Returns

bool

True if window size is required, false otherwise