Simplify stream operations with anyMatch() again

This is the 2nd attempt to simplify stream operations in
InputMethodServiceDeviceTest with anyMatch() method.

The original attempt [1] was reverted [2] just to cleanly revert prior
CLs [3][4].  The original change [1] itself still makes sense.

 [1]: I4698d956d6378c901b0c5255a664dcd08c1ef1e6
      07c668f8eab6235919864f82fb2e58e3f393fc31
 [2]: I67dcbe2f9032e6a834e0a83c6fa296af0e83416f
      9163cd044e934faaae7983e91be31a48a2f84554
 [3]: Iacc677864b111e56d0308cc85bd2a0353978aeeb
      a6490cbf87d8a2ab182b30af44ca00933cb9ab5b
 [4]: Id1dbc348efaa2ad5d8d7bd1570eff973af89d1fd
      807291f0bc780df7c37169fc4e340937f7f321d2

Bug: 70730589
Test: atest CtsInputMethodServiceHostTestCases
Change-Id: I9b0b000ae0f2c37b6abcb5698d6b623c4e6ad9a9
1 file changed