git.hedgecode.org
/
chesshog.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[LIB-9] Add functional for transcoding vector images
[chesshog.git]
/
chesshog-graphics
/
src
/
main
/
java
/
org
/
hedgecode
/
chess
/
img
/
board
/
SquarePair.java
diff --git
a/chesshog-graphics/src/main/java/org/hedgecode/chess/img/board/SquarePair.java
b/chesshog-graphics/src/main/java/org/hedgecode/chess/img/board/SquarePair.java
index
836d273
..
5fcdd66
100644
(file)
--- a/
chesshog-graphics/src/main/java/org/hedgecode/chess/img/board/SquarePair.java
+++ b/
chesshog-graphics/src/main/java/org/hedgecode/chess/img/board/SquarePair.java
@@
-20,7
+20,7
@@
import java.awt.image.BufferedImage;
import java.util.Objects;
/**
import java.util.Objects;
/**
- *
+ *
Storage class for set of images of chess board squares.
*
* @author Dmitry Samoshin aka gotty
*/
*
* @author Dmitry Samoshin aka gotty
*/
@@
-29,7
+29,7
@@
public class SquarePair<T> {
private final T dark;
private final T light;
private final T dark;
private final T light;
- SquarePair(T dark, T light) {
+
private
SquarePair(T dark, T light) {
this.dark = dark;
this.light = light;
}
this.dark = dark;
this.light = light;
}
@@
-42,6
+42,13
@@
public class SquarePair<T> {
return light;
}
return light;
}
+ public boolean isFilled() {
+ if (this.dark == null || this.light == null) {
+ return false;
+ }
+ return true;
+ }
+
@Override
public boolean equals(Object o) {
if (!(o instanceof SquarePair)) {
@Override
public boolean equals(Object o) {
if (!(o instanceof SquarePair)) {