Table of Contents

Class MySqlColumnCollection

Namespace
LfrlAnvil.MySql.Objects
Assembly
LfrlAnvil.MySql.dll

Represents a collection of SQL table columns.

public sealed class MySqlColumnCollection : SqlColumnCollection, ISqlColumnCollection, IReadOnlyCollection<ISqlColumn>, IEnumerable<ISqlColumn>, IEnumerable
Inheritance
MySqlColumnCollection
Implements
Inherited Members

Remarks

MySqlDialect implementation.

Properties

Table

Table that this collection belongs to.

public MySqlTable Table { get; }

Property Value

MySqlTable

Methods

CreateColumn(SqlColumnBuilder)

Creates a new SqlColumn instance.

protected override MySqlColumn CreateColumn(SqlColumnBuilder builder)

Parameters

builder SqlColumnBuilder

Source column builder.

Returns

MySqlColumn

New SqlColumn instance.

Get(string)

Returns a column with the provided name.

[Pure]
public MySqlColumn Get(string name)

Parameters

name string

Name of the column to return.

Returns

MySqlColumn

Existing column.

Exceptions

KeyNotFoundException

When column does not exist.

GetEnumerator()

Creates a new SqlObjectEnumerator<TSource, TDestination> instance for this collection.

[Pure]
public SqlObjectEnumerator<SqlColumn, MySqlColumn> GetEnumerator()

Returns

SqlObjectEnumerator<SqlColumn, MySqlColumn>

New SqlObjectEnumerator<TSource, TDestination> instance.

TryGet(string)

Attempts to return a column with the provided name.

[Pure]
public MySqlColumn? TryGet(string name)

Parameters

name string

Name of the column to return.

Returns

MySqlColumn

Existing column or null when column does not exist.