Table of Contents

Struct SqlParameterizedScalarQueryReaderExecutor

Namespace
LfrlAnvil.Sql.Statements
Assembly
LfrlAnvil.Sql.Core.dll

Represents an SqlScalarQueryReaderExecutor bound to an SqlParameterBinder instance.

public readonly record struct SqlParameterizedScalarQueryReaderExecutor : IEquatable<SqlParameterizedScalarQueryReaderExecutor>
Implements
Inherited Members

Constructors

SqlParameterizedScalarQueryReaderExecutor(SqlParameterBinder, SqlScalarQueryReaderExecutor)

Represents an SqlScalarQueryReaderExecutor bound to an SqlParameterBinder instance.

public SqlParameterizedScalarQueryReaderExecutor(SqlParameterBinder ParameterBinder, SqlScalarQueryReaderExecutor Reader)

Parameters

ParameterBinder SqlParameterBinder

Underlying parameter binder.

Reader SqlScalarQueryReaderExecutor

Underlying query reader.

Properties

ParameterBinder

Underlying parameter binder.

public SqlParameterBinder ParameterBinder { get; init; }

Property Value

SqlParameterBinder

Reader

Underlying query reader.

public SqlScalarQueryReaderExecutor Reader { get; init; }

Property Value

SqlScalarQueryReaderExecutor

Methods

Execute(IDbCommand, IEnumerable<SqlParameter>?)

Creates an IDataReader instance and reads a scalar value, using the given parameters.

[Pure]
public SqlScalarQueryResult Execute(IDbCommand command, IEnumerable<SqlParameter>? parameters)

Parameters

command IDbCommand

IDbCommand to read from.

parameters IEnumerable<SqlParameter>

Source of parameters to bind.

Returns

SqlScalarQueryResult

Returns a read scalar value.