Index
All Classes and Interfaces|All Packages|Serialized Form
A
- A1 - Enum constant in enum class chessapi4j.Square
-
a1 square
- A2 - Enum constant in enum class chessapi4j.Square
-
a2 square
- A3 - Enum constant in enum class chessapi4j.Square
-
a3 square
- A4 - Enum constant in enum class chessapi4j.Square
-
a4 square
- A5 - Enum constant in enum class chessapi4j.Square
-
a5 square
- A6 - Enum constant in enum class chessapi4j.Square
-
a6 square
- A7 - Enum constant in enum class chessapi4j.Square
-
a7 square
- A8 - Enum constant in enum class chessapi4j.Square
-
a8 square
- addMove(Move) - Method in class chessapi4j.Game
-
Add the move to the game and returns the last position.
- addMove(String) - Method in class chessapi4j.Game
-
Adds a move to the game.
- addMoves(List<? extends Move>) - Method in class chessapi4j.functional.Game
-
Adds a list of moves to the game instance.
- AdvanceUtil - Class in chessapi4j
-
Low-level utilities that are not entirely safe but very fast.
- and(Bitboard...) - Static method in class chessapi4j.Bitboard
-
Apply the "and bit to bit" operation over the values of the bitboards and retrieves a new
Bitboard
object that wraps the result of this operation. - AWARE - Enum constant in enum class chessapi4j.functional.Game.RepetitionsMode
-
Consider repetitions but do not set the result tag.
B
- B1 - Enum constant in enum class chessapi4j.Square
-
b1 square
- B2 - Enum constant in enum class chessapi4j.Square
-
b2 square
- B3 - Enum constant in enum class chessapi4j.Square
-
b3 square
- B4 - Enum constant in enum class chessapi4j.Square
-
b4 square
- B5 - Enum constant in enum class chessapi4j.Square
-
b5 square
- B6 - Enum constant in enum class chessapi4j.Square
-
b6 square
- B7 - Enum constant in enum class chessapi4j.Square
-
b7 square
- B8 - Enum constant in enum class chessapi4j.Square
-
b8 square
- BB - Enum constant in enum class chessapi4j.Piece
-
Black bishop
- BISHOP_DIRECTIONS - Static variable in class chessapi4j.Util
-
This array indicates the directions in which the bishop can move according to the ordinal indices of the
MoveDirection
enum class. - Bitboard - Class in chessapi4j
-
Wrapped bitboard class for some debugging or experimenting purposes.
- Bitboard() - Constructor for class chessapi4j.Bitboard
-
Creates an empty wrapped bitboard
- Bitboard(long) - Constructor for class chessapi4j.Bitboard
-
Wrap the given value.
- Bitboard(Bitboard) - Constructor for class chessapi4j.Bitboard
-
Copy constructor.
- Bitboard(Square...) - Constructor for class chessapi4j.Bitboard
-
Constructs a bitboard from the given array of squares.
- bitboardMove() - Method in class chessapi4j.functional.Move
-
Wrapped bitboard representing the move.
- bitboardMove() - Method in class chessapi4j.Move
-
Wrapped bitboard representing the move.
- bitboards() - Method in class chessapi4j.functional.Position
-
Returns the bitboards representing this position as an array of longs.
- bk() - Method in class chessapi4j.functional.Position
-
Returns the black castle kingside right as a long, meaning 1 that black can castle kingside and 0 that black can not castle kingside.
- bk() - Method in class chessapi4j.Position
-
Returns the black short castle rights as a long.
- BK - Enum constant in enum class chessapi4j.Piece
-
Black king
- black(String) - Method in class chessapi4j.functional.Game.Builder
-
Sets the black tag.
- BLACK - Enum constant in enum class chessapi4j.Side
-
Black side
- blackCastleKingside() - Method in class chessapi4j.functional.Position
-
Returns true if black can castle kingside, false otherwise.
- blackCastleQueenside() - Method in class chessapi4j.functional.Position
-
Returns true if black can castle queenside, false otherwise.
- BN - Enum constant in enum class chessapi4j.Piece
-
Black knight
- BP - Enum constant in enum class chessapi4j.Piece
-
Black pawn
- bq() - Method in class chessapi4j.functional.Position
-
Returns the black castle queenside right as a long, meaning 1 that black can castle queenside and 0 that black can not castle queenside.
- bq() - Method in class chessapi4j.Position
-
Returns the black long castle rights as a long.
- BQ - Enum constant in enum class chessapi4j.Piece
-
Black queen
- BR - Enum constant in enum class chessapi4j.Piece
-
Black rook
- build() - Method in class chessapi4j.functional.Game.Builder
-
Builds the
Game
instance. - builder() - Method in class chessapi4j.functional.Game
-
Creates a new
Builder
instance. - Builder() - Constructor for class chessapi4j.functional.Game.Builder
-
Creates a new
Builder
instance.
C
- C1 - Enum constant in enum class chessapi4j.Square
-
c1 square
- C2 - Enum constant in enum class chessapi4j.Square
-
c2 square
- C3 - Enum constant in enum class chessapi4j.Square
-
c3 square
- C4 - Enum constant in enum class chessapi4j.Square
-
c4 square
- C5 - Enum constant in enum class chessapi4j.Square
-
c5 square
- C6 - Enum constant in enum class chessapi4j.Square
-
c6 square
- C7 - Enum constant in enum class chessapi4j.Square
-
c7 square
- C8 - Enum constant in enum class chessapi4j.Square
-
c8 square
- changeColorToMove() - Method in class chessapi4j.Position
-
Interchange players turn to move.
- changePieceBit(long, int) - Method in class chessapi4j.Position
-
Sets a particular bitboard according to the pieceOrdinal parameter.
- check() - Method in class chessapi4j.functional.Position
-
Check boolean value, true if this position is in check, false otherwise.
- checkmate() - Method in class chessapi4j.functional.Position
-
Checkmate boolean value, true if checkmate, false otherwise.
- chessapi4j - package chessapi4j
-
This package contains the object orientated classes of chessapi4j.
- chessapi4j.functional - package chessapi4j.functional
-
This package contains classes that are especially well-suited for functional programming and for applications that operate in multithreaded environments.
- childFromMove(Move) - Method in class chessapi4j.Position
-
Returns the position resulting from the given move.
- children() - Method in class chessapi4j.functional.Position
-
Retrieves the children of the current position in a
List
ofTuple<Position, Move>
format. - compareTo(Tag) - Method in class chessapi4j.functional.Tag
- copyBitboards(long[]) - Static method in class chessapi4j.Util
-
Creates a deep copy of the given bitboard array.
- countPieces(Position) - Static method in class chessapi4j.Util
-
Piece counter for the given position.
- currentPosition() - Method in class chessapi4j.functional.Game
-
Returns the current position of this game.
- currentPosition() - Method in class chessapi4j.Game
-
Returns the current position of the game.
D
- D - Enum constant in enum class chessapi4j.MoveDirection
-
Down
- D1 - Enum constant in enum class chessapi4j.Square
-
d1 square
- D2 - Enum constant in enum class chessapi4j.Square
-
d2 square
- D3 - Enum constant in enum class chessapi4j.Square
-
d3 square
- D4 - Enum constant in enum class chessapi4j.Square
-
d4 square
- D5 - Enum constant in enum class chessapi4j.Square
-
d5 square
- D6 - Enum constant in enum class chessapi4j.Square
-
d6 square
- D7 - Enum constant in enum class chessapi4j.Square
-
d7 square
- D8 - Enum constant in enum class chessapi4j.Square
-
d8 square
- date(String) - Method in class chessapi4j.functional.Game.Builder
-
Sets the date tag.
- DL - Enum constant in enum class chessapi4j.MoveDirection
-
Down left
- DR - Enum constant in enum class chessapi4j.MoveDirection
-
Down right
- draw() - Method in class chessapi4j.functional.Position
-
Retrieves if the current position is a forced draw.
E
- E1 - Enum constant in enum class chessapi4j.Square
-
e1 square
- E2 - Enum constant in enum class chessapi4j.Square
-
e2 square
- E3 - Enum constant in enum class chessapi4j.Square
-
e3 square
- E4 - Enum constant in enum class chessapi4j.Square
-
e4 square
- E5 - Enum constant in enum class chessapi4j.Square
-
e5 square
- E6 - Enum constant in enum class chessapi4j.Square
-
e6 square
- E7 - Enum constant in enum class chessapi4j.Square
-
e7 square
- E8 - Enum constant in enum class chessapi4j.Square
-
e8 square
- EcoDescriptor - Class in chessapi4j
-
A simple data class with the ECO code and the opening name.
- EcoDescriptor(String, String) - Constructor for class chessapi4j.EcoDescriptor
-
Creates a new EcoDescriptor
- EMPTY - Enum constant in enum class chessapi4j.Piece
-
Special value for representing empty squares
- enPassantSquare() - Method in class chessapi4j.functional.Position
-
En passant square.
- equals(Object) - Method in class chessapi4j.Bitboard
- equals(Object) - Method in class chessapi4j.EcoDescriptor
- equals(Object) - Method in class chessapi4j.functional.Game
-
Checks if this Game object is equal to another object.
- equals(Object) - Method in class chessapi4j.functional.Move
- equals(Object) - Method in class chessapi4j.functional.PGNMove
- equals(Object) - Method in class chessapi4j.functional.Position
- equals(Object) - Method in class chessapi4j.functional.Tag
- equals(Object) - Method in class chessapi4j.Game
-
Checks if this Game object is equal to another object.
- equals(Object) - Method in class chessapi4j.Move
- equals(Object) - Method in class chessapi4j.PGNMove
- equals(Object) - Method in class chessapi4j.Position
- equals(Object) - Method in class chessapi4j.Tag
- evaluate(Position) - Method in interface chessapi4j.Evaluator
-
Calculates the evaluation score for the given position using various evaluation heuristics.
- Evaluator - Interface in chessapi4j
-
Interface for heuristics position evaluation.
- EvaluatorFactory - Class in chessapi4j
-
Factory for
Evaluator
implementations. - event(String) - Method in class chessapi4j.functional.Game.Builder
-
Sets the event tag.
F
- F1 - Enum constant in enum class chessapi4j.Square
-
f1 square
- F2 - Enum constant in enum class chessapi4j.Square
-
f2 square
- F3 - Enum constant in enum class chessapi4j.Square
-
f3 square
- F4 - Enum constant in enum class chessapi4j.Square
-
f4 square
- F5 - Enum constant in enum class chessapi4j.Square
-
f5 square
- F6 - Enum constant in enum class chessapi4j.Square
-
f6 square
- F7 - Enum constant in enum class chessapi4j.Square
-
f7 square
- F8 - Enum constant in enum class chessapi4j.Square
-
f8 square
- Factory - Class in chessapi4j.functional
-
Main factory class for the functional API.
- fen() - Method in class chessapi4j.functional.Position
-
Fen string representation.
- fiftyMoves() - Method in class chessapi4j.functional.Position
-
Fifty moves boolean value, true if fifty moves, false otherwise.
- fiftyMoves(Position) - Static method in class chessapi4j.AdvanceUtil
-
Returns
1
if the position can be a draw due to the 50-move rule,0
otherwise. - fromMoves(Position, List<Move>) - Static method in class chessapi4j.PositionFactory
-
Custom new instance.
- fromMoves(String) - Static method in class chessapi4j.PositionFactory
-
Deprecated.
G
- G1 - Enum constant in enum class chessapi4j.Square
-
g1 square
- G2 - Enum constant in enum class chessapi4j.Square
-
g2 square
- G3 - Enum constant in enum class chessapi4j.Square
-
g3 square
- G4 - Enum constant in enum class chessapi4j.Square
-
g4 square
- G5 - Enum constant in enum class chessapi4j.Square
-
g5 square
- G6 - Enum constant in enum class chessapi4j.Square
-
g6 square
- G7 - Enum constant in enum class chessapi4j.Square
-
g7 square
- G8 - Enum constant in enum class chessapi4j.Square
-
g8 square
- Game - Class in chessapi4j.functional
-
The Game class represents a chess game.
- Game - Class in chessapi4j
-
The Game class represents a chess game.
- Game(Tag, Tag, Tag, Tag, Tag, Tag, Game.RepetitionsMode) - Constructor for class chessapi4j.functional.Game
-
Constructs an open to modifications instance with the specified initial parameters.
- Game(Tag, Tag, Tag, Tag, Tag, Tag, Tag, Set<Tag>, Deque<PGNMove>) - Constructor for class chessapi4j.functional.Game
-
Constructs a Game immutable instance with the specified parameters.
- Game(Tag, Tag, Tag, Tag, Tag, Tag, Tag, Set<Tag>, List<PGNMove>) - Constructor for class chessapi4j.Game
-
Constructs a Game object with the specified parameters.
- Game.Builder - Class in chessapi4j.functional
-
Builder for open
Game
instances. - Game.RepetitionsMode - Enum Class in chessapi4j.functional
-
This enum represents the possible modes for handling three repetitions.
- gameOver() - Method in class chessapi4j.functional.Position
-
Checks if the game is over.
- generateChildren(Position) - Method in class chessapi4j.Generator
-
Generates the list of legal positions that arise from this particular position.
- generateMoves(Position, List<Position>) - Method in class chessapi4j.Generator
-
Generates a list with the Move objects for the given children in the same order.
- generator() - Static method in class chessapi4j.functional.Factory
-
Generator
class is a singleton class. - Generator - Class in chessapi4j.functional
-
This class is used to generate all the legal moves for a given position.
- Generator - Class in chessapi4j
-
This class is intended to generate all possible moves from an original position.
- GeneratorFactory - Class in chessapi4j
-
Factory class for Generator instances.
- get(int) - Static method in enum class chessapi4j.Piece
-
Retrieves the piece object for the given piece index
- get(int) - Static method in enum class chessapi4j.Square
-
Retrieves the square object for the square number provided.
- get(String) - Static method in enum class chessapi4j.Square
-
Retrieves the square object for the square name provided.
- getBitboard(Piece) - Method in class chessapi4j.functional.Position
-
Retrieves the
Bitboard
object that represent the positions of the givenPiece
. - getBitboard(Piece) - Method in class chessapi4j.Position
-
Retrieves the
Bitboard
object that represent the positions of the givenPiece
. - getBits() - Method in class chessapi4j.Position
-
Returns the bitboards array in ordinal order excluding EMPTY.
- getBlack() - Method in class chessapi4j.functional.Game
-
Returns the black tag.
- getBlack() - Method in class chessapi4j.Game
-
The black tag
- getChild() - Method in class chessapi4j.MoveDetector
-
The child position
- getCol(int) - Static method in class chessapi4j.Util
-
Column number for the given square (zero-based)
- getCol(Square) - Static method in class chessapi4j.Util
-
Column number for the given square object
- getColIndex(String) - Static method in class chessapi4j.Util
-
Column number for the given column character
- getColLetter(int) - Static method in class chessapi4j.Util
-
Column character for the given square
- getComment() - Method in class chessapi4j.functional.PGNMove
-
Returns the comment associated with the move.
- getComment() - Method in class chessapi4j.PGNMove
-
Returns the comment associated with the move.
- getDate() - Method in class chessapi4j.functional.Game
-
Returns the date tag.
- getDate() - Method in class chessapi4j.Game
-
The date tag
- getEco() - Method in class chessapi4j.EcoDescriptor
-
The eco code
- getEcoDescriptor() - Method in class chessapi4j.functional.Game
-
Retrieves the ECO (Encyclopaedia of Chess Openings) descriptor for the game.
- getEcoDescriptor() - Method in class chessapi4j.Game
-
Retrieves the ECO (Encyclopaedia of Chess Openings) descriptor for the game.
- getEnPassant() - Method in class chessapi4j.Position
-
Returns the index square of the piece that can be capture using en passant rule, even when is not possible for any pawn to reach.
- getEvent() - Method in class chessapi4j.functional.Game
-
Returns the event tag.
- getEvent() - Method in class chessapi4j.Game
-
The event tag
- getHalfMovesCounter() - Method in class chessapi4j.Position
-
Returns the half moves number according to fifty moves rules.
- getImpl() - Static method in class chessapi4j.EvaluatorFactory
-
An example implementation.
- getMove() - Method in class chessapi4j.functional.Move
-
Bitboard representing the move.
- getMove() - Method in class chessapi4j.Move
-
The move bitboard as a long
- getMove() - Method in class chessapi4j.MoveDetector
-
Returns the move between the positions.
- getMoves() - Method in class chessapi4j.functional.Game
-
Returns the list of moves.
- getMoves() - Method in class chessapi4j.Game
-
The moves collection
- getMovesCounter() - Method in class chessapi4j.Position
-
Returns the number of complete moves.
- getName() - Method in class chessapi4j.EcoDescriptor
-
The opening name
- getName() - Method in class chessapi4j.functional.Tag
-
The tag name
- getName() - Method in enum class chessapi4j.Square
-
Lower case name of this square.
- getName() - Method in class chessapi4j.Tag
-
The name of this tag
- getOrigin() - Method in class chessapi4j.functional.Move
-
Origin square
- getOrigin() - Method in class chessapi4j.Move
-
The origin square index
- getParent() - Method in class chessapi4j.MoveDetector
-
The parent position
- getPiece(Square) - Method in class chessapi4j.functional.Position
-
Retrieves the
Piece
object that represent the piece present in the givenSquare
object given as argument - getPiece(Square) - Method in class chessapi4j.Position
-
Retrieves the
Piece
object that represent the piece present in the givenSquare
object given as argument - getPosition() - Method in class chessapi4j.functional.PGNMove
-
Returns the position previous to the move.
- getPosition() - Method in class chessapi4j.PGNMove
-
Returns the position previous to the move.
- getPositions() - Method in class chessapi4j.functional.Game
-
The position collection of this game
- getPromotionPiece() - Method in class chessapi4j.functional.Move
-
Promotion piece or -1 if there is no promotion.
- getPromotionPiece() - Method in class chessapi4j.Move
-
The promotion piece index
- getRav() - Method in class chessapi4j.functional.PGNMove
-
Returns the Recursive Annotation Variation (RAV) associated with the move.
- getRav() - Method in class chessapi4j.PGNMove
-
Returns the Recursive Annotation Variation (RAV) associated with the move.
- getResult() - Method in class chessapi4j.functional.Game
-
Returns the result tag wrapped in an Optional.
- getResult() - Method in class chessapi4j.Game
-
The result tag
- getRound() - Method in class chessapi4j.functional.Game
-
Returns the round tag.
- getRound() - Method in class chessapi4j.Game
-
The round tag
- getRow(int) - Static method in class chessapi4j.Util
-
Row number for the given square (zero-based)
- getRow(Square) - Static method in class chessapi4j.Util
-
Row number for the given square object
- getSite() - Method in class chessapi4j.functional.Game
-
Returns the site tag.
- getSite() - Method in class chessapi4j.Game
-
The site tag
- getSquare(String) - Static method in class chessapi4j.Util
-
Retrieves the square object for the given algebraic notation square.
- getSquareIndex(int, int) - Static method in class chessapi4j.Util
-
Square for the given column and row
- getSquareIndex(Square) - Static method in class chessapi4j.Util
-
Square number for the given square in algebraic notation.
- getSquareIndex(String) - Static method in class chessapi4j.Util
-
Square number for the given square in algebraic notation.
- getSquares() - Method in class chessapi4j.functional.Position
-
This method returns a 64 length array.
- getSquares() - Method in class chessapi4j.Position
-
This method returns a 64 length array.
- getSquares(Piece) - Method in class chessapi4j.functional.Position
-
Retrieves a
List
with all the squares where is a piece like the given as argument. - getSquares(Piece) - Method in class chessapi4j.Position
-
Retrieves a
List
with all the squares where is a piece like the given as argument. - getSuffixAnnotations() - Method in class chessapi4j.functional.PGNMove
-
Returns the suffix annotations associated with the move.
- getSuffixAnnotations() - Method in class chessapi4j.PGNMove
-
Returns the suffix annotations associated with the move.
- getSupplementalTags() - Method in class chessapi4j.functional.Game
-
Returns the supplemental tags.
- getSupplementalTags() - Method in class chessapi4j.Game
-
The supplemental tags
- getTags() - Method in class chessapi4j.functional.Game
-
Returns the tags as a map of name to value.
- getTagValue(String) - Method in class chessapi4j.functional.Game
-
Returns the value of the tag with the given name.
- getTagValue(String) - Method in class chessapi4j.Game
-
Returns the value of the tag with the given name.
- getTarget() - Method in class chessapi4j.functional.Move
-
Target square
- getTarget() - Method in class chessapi4j.Move
-
Target square
- getUnsafeMove() - Method in class chessapi4j.MoveDetector
-
Returns the move between the positions.
- getV1() - Method in class chessapi4j.functional.Tuple
-
Returns the first value
- getV2() - Method in class chessapi4j.functional.Tuple
-
Returns the second value
- getValue() - Method in class chessapi4j.Bitboard
-
Value wrapped by this object.
- getValue() - Method in class chessapi4j.functional.Tag
-
The tag value
- getValue() - Method in class chessapi4j.Tag
-
The value of this tag
- getWhite() - Method in class chessapi4j.functional.Game
-
Returns the white tag.
- getWhite() - Method in class chessapi4j.Game
-
The white tag
H
- H1 - Enum constant in enum class chessapi4j.Square
-
h1 square
- H2 - Enum constant in enum class chessapi4j.Square
-
h2 square
- H3 - Enum constant in enum class chessapi4j.Square
-
h3 square
- H4 - Enum constant in enum class chessapi4j.Square
-
h4 square
- H5 - Enum constant in enum class chessapi4j.Square
-
h5 square
- H6 - Enum constant in enum class chessapi4j.Square
-
h6 square
- H7 - Enum constant in enum class chessapi4j.Square
-
h7 square
- H8 - Enum constant in enum class chessapi4j.Square
-
h8 square
- halfMovesCounter() - Method in class chessapi4j.functional.Position
-
Half moves counter.
- hashCode() - Method in class chessapi4j.Bitboard
- hashCode() - Method in class chessapi4j.EcoDescriptor
- hashCode() - Method in class chessapi4j.functional.Game
-
Calculates the hash code for the Game object.
- hashCode() - Method in class chessapi4j.functional.Move
- hashCode() - Method in class chessapi4j.functional.PGNMove
- hashCode() - Method in class chessapi4j.functional.Position
-
For this class hashCode is identical to call
Position.zobristHash()
and then apply the hash standard method to that value. - hashCode() - Method in class chessapi4j.functional.Tag
- hashCode() - Method in class chessapi4j.Game
-
Calculates the hash code for the Game object.
- hashCode() - Method in class chessapi4j.Move
- hashCode() - Method in class chessapi4j.PGNMove
- hashCode() - Method in class chessapi4j.Position
- hashCode() - Method in class chessapi4j.Tag
I
- IGNORE - Enum constant in enum class chessapi4j.functional.Game.RepetitionsMode
-
Ignore repetitions.
- increaseMovesCounter() - Method in class chessapi4j.Position
-
Increments movesCounter when white moves.
- instance() - Static method in class chessapi4j.GeneratorFactory
-
Generator main implementation
- instance(int, int) - Static method in class chessapi4j.MoveFactory
-
New instance.
- instance(int, int, int) - Static method in class chessapi4j.MoveFactory
-
New coronation instance.
- instance(Move) - Static method in class chessapi4j.MoveFactory
-
New instance.
- instance(Square, Square) - Static method in class chessapi4j.MoveFactory
-
New instance.
- instance(Square, Square, Piece) - Static method in class chessapi4j.MoveFactory
-
New coronation instance.
- instance(String, boolean) - Static method in class chessapi4j.MoveFactory
-
Takes a move string (UCI notation) and a boolean indicating the player who moves and return the move representation.
- invalidString(String) - Static method in exception class chessapi4j.MovementException
-
Creates a new instance of
MovementException
with a message that indicates that the move string is invalid. - isCheckmate() - Method in class chessapi4j.Position
-
If this method returns true means this position is checkmate.
- isDraw() - Method in class chessapi4j.Position
-
Retrieves if the current position is a forced draw.
- isFiftyMoves() - Method in class chessapi4j.Position
-
If this method returns true means this position can be draw according to Fifty Moves's rule.
- isGameOver() - Method in class chessapi4j.Position
-
Checks if the game is over.
- isInCheck(Position) - Static method in class chessapi4j.AdvanceUtil
-
Returns
1
if the position is in check,0
otherwise. - isInCheck(Position) - Static method in class chessapi4j.Util
-
True if the position is in check false otherwise.
- isLackOfMaterial() - Method in class chessapi4j.Position
-
If this method returns true means this position is a draw because of lack of material.
- isLegal(Move) - Method in class chessapi4j.functional.Position
-
Checks if the given move is legal for the current position.
- isLongCastleBlack() - Method in class chessapi4j.Position
-
If this method returns true means black is able to castle queen side.
- isLongCastleWhite() - Method in class chessapi4j.Position
-
If this method returns true means white is able to castle queen side.
- isPromotion(int) - Static method in class chessapi4j.Util
-
Promotion checker for the given target square
- isPromotion(Square) - Static method in class chessapi4j.Util
-
Promotion checker for the given target square.
- isRepetitions() - Method in class chessapi4j.Position
-
If this method returns true means this position is a draw because of repetitions.
- isShortCastleBlack() - Method in class chessapi4j.Position
-
If this method returns true means black is able to castle king side.
- isShortCastleWhite() - Method in class chessapi4j.Position
-
If this method returns true means white is able to castle king side.
- isStalemate() - Method in class chessapi4j.Position
-
If this method returns true means this position is a draw because of stalemate.
- isValidFen(String) - Static method in class chessapi4j.Rules
-
Checks if the FEN corresponds to a legal position.
- isWhiteMove() - Method in class chessapi4j.Position
-
If this method returns true means it is white turn to move, otherwise it is black turn.
- iterator() - Method in class chessapi4j.functional.Game
-
An iterator that iterates over the game positions.
- iterator() - Method in class chessapi4j.Game
-
An iterator that iterates over the game positions.
L
- L - Enum constant in enum class chessapi4j.MoveDirection
-
Left
- lackOfMaterial() - Method in class chessapi4j.functional.Position
-
Lack of material boolean value, true if lack of material, false otherwise.
- lackOfMaterial(Position) - Static method in class chessapi4j.AdvanceUtil
-
Returns
1
if the position is in a draw due to insufficient material,0
otherwise. - legal(Position, Move) - Static method in class chessapi4j.Rules
-
Allows determinate if an specific move is legal for a given position.
- legalMoves(Position) - Method in class chessapi4j.functional.Generator
-
Generate all the legal moves for a given position.
- longToList(long) - Static method in class chessapi4j.Util
-
Separates the given bitboard in individuals bitboards, one for each bit.
M
- makeClone() - Method in class chessapi4j.Position
-
Returns a deep clone of this object.
- MissingECOException - Exception Class in chessapi4j
-
This exception is thrown when a game produce no result in the ECO code search.
- MissingECOException(Game) - Constructor for exception class chessapi4j.MissingECOException
-
Constructs a new MissingECOException for the given game.
- MissingECOException(Game) - Constructor for exception class chessapi4j.MissingECOException
-
Constructs a new MissingECOException for the given game.
- move(Move) - Method in class chessapi4j.functional.Game
-
Add the move to the game and returns this game instace.
- move(Move) - Method in class chessapi4j.functional.Position
-
Returns the position that results from the given move.
- move(Square, Square) - Static method in class chessapi4j.functional.Factory
-
Creates a move from the origin and target square
- move(Square, Square, Piece) - Static method in class chessapi4j.functional.Factory
-
Creates a move from the origin and target square
- move(String) - Method in class chessapi4j.functional.Game
-
Adds the move to the game.
- move(String) - Method in class chessapi4j.functional.Position
-
Returns the position that results from the given move in Universal Chess Interface (UCI) format.
- move(String, boolean) - Static method in class chessapi4j.functional.Factory
-
Takes a move string (UCI notation) and a boolean indicating the player who moves and return the move representation.
- Move - Class in chessapi4j.functional
-
Move representation.
- Move - Class in chessapi4j
-
Move representation.
- Move(int, int) - Constructor for class chessapi4j.functional.Move
-
Creates a new move instance
- Move(long, int, int) - Constructor for class chessapi4j.functional.Move
-
Creates a new move instance
- Move(long, int, int) - Constructor for class chessapi4j.Move
-
Creates a new move instance
- Move(Square, Square) - Constructor for class chessapi4j.functional.Move
-
Creates a new move instance
- Move(Square, Square) - Constructor for class chessapi4j.Move
-
Creates a new move instance
- Move(Square, Square, Piece) - Constructor for class chessapi4j.functional.Move
-
Creates a new move instance
- Move(Square, Square, Piece) - Constructor for class chessapi4j.Move
-
Creates a new move instance
- MoveDetector - Class in chessapi4j
-
Class for move detection between two positions.
- MoveDetector(Position, Position) - Constructor for class chessapi4j.MoveDetector
-
Creates a new instance of MoveDetector.
- MoveDirection - Enum Class in chessapi4j
-
Basic enum for move direction and sense.
- MoveFactory - Class in chessapi4j
-
Factory class for
Move
instances. - MovementException - Exception Class in chessapi4j
-
It's thrown when move inconsistencies happens.
- MovementException(Move, Position) - Constructor for exception class chessapi4j.MovementException
-
Creates a new instance of
MovementException
with a message that indicates that the move is illegal for the position. - MovementException(Move, Position) - Constructor for exception class chessapi4j.MovementException
-
Creates a new instance of
MovementException
with a message that indicates that the move is illegal for the position. - MovementException(String) - Constructor for exception class chessapi4j.MovementException
-
Creates a new instance of
MovementException
. - MovementException(String, Position) - Constructor for exception class chessapi4j.MovementException
-
Creates a new instance of
MovementException
with a message that indicates that the move is illegal for the position. - movesCounter() - Method in class chessapi4j.functional.Position
-
Moves counter.
N
- NAGS - Static variable in class chessapi4j.functional.PGNHandler
-
Numeric Annotation Glyphs mapping according to PGN_Reference
- NAGS - Static variable in class chessapi4j.PGNHandler
-
Numeric Annotation Glyphs mapping according to PGN_Reference
- not(Bitboard) - Static method in class chessapi4j.Bitboard
-
Negates the given bitboard.
O
- or(Bitboard...) - Static method in class chessapi4j.Bitboard
-
Apply the "or bit to bit" operation over the values of the bitboards and retrieves a new
Bitboard
object that wraps the result of this operation. - origin() - Method in class chessapi4j.functional.Move
-
Origin square
- origin() - Method in class chessapi4j.Move
-
Origin square
P
- parseGames(InputStream) - Static method in class chessapi4j.functional.PGNHandler
-
Parses an input stream containing chess game data in PGN format and returns a list of Game objects.
- parseGames(InputStream) - Static method in class chessapi4j.PGNHandler
-
Parses an input stream containing chess game data in PGN format and returns a list of Game objects.
- parseGames(String) - Static method in class chessapi4j.PGNHandler
-
Deprecated.
- parseGames(Path) - Static method in class chessapi4j.functional.PGNHandler
-
Parses a file containing chess game data in PGN format and returns a list of Game objects.
- parseGames(Path) - Static method in class chessapi4j.PGNHandler
-
Parses a file containing chess game data in PGN format and returns a list of Game objects.
- PGNHandler - Class in chessapi4j.functional
-
This class is used to handle PGN files.
- PGNHandler - Class in chessapi4j
-
This class provides methods and tools for manipulating and converting chess moves into PGN format.
- pgnMove(String, Position) - Static method in class chessapi4j.functional.Factory
-
Takes a move string (SAN notation) and the position from which the move came and returns a
PGNMove
instance. - PGNMove - Class in chessapi4j.functional
-
Represents a move with Portable Game Notation (PGN) properties.
- PGNMove - Class in chessapi4j
-
Represents a move with Portable Game Notation (PGN) properties.
- PGNMove(int, int, int, Position) - Constructor for class chessapi4j.functional.PGNMove
-
Constructs a PGNMove object with no suffix annotations, RAV, or comment.
- PGNMove(int, int, int, Position, Deque<Integer>, Deque<PGNMove>, String) - Constructor for class chessapi4j.functional.PGNMove
-
Constructs a PGNMove object.
- PGNMove(int, int, int, Position) - Constructor for class chessapi4j.PGNMove
-
Constructs a PGNMove object with the specified origin, target, and promotion piece.
- PGNMove(int, int, Position) - Constructor for class chessapi4j.functional.PGNMove
-
Constructs a PGNMove object with no coronation piece, suffix annotations, RAV, or comment.
- PGNMove(Move, Position) - Constructor for class chessapi4j.PGNMove
-
Constructs a PGNMove object based on a Move object.
- Piece - Enum Class in chessapi4j
-
Enum basic class for pieces.
- popFirstBit() - Method in class chessapi4j.Bitboard
-
Removes and returns the most significant bit set to 1 in the bitboard.
- popLastBit() - Method in class chessapi4j.Bitboard
-
Removes and returns the least significant bit set to 1 in the bitboard.
- position(String) - Static method in class chessapi4j.functional.Factory
-
Takes a FEN string and returns a
Position
instance - Position - Class in chessapi4j.functional
-
Instances of this class represents a chess position.
- Position - Class in chessapi4j
-
Position representation.
- Position() - Constructor for class chessapi4j.Position
-
Creates a new position with the started position.
- Position(String) - Constructor for class chessapi4j.functional.Position
-
Creates a new instance of
Position
with the given FEN. - Position(String) - Constructor for class chessapi4j.Position
-
Constructs a Position from a FEN string.
- positionAt(int, Side, boolean) - Method in class chessapi4j.functional.Game
-
Returns the position at the given move.
- positionAt(int, Side, boolean) - Method in class chessapi4j.Game
-
Returns the position at the given move.
- PositionFactory - Class in chessapi4j
-
Utility factory class for
Position
instances. - promotionPiece() - Method in class chessapi4j.functional.Move
-
Promotion piece or
Piece.EMPTY
if there is no promotion. - promotionPiece() - Method in class chessapi4j.Move
-
Promotion piece or
Piece.EMPTY
if there is no promotion.
Q
- QUEEN_DIRECTIONS - Static variable in class chessapi4j.Util
-
This array indicates the directions in which the queen can move according to the ordinal indices of the
MoveDirection
enum class. - QUEEN_MEGAMATRIX - Static variable in class chessapi4j.Util
-
This matrix contains all the information about queen's movements.
R
- R - Enum constant in enum class chessapi4j.MoveDirection
-
Right
- repetitions() - Method in class chessapi4j.functional.Game
-
Returns the repetitions flag.
- repetitionsMode(Game.RepetitionsMode) - Method in class chessapi4j.functional.Game.Builder
-
Sets the repetitions mode.
- ROOK_DIRECTIONS - Static variable in class chessapi4j.Util
-
This array indicates the directions in which the rook can move according to the ordinal indices of the
MoveDirection
enum class. - round(String) - Method in class chessapi4j.functional.Game.Builder
-
Sets the round tag.
- Rules - Class in chessapi4j
-
Utility class for game rules.
S
- safePosition(String) - Static method in class chessapi4j.functional.Factory
-
Takes a FEN string and returns a
Position
instance if the FEN is valid. - sanMove(String) - Method in class chessapi4j.functional.Game
-
Adds the move to the game.
- sanMove(String) - Method in class chessapi4j.functional.Position
-
Returns the position that results from the given move in Standard Algebraic Notation (SAN) format.
- Search - Interface in chessapi4j
-
Interface for search algorithms.
- SearchFactory - Class in chessapi4j
-
Factory class for
Search
implementations. - searchImpl() - Static method in class chessapi4j.SearchFactory
-
An experimental implementation.
- secureInstance(String) - Method in class chessapi4j.PositionFactory
-
Deprecated.
- seekBestMove(Position, Supplier<Evaluator>, int) - Method in interface chessapi4j.Search
-
Seek for the best move if any.
- seekBestMove(Position, Supplier<Evaluator>, int, int) - Method in interface chessapi4j.Search
-
Seek for the best move if any.
- seekBestMove(Position, Supplier<Evaluator>, int, int, String) - Method in interface chessapi4j.Search
-
Seek for the best move if any.
- setBitboard(Piece, Bitboard) - Method in class chessapi4j.Position
-
Sets the
Bitboard
object that represent the positions of the givenPiece
. - setBitboard(Piece, Square...) - Method in class chessapi4j.Position
-
For each square in the given array, sets the piece type in that square.
- setBits(long[]) - Method in class chessapi4j.Position
-
Sets the array of bitboards, length has to be always 12.
- setBK(long) - Method in class chessapi4j.Position
-
Sets black short castle rights as a long.
- setBlack(Tag) - Method in class chessapi4j.Game
-
Sets the black tag.
- setBlack(String) - Method in class chessapi4j.functional.Game
-
Sets the black tag.
- setBQ(long) - Method in class chessapi4j.Position
-
Sets black long castle rights as a long.
- setCheckmate(boolean) - Method in class chessapi4j.Position
-
Sets checkmate boolean value.
- setChild(Position) - Method in class chessapi4j.MoveDetector
-
Sets the child.
- setComment(String) - Method in class chessapi4j.PGNMove
-
Sets the comment for the move.
- setDate(Tag) - Method in class chessapi4j.Game
-
Sets the date tag.
- setDate(String) - Method in class chessapi4j.functional.Game
-
Sets the date tag.
- setEnPassant(int) - Method in class chessapi4j.Position
-
Sets en passant value.
- setEvent(Tag) - Method in class chessapi4j.Game
-
Sets the event tag.
- setEvent(String) - Method in class chessapi4j.functional.Game
-
Sets the event tag.
- setFiftyMoves(boolean) - Method in class chessapi4j.Position
-
Sets fifty moves boolean value.
- setHalfMovesCounter(int) - Method in class chessapi4j.Position
-
Sets half moves counter value.
- setLackOfMaterial(boolean) - Method in class chessapi4j.Position
-
Sets lack of material boolean value.
- setLongCastleBlack(boolean) - Method in class chessapi4j.Position
-
Sets long castle black boolean value.
- setLongCastleWhite(boolean) - Method in class chessapi4j.Position
-
Sets long castle white boolean value.
- setMoves(List<PGNMove>) - Method in class chessapi4j.Game
-
Set the moves collection
- setMovesCounter(int) - Method in class chessapi4j.Position
-
Sets moves counter value.
- setName(String) - Method in class chessapi4j.Tag
-
Sets the name of this tag
- setOrigin(int) - Method in class chessapi4j.Move
-
Origin square setter.
- setOrigin(Square) - Method in class chessapi4j.Move
-
Origin square setter.
- setParent(Position) - Method in class chessapi4j.MoveDetector
-
Sets the parent.
- setPosition(Position) - Method in class chessapi4j.PGNMove
-
Sets the position for the move.
- setPromotionPiece(int) - Method in class chessapi4j.Move
-
Promotion piece setter.
- setPromotionPiece(Piece) - Method in class chessapi4j.Move
-
Promotion piece setter.
- setRav(List<PGNMove>) - Method in class chessapi4j.PGNMove
-
Sets the Recursive Annotation Variation (RAV) for the move.
- setRepetitions(boolean) - Method in class chessapi4j.Position
-
Sets repetitions boolean value.
- setResult(Tag) - Method in class chessapi4j.Game
-
Sets the result tag.
- setResult(String) - Method in class chessapi4j.functional.Game
-
Sets the result tag.
- setRound(Tag) - Method in class chessapi4j.Game
-
Sets the round tag.
- setRound(String) - Method in class chessapi4j.functional.Game
-
Sets the round tag.
- setShortCastleBlack(boolean) - Method in class chessapi4j.Position
-
Sets short castle black boolean value.
- setShortCastleWhite(boolean) - Method in class chessapi4j.Position
-
Sets short castle white boolean value.
- setSite(Tag) - Method in class chessapi4j.Game
-
Sets the site tag.
- setSite(String) - Method in class chessapi4j.functional.Game
-
Sets the site tag.
- setSquares(int[]) - Method in class chessapi4j.Position
-
Sets the squares array.
- setStalemate(boolean) - Method in class chessapi4j.Position
-
Sets stalemate boolean value.
- setStatus(Position) - Static method in class chessapi4j.Rules
-
Set the internal variables checkmate, stalemate, fiftyMoves and lackOfMaterial of the given position object
- setSuffixAnnotations(List<Integer>) - Method in class chessapi4j.PGNMove
-
Sets the suffix annotations for the move.
- setSupplementalTags(Set<Tag>) - Method in class chessapi4j.functional.Game
-
Sets the supplemental tags.
- setSupplementalTags(Set<Tag>) - Method in class chessapi4j.Game
-
Sets the supplemental tags.
- setTarget(int) - Method in class chessapi4j.Move
-
Target square setter.
- setTarget(Square) - Method in class chessapi4j.Move
-
Target square setter.
- setValue(long) - Method in class chessapi4j.Bitboard
-
Sets the value of the bitboard.
- setValue(String) - Method in class chessapi4j.Tag
-
Sets the value for this tag
- setWhite(Tag) - Method in class chessapi4j.Game
-
Sets the white tag.
- setWhite(String) - Method in class chessapi4j.functional.Game
-
Sets the white tag.
- setWhiteMove(boolean) - Method in class chessapi4j.Position
-
Sets whiteMove boolean value.
- setWK(long) - Method in class chessapi4j.Position
-
Sets the white king side castle rights as a long.
- setWM(long) - Method in class chessapi4j.Position
-
Sets white move rights as a long, meaning 1 for white to move and 0 for black to move.
- setWQ(long) - Method in class chessapi4j.Position
-
Sets white long castle rights as a long.
- shiftLeft(Bitboard, int) - Static method in class chessapi4j.Bitboard
-
Performs a bitwise left shift on the given bitboard.
- shiftRight(Bitboard, int) - Static method in class chessapi4j.Bitboard
-
Performs a bitwise right shift (>>>) on the given bitboard.
- side() - Method in enum class chessapi4j.Piece
-
Returns the side of the piece
- Side - Enum Class in chessapi4j
-
Enum for sides on the board.
- sideToMove() - Method in class chessapi4j.Position
-
Returns the side to move.
- site(String) - Method in class chessapi4j.functional.Game.Builder
-
Sets the site tag.
- Square - Enum Class in chessapi4j
-
Basis enum for squares.
- stalemate() - Method in class chessapi4j.functional.Position
-
Stalemate boolean value, true if stalemate, false otherwise.
- startPos() - Static method in class chessapi4j.functional.Factory
-
Starter position.
- STRICT - Enum constant in enum class chessapi4j.functional.Game.RepetitionsMode
-
Consider repetitions as game over condition.
T
- Tag - Class in chessapi4j.functional
-
This class provides a simple structure to represent a tag with a name and a corresponding value, along with methods for manipulation and comparison.
- Tag - Class in chessapi4j
-
This class provides a simple structure to represent a tag with a name and a corresponding value, along with methods for manipulation and comparison.
- Tag(String, String) - Constructor for class chessapi4j.functional.Tag
-
Creates a new Tag with the given name and value.
- Tag(String, String) - Constructor for class chessapi4j.Tag
-
Creates a new tag
- target() - Method in class chessapi4j.functional.Move
-
Target square
- target() - Method in class chessapi4j.Move
-
Target square
- toFen() - Method in class chessapi4j.Position
-
Method for FEN representation.
- toSAN(Position, Move) - Static method in class chessapi4j.functional.PGNHandler
-
Converts a chess move given in Universal Chess Interface (UCI) format (Pure Coordinate Notation) to Standard Algebraic Notation (SAN) format.
- toSAN(Position, Move) - Static method in class chessapi4j.PGNHandler
-
Converts a chess move given in Universal Chess Interface (UCI) format (Pure Coordinate Notation) to Standard Algebraic Notation (SAN) format.
- toSAN(Position, String) - Static method in class chessapi4j.PGNHandler
-
Converts a chess move given in Universal Chess Interface (UCI) format (Pure Coordinate Notation) to Standard Algebraic Notation (SAN) format.
- toString() - Method in class chessapi4j.Bitboard
- toString() - Method in class chessapi4j.EcoDescriptor
- toString() - Method in class chessapi4j.functional.Game
-
The string representation is always the PGN export format representation.
- toString() - Method in class chessapi4j.functional.Move
- toString() - Method in class chessapi4j.functional.PGNMove
- toString() - Method in class chessapi4j.functional.Position
- toString() - Method in class chessapi4j.functional.Tag
- toString() - Method in class chessapi4j.Game
-
The string representation is always the PGN export format representation.
- toString() - Method in class chessapi4j.Move
- toString() - Method in class chessapi4j.PGNMove
- toString() - Method in class chessapi4j.Position
- toString() - Method in class chessapi4j.Tag
- toUCI(Position, String) - Static method in class chessapi4j.functional.PGNHandler
-
Converts a chess move given in Standard Algebraic Notation (SAN) to Universal Chess Interface (UCI) format (Pure Coordinate Notation).
- toUCI(Position, String) - Static method in class chessapi4j.PGNHandler
-
Converts a chess move given in Standard Algebraic Notation (SAN) to Universal Chess Interface (UCI) format (Pure Coordinate Notation).
- trailingZeros() - Method in class chessapi4j.Bitboard
-
Returns the number of trailing zeros in the bitboard.
- Tuple<T1,
T2> - Class in chessapi4j.functional -
Generic tuple for two values
- Tuple(T1, T2) - Constructor for class chessapi4j.functional.Tuple
-
Constructs a new tuple
U
- U - Enum constant in enum class chessapi4j.MoveDirection
-
Up
- UL - Enum constant in enum class chessapi4j.MoveDirection
-
Up left
- UR - Enum constant in enum class chessapi4j.MoveDirection
-
Up right
- Util - Class in chessapi4j
-
Utility class.
V
- valueOf(String) - Static method in enum class chessapi4j.functional.Game.RepetitionsMode
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in enum class chessapi4j.MoveDirection
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in enum class chessapi4j.Piece
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in enum class chessapi4j.Side
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in enum class chessapi4j.Square
-
Returns the enum constant of this class with the specified name.
- values() - Static method in enum class chessapi4j.functional.Game.RepetitionsMode
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class chessapi4j.MoveDirection
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class chessapi4j.Piece
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class chessapi4j.Side
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class chessapi4j.Square
-
Returns an array containing the constants of this enum class, in the order they are declared.
- visibleSquares(Position, MoveDirection, Square) - Static method in class chessapi4j.Util
-
Deprecated.
- visibleSquares(Position, Square) - Static method in class chessapi4j.Util
-
Deprecated.
W
- WB - Enum constant in enum class chessapi4j.Piece
-
White bishop
- white(String) - Method in class chessapi4j.functional.Game.Builder
-
Sets the white tag.
- WHITE - Enum constant in enum class chessapi4j.Side
-
White side
- whiteCastleKingside() - Method in class chessapi4j.functional.Position
-
Returns true if white can castle kingside, false otherwise.
- whiteCastleQueenside() - Method in class chessapi4j.functional.Position
-
Returns true if white can castle queenside, false otherwise.
- whiteMove() - Method in class chessapi4j.functional.Position
-
Side to move rights.
- wk() - Method in class chessapi4j.functional.Position
-
Returns the white castle kingside right as a long, meaning 1 that white can castle kingside and 0 that white can not castle kingside.
- wk() - Method in class chessapi4j.Position
-
Returns the white short castling rights as a long.
- WK - Enum constant in enum class chessapi4j.Piece
-
White king
- wm() - Method in class chessapi4j.functional.Position
-
Side to move rights.
- wm() - Method in class chessapi4j.Position
-
Returns the white move rights as a long, meaning 1 for white to move and 0 for black to move.
- WN - Enum constant in enum class chessapi4j.Piece
-
White knight
- WP - Enum constant in enum class chessapi4j.Piece
-
White pawn
- wq() - Method in class chessapi4j.functional.Position
-
Returns the white castle queenside right as a long, meaning 1 that white can castle queenside and 0 that white can not castle queenside.
- wq() - Method in class chessapi4j.Position
-
Returns the white long castling rights as a long.
- WQ - Enum constant in enum class chessapi4j.Piece
-
White queen
- WR - Enum constant in enum class chessapi4j.Piece
-
White rook
X
- xor(Bitboard...) - Static method in class chessapi4j.Bitboard
-
Apply the "xor bit to bit" operation over the values of the bitboards and retrieves a new
Bitboard
object that wraps the result of this operation.
Z
- zobristHash() - Method in class chessapi4j.functional.Position
-
Zobrist hash.
- zobristHash() - Method in class chessapi4j.Position
-
Returns the zobrist hash of the position.
All Classes and Interfaces|All Packages|Serialized Form