Grab the contents of a file as a string. Connects lines with \n, even if the input file used \r\n.
(File file)
| 152 | * even if the input file used \r\n. |
| 153 | */ |
| 154 | static public String loadFile(File file) throws IOException { |
| 155 | String[] contents = PApplet.loadStrings(file); |
| 156 | if (contents == null) return null; |
| 157 | return PApplet.join(contents, "\n"); |
| 158 | } |
| 159 | |
| 160 | |
| 161 | /** |
no test coverage detected