code: private static int getWindingRule(Path.FillType type) {
      switch (type) {
        case WINDING:
        case INVERSE_WINDING:
          return GeneralPath.WIND_NON_ZERO;
        case EVEN_ODD:
        case INVERSE_EVEN_ODD:
          return GeneralPath.WIND_EVEN_ODD;
  
        default:
          assert false;
          return GeneralPath.WIND_NON_ZERO;
      }
    }
docs: Returns the Java2D winding rules matching a given Android {@link FillType}.
  
  @param type the android fill type
  @return the matching java2d winding rule.