BasicColoring class

It's a class that allows you to color a shape

Implementers

Constructors

BasicColoring(BasicShape shape)
Creating a constructor for the class BasicColoring.

Properties

getBoard List<List<int>>
It's a getter that returns the cross.
read-only
getCross BasicShape
It's a getter that returns the cross object.
read-only
hashCode int
The hash code for this object.
read-onlyinherited
move BasicMoves
Creating a new instance of the BasicMoves class, and passing in the validatePosition function as a parameter.
latefinal
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited

Methods

buildOffset(List<int> colors, int offset) List<int>
It takes a list of colors and an offset, and returns a new list of colors with the offset applied
color(int color) bool
Color the current position.
diagonalDownLeft(List<int> colors, [int? n]) bool
Color in diagonal with a direction down left from a current position defined by the movement.
diagonalDownRight(List<int> colors, [int? n]) bool
Color in diagonal with a direction down right from a current position defined by the movement.
diagonalUpLeft(List<int> colors, [int? n]) bool
Color in diagonal with a direction up left from a current position defined by the movement.
diagonalUpRight(List<int> colors, [int? n]) bool
Color in diagonal with a direction up right from a current position defined by the movement.
down(List<int> colors, [int? n]) bool
Color down from a current position defined by the movement.
fillEmpty(int color) bool
If the color of the cell is the default color, then change it to the color passed in.
joinBoards(BasicShape shape) bool
It copies the cross from the parameter to the global variable.
left(List<int> colors, [int? n]) bool
Color left from a current position defined by the movement.
mirrorCellHorizontal() bool
It mirrors a current cell horizontally
mirrorCellVertical() bool
It mirrors a current cell vertically
mirrorHorizontalDownUp() bool
It takes the bottom half of the cross and mirrors it to the top half
mirrorHorizontalUpDown() bool
It takes the top half of the cross and mirrors it to the bottom half
mirrorVerticalLeftRight() bool
It takes the first three columns of the cross and mirrors them to the last three columns
mirrorVerticalRightLeft() bool
It takes the last three columns of the cross and mirrors them to the first three columns
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
Color right from a current position defined by the movement.
toString() String
A string representation of this object.
override
up(List<int> colors, [int? n]) bool
Color up from a current position defined by the movement.

Operators

operator ==(Object other) bool
The equality operator.
inherited