com.sebtools.FileMgr
Component FileMgr (File Manager)
properties:
methods: deleteFile, directoryList, FileNameFromString, getDelimiter, getDirectory, getFileLen, getFilePath, init, makedir, makeFolder, PathNameFromString, readFile, uploadFile, writeFile
* - private method

deleteFile
public any deleteFile ( required string FileName, string Folder )

I delete the given file.

Output: suppressed
Parameters:
   FileName: string, required, FileName
   Folder: string, optional, Folder

directoryList
query directoryList ( required string directory, string filter="", string sort="", boolean recurse="false", query dirInfo, query thisDir )

Mimics the cfdirectory list.

Output: suppressed
Parameters:
   directory: string, required, directory
   filter: string, optional, filter
   sort: string, optional, sort
   recurse: boolean, optional, recurse
   dirInfo: query, optional, dirInfo
   thisDir: query, optional, thisDir

FileNameFromString
public string FileNameFromString ( required string string, string extensions="cfm,htm,html" )

Output: suppressed
Parameters:
   string: string, required, string
   extensions: string, optional, extensions

getDelimiter
public string getDelimiter ( )

Output: suppressed

getDirectory
public string getDirectory ( required string Folder )

Output: suppressed
Parameters:
   Folder: string, required, Folder

getFileLen
public numeric getFileLen ( required string FileName, string Folder )

Output: suppressed
Parameters:
   FileName: string, required, FileName
   Folder: string, optional, Folder

getFilePath
public string getFilePath ( required string FileName, string Folder )

Output: suppressed
Parameters:
   FileName: string, required, FileName
   Folder: string, optional, Folder

init
public FileMgr init ( required string UploadPath )

I instantiate and return this object.

Output: suppressed
Parameters:
   UploadPath: string, required, UploadPath

makedir
public any makedir ( required string Directory )

I make a directory (if it doesn't exist already).

Output: suppressed
Parameters:
   Directory: string, required, Directory

makeFolder
public any makeFolder ( required string Folder )

Output: suppressed
Parameters:
   Folder: string, required, Folder

PathNameFromString
public string PathNameFromString ( required string string )

Output: suppressed
Parameters:
   string: string, required, string

readFile
public string readFile ( required string FileName, string Folder )

I return the contents of a file.

Output: suppressed
Parameters:
   FileName: string, required, FileName
   Folder: string, optional, Folder

uploadFile
public struct uploadFile ( required string FieldName, string Folder, string NameConflict="Error" )

Output: suppressed
Parameters:
   FieldName: string, required, FieldName
   Folder: string, optional, Folder
   NameConflict: string, optional, NameConflict

writeFile
public void writeFile ( required string FileName, required string Contents, string Folder )

I save a file.

Output: suppressed
Parameters:
   FileName: string, required, FileName
   Contents: string, required, Contents
   Folder: string, optional, Folder