ShortDiscriminator

A ShortDiscriminator discriminates Shorts. With Java's auto-boxing feature, it doesn't matter whether Short objects or short values are present; this Discriminator will discriminate them. It discriminates its input by discriminating directly on the byte values.

Example

Given the input...

  • {0, -128, 32767, 56, -1, 67, 56, -128, 56, -56}

... a ShortDiscriminator returns the following equivalence classes:

  • {0}
  • {32767}
  • {-1}
  • {67}
  • {-56}
  • {-128, -128}
  • {56, 56, 56}