(File fileJson)
| 564 | } |
| 565 | |
| 566 | public static String loadJson(File fileJson) throws IOException { |
| 567 | BufferedReader reader = null; |
| 568 | try { |
| 569 | reader = new BufferedReader(new FileReader(fileJson)); |
| 570 | String str; |
| 571 | StringBuilder sb = new StringBuilder(); |
| 572 | while ((str = reader.readLine()) != null) { |
| 573 | sb.append(str).append("\n"); |
| 574 | } |
| 575 | return sb.toString(); |
| 576 | } finally { |
| 577 | if (reader != null) { |
| 578 | reader.close(); |
| 579 | } |
| 580 | } |
| 581 | } |
| 582 | |
| 583 | public static int getARBGInt(int a, int r, int g, int b) { |
| 584 | return ((a & 0xFF) << 24) | ((r & 0xFF) << 16) | ((g & 0xFF) << 8) | ((b & 0xFF)); |
no test coverage detected