Show / Hide Table of Contents

Class Chess

This class contains static methods useful when dealing with chess

Inheritance
System.Object
Chess
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: PonzianiComponents.Chesslib
Assembly: PonzianiComponents.dll
Syntax
public class Chess

Properties

| Improve this Doc View Source

SupportedLanguages

List of supported languages

Declaration
public static List<string> SupportedLanguages { get; }
Property Value
Type Description
System.Collections.Generic.List<System.String>

Methods

| Improve this Doc View Source

GetColor(Piece)

Determines the color of a piecce

Declaration
public static Side GetColor(Piece piece)
Parameters
Type Name Description
Piece piece

The piece

Returns
Type Description
Side

The color of the piece

| Improve this Doc View Source

GetPiece(PieceType, Side)

Creates a Piece from PieceType and Side

Declaration
public static Piece GetPiece(PieceType pt, Side side)
Parameters
Type Name Description
PieceType pt

Piece Type

Side side

Side

Returns
Type Description
Piece

Piece

| Improve this Doc View Source

GetPieceType(Piece)

Provides the type of a given piece

Declaration
public static PieceType GetPieceType(Piece piece)
Parameters
Type Name Description
Piece piece

A chess piece

Returns
Type Description
PieceType

The type of this chess piece

| Improve this Doc View Source

ParsePieceTypeChar(Char)

Parses a PieceType Character ('Q', 'R', 'B', 'N', 'K' or 'P')

Declaration
public static PieceType ParsePieceTypeChar(char piecetypechar)
Parameters
Type Name Description
System.Char piecetypechar

The Piece type character

Returns
Type Description
PieceType

the piece type value

| Improve this Doc View Source

SquareToString(Square)

Get's the string representation (e.g. "a1" or "d5") of a square

Declaration
public static string SquareToString(Square square)
Parameters
Type Name Description
Square square

The square

Returns
Type Description
System.String

The square's string representation

  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX