Once again I am here to present my second extension to community.
Probably you have read in title , the name of extension is FileTools and features are similar to its name.
It provides tools to work with Files (folders also).
Latest Version: 3
Last Updated: 2019-10-20T18:30:00Z
A wide range of blocks…
It has total 29 function/method blocks and 5 event blocks
As it has ‘so many’ blocks so I will show how to use them one by one.
Path to application specific directory i.e., /storage/emulated/0/Android/date/
Thanks to @bodymindpower
Returns a list of available storage directories.
Note: Not working properly sometimes.So use with caution.
Copies file from source to destination folder.It triggers ‘FileCopied’ event will boolean
Note: It can not create folder.It can only copy files between existing folders
Creates Application Specific Directory (/storage/emulated/0/Android/data/
<package name>/files) in case it does not exists
Creates a single directory.It triggers ‘Directory Created’ with boolean
Note:It can not create multiple directories.In this case, this will not work if ‘data’ does not exists
Deletes given directory including all files in it
Deletes a file if it exists.It triggers ‘FileDeleted’ event with boolean
Returns true if file or folder exists else false
Gets file extension(mp3,mp4,txt,etc) of file.
Note: Sometimes it can return
.fileif it is unable to get file extension
Gets file list from the given folder with filter (if applied)
Extenion:- .mp3 , .txt , .png , .jpeg , etc
Returns that file is hidden or not
Checks that given path is complete path or not
For example: /testt.txt and /mnt/sdcard/Android/com.sunny.notez/files/testt.txt are not same.
Returns that folder/file is executable or not
Returns true if given path is/has file
Returns 1 if path is file , 2 if path is folder else -1
Returns true if file/folder is hidden else false
Returns true if file/folder is readable else false
Returns true if file/folder is writable else false
Last modified time of file/folder in given format
Mime type of given file
In above case it will return text/plain
Moves file from source to destination and deletes original file
Converts content uri to actual path
Renames file without deleting it
Returns total space of directory
Returns free space of directory
Gets files and folders list and raises event ‘GotFileList’ with a list of files and folders
Get a list of folder/sub directories of given directory
Here are two download links:
1.Download link 1: File_Tools.aix (20.1 KB)
2.Download link 2: File_Tools.aix - Google Диск
It was not only me who was included in making this extension.
A lot of people helped me to make this extension.
I want to say thank you @deepanshu_da85 and @MeteorCoder for helping me in making FileTools
StackOverFlow also helped me a lot in making FileTools
And a lot of thanks to @KodularCreator for this awesome platform
@bodymindpower for reporting some bugs and changes
ChangeLog Version 2
Added two new blocks
- All methods returning files list will now return empty list(if files list is empty) instead of runtime error
- Mime Type method will return mime type with more accuracy.
- Fixed some null pointer exceptions
ChangeLog Version 3
Added three new blocks
New version includes changes in some blocks
- ‘Application Specific Directory’ now returns path to ASD
- Replaced ‘File’ with ‘FileSystems’ in ‘Available Storage Directory’ block but I am not sure it is working or not
- Some changes in ‘Available Storage Directory’ block