| Package | com.lookbackon.ds |
| Class | public class BitBoard |
| Inheritance | BitBoard BitVector Object |
| Implements | IBitBoard |
| Subclasses | AbstractChessVO |
See also
| Property | Defined By | ||
|---|---|---|---|
![]() | bitCount : int [read-only]
The total number of bits. | BitVector | |
![]() | cellCount : int [read-only]
The total number of cells. | BitVector | |
| celled : int [read-only]
| BitBoard | ||
| column : int [read-only] | BitBoard | ||
| isEmpty : Boolean [read-only]
whether or not bitboard is empty;
| BitBoard | ||
| row : int [read-only] | BitBoard | ||
| Method | Defined By | ||
|---|---|---|---|
BitBoard(column:int, row:int) | BitBoard | ||
| BitBoard | |||
clear():void [override]
Resets all bits to 0;
| BitBoard | ||
| BitBoard | |||
dump():String
Dump out a string representing the current object. | BitBoard | ||
![]() | getBit(index:int):int
Gets a bit from a given index. | BitVector | |
getBitt(row:int, column:int):int
Gets a bit from a given row and column. | BitBoard | ||
getCols(colIndex:int):Array | BitBoard | ||
getRows(rowIndex:int):Array | BitBoard | ||
| BitBoard | |||
| BitBoard | |||
![]() | resize(size:int):void
Resizes the bit-vector to an appropriate number of bits. | BitVector | |
| BitBoard | |||
notice:this function is suitable for which board column equals to row. | BitBoard | ||
| BitBoard | |||
setAll():void [override]
Sets each bit to 1. | BitBoard | ||
![]() | setBit(index:int, b:Boolean):void
Sets a bit at a given index. | BitVector | |
setBitt(row:int, column:int, b:Boolean):void
Sets a bit at a given row and column. | BitBoard | ||
toString():String [override]
Prints out a string representing the current object. | BitBoard | ||
| BitBoard | |||
| celled | property |
celled:int [read-only]
public function get celled():int| column | property |
column:int [read-only] public function get column():int| isEmpty | property |
isEmpty:Boolean [read-only] whether or not bitboard is empty;
public function get isEmpty():Boolean| row | property |
row:int [read-only] public function get row():int| BitBoard | () | Constructor |
public function BitBoard(column:int, row:int)Parameters
column:int — the number column of bit board.
| |
row:int — the number row of bit board.
|
| and | () | method |
| clear | () | method |
override public function clear():voidResets all bits to 0;
| clone | () | method |
| dump | () | method |
public function dump():StringDump out a string representing the current object.
ReturnsString — A "human-readable" string representing the current object.
|
| getBitt | () | method |
public function getBitt(row:int, column:int):intGets a bit from a given row and column.
Parameters
row:int — the row number.
| |
column:int — the column number.
|
int — the index bool value.
|
| getCols | () | method |
public function getCols(colIndex:int):ArrayParameters
colIndex:int |
Array |
| getRows | () | method |
public function getRows(rowIndex:int):ArrayParameters
rowIndex:int |
Array |
| not | () | method |
| or | () | method |
| reverse | () | method |
public function reverse():BitBoardReturns
BitBoard — reversed rows with cols such as mirror rotatation 180 degree.
|
| rotate45 | () | method |
public function rotate45():BitBoardnotice:this function is suitable for which board column equals to row.
ReturnsBitBoard — Fliped rows with cols such as clockwise rotatation 45 degree.
|
| rotate90 | () | method |
public function rotate90():BitBoardReturns
BitBoard — Fliped rows with cols such as clockwise rotatation 90 degree.
|
| setAll | () | method |
override public function setAll():voidSets each bit to 1.
| setBitt | () | method |
public function setBitt(row:int, column:int, b:Boolean):voidSets a bit at a given row and column.
Parameters
row:int — the row number.
| |
column:int — the column number.
| |
b:Boolean — the index bool value.
|
| toString | () | method |
override public function toString():StringPrints out a string representing the current object.
ReturnsString — A string representing the current object.
|
| xor | () | method |