MCPcopy Create free account
hub / github.com/Acode-Foundation/Acode / createFile

Method createFile

src/plugins/sdcard/src/android/SDcard.java:637–649  ·  view source on GitHub ↗
(
    String parent,
    String name,
    CallbackContext callback
  )

Source from the content-addressed store, hash-verified

635 }
636
637 private void createFile(
638 String parent,
639 String name,
640 CallbackContext callback
641 ) {
642 String mimeType = URLConnection.guessContentTypeFromName(name);
643 String ext = FilenameUtils.getExtension(name);
644
645 if (mimeType == null && ext != null) mimeType = "text/" + ext;
646 else mimeType = "text/plain";
647
648 create(parent, name, mimeType, callback);
649 }
650
651 private void create(
652 String parent,

Callers 1

executeMethod · 0.95

Calls 2

createMethod · 0.95
getExtensionMethod · 0.80

Tested by

no test coverage detected