File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -100,6 +100,14 @@ public void normalize() {
100100 }
101101 }
102102
103+ public boolean equals (HWB other ) {
104+ if (other != null ) {
105+ return (vh .equals (other .vh ) && vw .equals (other .vw ) && vb .equals (other .vb ) &&
106+ ((va == null && other .va == null ) || (va != null && va .equals (other .va ))));
107+ }
108+ return false ;
109+ }
110+
103111 /**
104112 * Returns a string representation of the object.
105113 */
Original file line number Diff line number Diff line change @@ -83,6 +83,13 @@ public final boolean setGray(boolean isGray) {
8383 return isGray ;
8484 }
8585
86+ public boolean equals (LAB other ) {
87+ if (other != null ) {
88+ return (vl .equals (other .vl ) && va .equals (other .va ) && vb .equals (other .vb ) &&
89+ ((alpha == null && other .alpha == null ) || (alpha != null && alpha .equals (other .alpha ))));
90+ }
91+ return false ;
92+ }
8693
8794 /**
8895 * Returns a string representation of the object.
Original file line number Diff line number Diff line change @@ -95,6 +95,13 @@ public final void setAlpha(ApplContext ac, CssValue val)
9595 alpha = RGBA .filterAlpha (ac , val );
9696 }
9797
98+ public boolean equals (LCH other ) {
99+ if (other != null ) {
100+ return (vl .equals (other .vl ) && vc .equals (other .vc ) && vh .equals (other .vh ) &&
101+ ((alpha == null && other .alpha == null ) || (alpha != null && alpha .equals (other .alpha ))));
102+ }
103+ return false ;
104+ }
98105
99106 /**
100107 * Returns a string representation of the object.
You can’t perform that action at this time.
0 commit comments