ProductTransformation { static boolean parseFlip(String input, String letter) { return input.contains("flip" + letter); } ProductTransformation(Rectangle subsetRectangle, boolean flipX, boolean flipY); static ProductTransformation parse(String productTransformationString, Rectangle productRectangle); AffineTransform getTransform();  }
@Test public void testParseFlip() throws Exception { assertTrue(ProductTransformation.parseFlip("foo bar flipx", "x")); assertTrue(ProductTransformation.parseFlip("foo flipy bar", "y")); assertFalse(ProductTransformation.parseFlip("foo bar", "x")); assertFalse(ProductTransformation.parseFlip("foo bar flipy", "x")); }