MCPcopy Index your code
hub / github.com/processing/processing / canEdit

Method canEdit

app/src/processing/app/Mode.java:945–951  ·  view source on GitHub ↗

@param f File to be checked against this mode's accepted extensions. @return Whether or not the given file name features an extension supported by this mode.

(final File f)

Source from the content-addressed store, hash-verified

943 * @return Whether or not the given file name features an extension supported by this mode.
944 */
945 public boolean canEdit(final File f) {
946 final int dot = f.getName().lastIndexOf('.');
947 if (dot < 0) {
948 return false;
949 }
950 return validExtension(f.getName().substring(dot + 1));
951 }
952
953 /**
954 * Check this extension (no dots, please) against the list of valid

Callers 3

promptForModeMethod · 0.80
handleOpenMethod · 0.80
handleOpenInternalMethod · 0.80

Calls 2

validExtensionMethod · 0.95
getNameMethod · 0.45

Tested by

no test coverage detected