fix checkstyle new code
Using better Array class

Replaced List to JsArray. Better peformance.
Added boolean array in tests.