Table of Contents

Struct SqlSchemaObjectName

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

Represents a name of an SQL object that may belong to an SQL schema.

public readonly struct SqlSchemaObjectName : IEquatable<SqlSchemaObjectName>
Implements
Inherited Members

Properties

Object

Name of this SQL object.

public string Object { get; }

Property Value

string

Schema

Name of the schema that this SQL object belongs to.

public string Schema { get; }

Property Value

string

Methods

Create(string)

Creates a new SqlSchemaObjectName instance with empty Schema.

[Pure]
public static SqlSchemaObjectName Create(string obj)

Parameters

obj string

Name of the SQL object.

Returns

SqlSchemaObjectName

New SqlSchemaObjectName instance.

Create(string, string)

Creates a new SqlSchemaObjectName instance.

[Pure]
public static SqlSchemaObjectName Create(string schema, string obj)

Parameters

schema string

Name of the schema that the SQL object belongs to.

obj string

Name of the SQL object.

Returns

SqlSchemaObjectName

New SqlSchemaObjectName instance.

Equals(SqlSchemaObjectName)

Indicates whether the current object is equal to another object of the same type.

[Pure]
public bool Equals(SqlSchemaObjectName other)

Parameters

other SqlSchemaObjectName

An object to compare with this object.

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

Equals(object?)

Indicates whether this instance and a specified object are equal.

[Pure]
public override bool Equals(object? obj)

Parameters

obj object

The object to compare with the current instance.

Returns

bool

true if obj and this instance are the same type and represent the same value; otherwise, false.

GetHashCode()

Returns the hash code for this instance.

[Pure]
public override int GetHashCode()

Returns

int

A 32-bit signed integer that is the hash code for this instance.

ToString()

Returns a string representation of this SqlSchemaObjectName instance.

[Pure]
public override string ToString()

Returns

string

String representation.

Operators

operator ==(SqlSchemaObjectName, SqlSchemaObjectName)

Checks if a is equal to b.

[Pure]
public static bool operator ==(SqlSchemaObjectName a, SqlSchemaObjectName b)

Parameters

a SqlSchemaObjectName

First operand.

b SqlSchemaObjectName

Second operand.

Returns

bool

true when operands are equal, otherwise false.

operator !=(SqlSchemaObjectName, SqlSchemaObjectName)

Checks if a is not equal to b.

[Pure]
public static bool operator !=(SqlSchemaObjectName a, SqlSchemaObjectName b)

Parameters

a SqlSchemaObjectName

First operand.

b SqlSchemaObjectName

Second operand.

Returns

bool

true when operands are not equal, otherwise false.