Child pages
  • JSFile

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Wiki Markup
{hidden}
DO NOT EDIT THE CONTENT OF THIS PAGE DIRECTLY, UNLESS YOU KNOW WHAT YOU'RE DOING.
		THE STRUCTURE OF THE CONTENT IS VITAL IN BEING ABLE TO EXTRACT CHANGES FROM THE PAGE AND MERGE THEM BACK INTO SERVOY SOURCE{hidden}
{sub-section:description|text=}{sub-section}\\{table:class=servoy sSummery}{colgroup}{column:width=80px}{column}{column}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=2}Method Summary{th}{tr}{tbody}{tr}{td}[Boolean]{td}{td}[#canRead]\()
Returns true if the file exists and is readable (has access to it).{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#canWrite]\()
Returns true if the file exists and can be modified.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#createNewFile]\()
Creates the file on disk if needed.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#deleteFile]\()
Deletes the file from the disk if possible.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#exists]\()
Returns true if the file/directory exists on the filesystem.{td}{tr}{tbody}{tbody}{tr}{td}[JSFile]{td}{td}[#getAbsoluteFile]\()
Returns a JSFile instance that corresponds to the absolute form of this pathname.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#getAbsolutePath]\()
Returns a String representation of the absolute form of this pathname.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#getContentType]\()
Returns the contenttype of this file, like for example 'application/pdf'.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#getName]\()
Returns the name of the file.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#getParent]\()
Returns the String representation of the path of the parent of this file.{td}{tr}{tbody}{tbody}{tr}{td}[JSFile]{td}{td}[#getParentFile]\()
Returns a JSFile instance that corresponds to the parent of this file.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#getPath]\()
Returns a String holding the path to the file.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#isAbsolute]\()
Returns true if the path is absolute.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#isDirectory]\()
Returns true if the file is a directory.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#isFile]\()
Returns true if the file is a file and not a regular file.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#isHidden]\()
Returns true if the file is hidden (a file system attribute).{td}{tr}{tbody}{tbody}{tr}{td}[Date]{td}{td}[#lastModified]\()
Returns the time/date of the last modification on the file.{td}{tr}{tbody}{tbody}{tr}{td}[String]\[]{td}{td}[#list]\()
Returns an array of strings naming the files and directories located inside the file, if the file is a directory.{td}{tr}{tbody}{tbody}{tr}{td}[JSFile]\[]{td}{td}[#listFiles]\()
Returns an array of JSFiles naming the files and directories located inside the file, if the file is a directory.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#mkdir]\()
Creates a directory on disk if possible.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#mkdirs]\()
Creates a directory on disk, together with all its parent directories, if possible.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#renameTo]\(destination)
Renames the file to a different name.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#setLastModified]\(date)
Sets the date/time of the last modification on the file.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#setReadOnly]\()
Sets the readonly attribute of the file/directory.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#size]\()
Returns the size in bytes of the file.{td}{tr}{tbody}{table}\\{table:class=servoy sDetail}{colgroup}{column:width=100%}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=1}Method Details{th}{tr}{tbody:id=63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081}{tr:id=name}{td}h6.canRead{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}canRead{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_des|text=|trigger=button}{sub-section}{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_des|trigger=none|class=sIndent}Returns true if the file exists and is readable (has access to it).{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_ret|text=|trigger=button}{sub-section}{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_see|text=|trigger=button}{sub-section}{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_see|text=|trigger=button}{sub-section}{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_sam|text=|trigger=button}{sub-section}{sub-section:63A23B055EF02046-C8CA806F-41F546B9-BE19BBAE-05E3C8CB223A99268EBCF081_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886}{tr:id=name}{td}h6.canWrite{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}canWrite{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_des|text=|trigger=button}{sub-section}{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_des|trigger=none|class=sIndent}Returns true if the file exists and can be modified.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_ret|text=|trigger=button}{sub-section}{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_see|text=|trigger=button}{sub-section}{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_see|text=|trigger=button}{sub-section}{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_sam|text=|trigger=button}{sub-section}{sub-section:532B81B8362F31A9-7061D325-46414180-B9CCA22A-C2A752C0BFEDE3C466CFC886_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF}{tr:id=name}{td}h6.createNewFile{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}createNewFile{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_des|text=|trigger=button}{sub-section}{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_des|trigger=none|class=sIndent}Creates the file on disk if needed. Returns true if the file (name) did not already exists and had to be created.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_ret|text=|trigger=button}{sub-section}{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_see|text=|trigger=button}{sub-section}{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_see|text=|trigger=button}{sub-section}{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_sam|text=|trigger=button}{sub-section}{sub-section:396CFF2364BC8351-F5C0D75B-4445461C-A40CB0A0-85E17EF80E432E67EDD2D8CF_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('story.txt');
if (f.exists())
	f.deleteFile();
else
	f.createNewFile();
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B}{tr:id=name}{td}h6.deleteFile{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}deleteFile{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_des|text=|trigger=button}{sub-section}{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_des|trigger=none|class=sIndent}Deletes the file from the disk if possible. Returns true if the file could be deleted. If the file is a directory, then it must be empty in order to be deleted.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_ret|text=|trigger=button}{sub-section}{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_see|text=|trigger=button}{sub-section}{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_see|text=|trigger=button}{sub-section}{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_sam|text=|trigger=button}{sub-section}{sub-section:FEAF19BCA0F1F47C-67D26136-411B4FE2-9B6C858A-C3C88BF7263AAE1275FCE51B_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('story.txt');
if (f.exists())
	f.deleteFile();
else
	f.createNewFile();
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C}{tr:id=name}{td}h6.exists{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}exists{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_des|text=|trigger=button}{sub-section}{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_des|trigger=none|class=sIndent}Returns true if the file/directory exists on the filesystem.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_ret|text=|trigger=button}{sub-section}{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_see|text=|trigger=button}{sub-section}{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_see|text=|trigger=button}{sub-section}{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_sam|text=|trigger=button}{sub-section}{sub-section:E756576F1025F4A1-0063562D-49F048CD-9C7BA57E-8A3159DFEC580A0E256D335C_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B}{tr:id=name}{td}h6.getAbsoluteFile{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSFile]{span}{span:id=iets|style=float: left; font-weight: bold;}getAbsoluteFile{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_des|text=|trigger=button}{sub-section}{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_des|trigger=none|class=sIndent}Returns a JSFile instance that corresponds to the absolute form of this pathname.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_ret|text=|trigger=button}{sub-section}{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_ret|trigger=none|class=sIndent}[JSFile]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_see|text=|trigger=button}{sub-section}{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_see|text=|trigger=button}{sub-section}{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_sam|text=|trigger=button}{sub-section}{sub-section:E8EBEFE1FECDBA7B-B0FAFC14-4D054BDE-A50AADDA-84847217DFFB327CB3244A8B_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('story.txt');
application.output('parent folder: ' + f.getAbsoluteFile().getParent());
application.output('parent folder has ' + f.getAbsoluteFile().getParentFile().listFiles().length + ' entries');
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763}{tr:id=name}{td}h6.getAbsolutePath{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}getAbsolutePath{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_des|text=|trigger=button}{sub-section}{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_des|trigger=none|class=sIndent}Returns a String representation of the absolute form of this pathname.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_ret|text=|trigger=button}{sub-section}{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_ret|trigger=none|class=sIndent}[String]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_see|text=|trigger=button}{sub-section}{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_see|text=|trigger=button}{sub-section}{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_sam|text=|trigger=button}{sub-section}{sub-section:0FCC30ECA15D5379-6252868B-43204627-A14E99EE-6A78A613D1E92A2391297763_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323}{tr:id=name}{td}h6.getContentType{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}getContentType{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_des|text=|trigger=button}{sub-section}{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_des|trigger=none|class=sIndent}Returns the contenttype of this file, like for example 'application/pdf'.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_ret|text=|trigger=button}{sub-section}{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_ret|trigger=none|class=sIndent}[String]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_see|text=|trigger=button}{sub-section}{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_see|text=|trigger=button}{sub-section}{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_sam|text=|trigger=button}{sub-section}{sub-section:FDFB266BD23EB6FE-51D6315B-4F6D4747-B847A726-B2D2DAACEBDE18A25AE42323_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B}{tr:id=name}{td}h6.getName{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}getName{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_des|text=|trigger=button}{sub-section}{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_des|trigger=none|class=sIndent}Returns the name of the file. The name consists in the last part of the file path.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_ret|text=|trigger=button}{sub-section}{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_ret|trigger=none|class=sIndent}[String]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_see|text=|trigger=button}{sub-section}{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_see|text=|trigger=button}{sub-section}{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_sam|text=|trigger=button}{sub-section}{sub-section:8FB7260FB423199B-C51C6014-4CC2494A-AA078F5C-6871129EB735561B71A8D88B_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1}{tr:id=name}{td}h6.getParent{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}getParent{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_des|text=|trigger=button}{sub-section}{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_des|trigger=none|class=sIndent}Returns the String representation of the path of the parent of this file.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_ret|text=|trigger=button}{sub-section}{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_ret|trigger=none|class=sIndent}[String]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_see|text=|trigger=button}{sub-section}{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_see|text=|trigger=button}{sub-section}{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_sam|text=|trigger=button}{sub-section}{sub-section:12DA1014765071F2-6C296795-467F4DD9-90D28022-A4C5E733D95D7A2F399F27A1_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('story.txt');
application.output('parent folder: ' + f.getAbsoluteFile().getParent());
application.output('parent folder has ' + f.getAbsoluteFile().getParentFile().listFiles().length + ' entries');
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E}{tr:id=name}{td}h6.getParentFile{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSFile]{span}{span:id=iets|style=float: left; font-weight: bold;}getParentFile{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_des|text=|trigger=button}{sub-section}{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_des|trigger=none|class=sIndent}Returns a JSFile instance that corresponds to the parent of this file.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_ret|text=|trigger=button}{sub-section}{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_ret|trigger=none|class=sIndent}[JSFile]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_see|text=|trigger=button}{sub-section}{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_see|text=|trigger=button}{sub-section}{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_sam|text=|trigger=button}{sub-section}{sub-section:4268CA7BFEF9C3AF-22A7E74D-42AB4EAE-B91084D4-9B63CEE149FDB0A780A5981E_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('story.txt');
application.output('parent folder: ' + f.getAbsoluteFile().getParent());
application.output('parent folder has ' + f.getAbsoluteFile().getParentFile().listFiles().length + ' entries');
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E}{tr:id=name}{td}h6.getPath{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}getPath{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_des|text=|trigger=button}{sub-section}{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_des|trigger=none|class=sIndent}Returns a String holding the path to the file.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_ret|text=|trigger=button}{sub-section}{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_ret|trigger=none|class=sIndent}[String]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_see|text=|trigger=button}{sub-section}{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_see|text=|trigger=button}{sub-section}{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_sam|text=|trigger=button}{sub-section}{sub-section:A876C38ABFD2B932-5D3195BF-484C48F9-A640A781-576FB999020DF82C27E3555E_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B}{tr:id=name}{td}h6.isAbsolute{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}isAbsolute{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_des|text=|trigger=button}{sub-section}{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_des|trigger=none|class=sIndent}Returns true if the path is absolute. The path is absolute if it starts with '/' on Unix/Linux/MacOS or has a driver letter on Windows.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_ret|text=|trigger=button}{sub-section}{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_see|text=|trigger=button}{sub-section}{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_see|text=|trigger=button}{sub-section}{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_sam|text=|trigger=button}{sub-section}{sub-section:2EE24EC278C87AEC-7243D8AB-425F490C-A4598B8C-5B99A231B9D396629F54FB6B_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612}{tr:id=name}{td}h6.isDirectory{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}isDirectory{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_des|text=|trigger=button}{sub-section}{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_des|trigger=none|class=sIndent}Returns true if the file is a directory.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_ret|text=|trigger=button}{sub-section}{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_see|text=|trigger=button}{sub-section}{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_see|text=|trigger=button}{sub-section}{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_sam|text=|trigger=button}{sub-section}{sub-section:A11AFF37597611F7-BC31982C-4FC746B4-A0E7877A-24C689A4EBE528A0D633C612_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD}{tr:id=name}{td}h6.isFile{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}isFile{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_des|text=|trigger=button}{sub-section}{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_des|trigger=none|class=sIndent}Returns true if the file is a file and not a regular file.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_ret|text=|trigger=button}{sub-section}{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_see|text=|trigger=button}{sub-section}{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_see|text=|trigger=button}{sub-section}{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_sam|text=|trigger=button}{sub-section}{sub-section:13E5C6172A3B385A-AA6D0D4B-4F2E4895-A9548215-D2223D1DC17AC1149E5A10BD_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA}{tr:id=name}{td}h6.isHidden{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}isHidden{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_des|text=|trigger=button}{sub-section}{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_des|trigger=none|class=sIndent}Returns true if the file is hidden (a file system attribute).{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_ret|text=|trigger=button}{sub-section}{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_see|text=|trigger=button}{sub-section}{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_see|text=|trigger=button}{sub-section}{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_sam|text=|trigger=button}{sub-section}{sub-section:2F66C6EFC4C6E854-8D6508BC-49194B67-A306B86D-F150483D8753E5708EF28FDA_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C}{tr:id=name}{td}h6.lastModified{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Date]{span}{span:id=iets|style=float: left; font-weight: bold;}lastModified{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_des|text=|trigger=button}{sub-section}{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_des|trigger=none|class=sIndent}Returns the time/date of the last modification on the file.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_ret|text=|trigger=button}{sub-section}{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_ret|trigger=none|class=sIndent}[Date]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_see|text=|trigger=button}{sub-section}{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_see|text=|trigger=button}{sub-section}{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_sam|text=|trigger=button}{sub-section}{sub-section:229431D411F9A281-DF9A8199-4BB5442D-BAC5B598-4943A1B76783331DCE9FF51C_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D}{tr:id=name}{td}h6.list{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]\[]{span}{span:id=iets|style=float: left; font-weight: bold;}list{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_des|text=|trigger=button}{sub-section}{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_des|trigger=none|class=sIndent}Returns an array of strings naming the files and directories located inside the file, if the file is a directory.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_ret|text=|trigger=button}{sub-section}{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_ret|trigger=none|class=sIndent}[String]\[]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_see|text=|trigger=button}{sub-section}{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_see|text=|trigger=button}{sub-section}{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_sam|text=|trigger=button}{sub-section}{sub-section:8FCE9EB7968EB987-DF7949DC-4B534D33-9A618B7F-01DBE0EC47CEF107FAA4D56D_sam|class=sIndent|trigger=none}{code:language=javascript}
var d = plugins.file.convertToJSFile('plugins');
var names = d.list();
application.output('Names:');
for (var i=0; i<names.length; i++)
	application.output(names[i]);
var files = d.listFiles();
application.output('Absolute paths:');
for (var i=0; i<files.length; i++)
	application.output(files[i].getAbsolutePath());
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA}{tr:id=name}{td}h6.listFiles{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSFile]\[]{span}{span:id=iets|style=float: left; font-weight: bold;}listFiles{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_des|text=|trigger=button}{sub-section}{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_des|trigger=none|class=sIndent}Returns an array of JSFiles naming the files and directories located inside the file, if the file is a directory.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_ret|text=|trigger=button}{sub-section}{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_ret|trigger=none|class=sIndent}[JSFile]\[]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_see|text=|trigger=button}{sub-section}{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_see|text=|trigger=button}{sub-section}{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_sam|text=|trigger=button}{sub-section}{sub-section:699E4843BA63F0C1-9DD269F3-42D7485D-B715A446-F0C8F272C1EB1A65920E01FA_sam|class=sIndent|trigger=none}{code:language=javascript}
var d = plugins.file.convertToJSFile('plugins');
var names = d.list();
application.output('Names:');
for (var i=0; i<names.length; i++)
	application.output(names[i]);
var files = d.listFiles();
application.output('Absolute paths:');
for (var i=0; i<files.length; i++)
	application.output(files[i].getAbsolutePath());
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78}{tr:id=name}{td}h6.mkdir{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}mkdir{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_des|text=|trigger=button}{sub-section}{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_des|trigger=none|class=sIndent}Creates a directory on disk if possible. Returns true if a new directory was created.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_ret|text=|trigger=button}{sub-section}{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_see|text=|trigger=button}{sub-section}{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_see|text=|trigger=button}{sub-section}{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_sam|text=|trigger=button}{sub-section}{sub-section:03E9105916AE6189-53063E7D-43934757-967D87FB-0DC417DE94DD83290256CC78_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('one/two/three/four');
f.mkdirs(); // Create all four levels of folders in one step.
var g = plugins.file.convertToJSFile('one/two/three/four/five');
g.mkdir(); // This will work because all parent folders are already created.
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D}{tr:id=name}{td}h6.mkdirs{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}mkdirs{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_des|text=|trigger=button}{sub-section}{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_des|trigger=none|class=sIndent}Creates a directory on disk, together with all its parent directories, if possible. Returns true if the hierarchy of directories is created.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_ret|text=|trigger=button}{sub-section}{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_see|text=|trigger=button}{sub-section}{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_see|text=|trigger=button}{sub-section}{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_sam|text=|trigger=button}{sub-section}{sub-section:6E69597BE13369E0-1986FAAD-41EB4CD8-BA2F9608-2326DE0A887A8BA06D3EB56D_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('one/two/three/four');
f.mkdirs(); // Create all four levels of folders in one step.
var g = plugins.file.convertToJSFile('one/two/three/four/five');
g.mkdir(); // This will work because all parent folders are already created.
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803}{tr:id=name}{td}h6.renameTo{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}renameTo{span}{span:id=iets|style=float: left;}\(destination){span}{td}{tr}{tr:id=des}{td}{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_des|text=|trigger=button}{sub-section}{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_des|trigger=none|class=sIndent}Renames the file to a different name. Returns true if the file could be renamed.{sub-section}{td}{tr}{tr:id=prs}{td}*Parameters*\\{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_prs|trigger=none}destination
{sub-section}{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_ret|text=|trigger=button}{sub-section}{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_see|text=|trigger=button}{sub-section}{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_see|text=|trigger=button}{sub-section}{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_sam|text=|trigger=button}{sub-section}{sub-section:5F2644FA4F49E5F1-C853994B-43B2445E-B6B5BDA0-4F7B69D993878942E2542803_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('story.txt');
f.renameTo('otherstory.txt');
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF}{tr:id=name}{td}h6.setLastModified{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}setLastModified{span}{span:id=iets|style=float: left;}\(date){span}{td}{tr}{tr:id=des}{td}{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_des|text=|trigger=button}{sub-section}{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_des|trigger=none|class=sIndent}Sets the date/time of the last modification on the file.{sub-section}{td}{tr}{tr:id=prs}{td}*Parameters*\\{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_prs|trigger=none}date
{sub-section}{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_ret|text=|trigger=button}{sub-section}{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_see|text=|trigger=button}{sub-section}{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_see|text=|trigger=button}{sub-section}{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_sam|text=|trigger=button}{sub-section}{sub-section:82F70A4F4BB2FA45-7DB2DDA8-4C41487E-AEF3A47A-BEC9BAC6DFD520881931BABF_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('story.txt');
f.createNewFile();
// Make the file look old.
f.setLastModified(new Date(1999, 5, 21));
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378}{tr:id=name}{td}h6.setReadOnly{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}setReadOnly{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_des|text=|trigger=button}{sub-section}{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_des|trigger=none|class=sIndent}Sets the readonly attribute of the file/directory. Returns true on success.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_ret|text=|trigger=button}{sub-section}{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_ret|trigger=none|class=sIndent}[Boolean]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_see|text=|trigger=button}{sub-section}{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_see|text=|trigger=button}{sub-section}{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_sam|text=|trigger=button}{sub-section}{sub-section:12C2F2AEF48E0AA0-841954D3-490B4D15-9074BEFF-F3886D11CC6810B8CC8D5378_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('invoice.txt');
plugins.file.writeTXTFile(f, 'important data that should not be changed');
f.setReadOnly();
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A}{tr:id=name}{td}h6.size{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Number]{span}{span:id=iets|style=float: left; font-weight: bold;}size{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_des|text=|trigger=button}{sub-section}{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_des|trigger=none|class=sIndent}Returns the size in bytes of the file. Returns 0 if the file does not exist on disk.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_prs|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_prs|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_ret|text=|trigger=button}{sub-section}{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_ret|trigger=none|class=sIndent}[Number]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_see|text=|trigger=button}{sub-section}{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_see|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_see|text=|trigger=button}{sub-section}{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_link|class=sIndent|trigger=none}{sub-section}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_sam|text=|trigger=button}{sub-section}{sub-section:1D3F2A4CA7CBC225-3EC2EB8B-44D64764-80D8AE26-5160DCB216E7D7939F23B09A_sam|class=sIndent|trigger=none}{code:language=javascript}
var f = plugins.file.convertToJSFile('./big.jpg');
if (f.exists()) {
	application.output('is absolute: ' + f.isAbsolute());
	application.output('is dir: ' + f.isDirectory());
	application.output('is file: ' + f.isFile());
	application.output('is hidden: ' + f.isHidden());
	application.output('can read: ' + f.canRead());
	application.output('can write: ' + f.canWrite());
	application.output('last modified: ' + f.lastModified());
	application.output('name: ' + f.getName());
	application.output('path: ' + f.getPath());
	application.output('absolute path: ' + f.getAbsolutePath());
	application.output('content type: ' + f.getContentType());
	application.output('size: ' + f.size());
}
else {
	application.output('File/folder not found.');
}
{code}{sub-section}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{table}