mura.content.file

Class fileManager

lucee.Component
    extended by mura.cfobject
      extended by mura.content.file.fileManager

This provides file service level logic functionality

Class Attributes:
  • output : false
  •  
  • synchronized : false
  •  
  • accessors : false
  •  
  • persistent : false
  •  
    Constructor Summary
    init(any fileDAO, any configBean, any settingsManager)
    Method Summary
    any cleanFileCache([any siteID])
    any create(any fileObj, any contentid, any siteid, any filename, string contentType, string contentSubType, numeric fileSize, string moduleID, string fileExt, any fileObjSmall, any fileObjMedium, any fileID='[runtime expression]', any fileObjSource='', string credits='', string caption='', string alttext='', string remoteID='', string remoteURL='', string remotePubDate='', [any remoteSource=''], string remoteSourceURL='', string exif='')
    any createHREFForImage([any siteID], [any fileID=''], [any fileExt=''], any size='undefined', any direct='[runtime expression]', boolean complete='false', [any height=''], [any width=''], [any secure='false'], [any useProtocol='true'])
    any cropAndScale([any fileID], [any size], [any x], [any y], [any height], [any width], [any siteid])
    any deleteAll(string contentID)
    any deleteCustomImageCache([any siteID], [numeric threshold='1'])
         Deletes custom cached images from the image cache based on age.
    any deleteIfNotUsed(any fileID, any contentHistID)
    any deleteVersion(any fileID)
    any emulateUpload(string filePath, string destinationDir='[runtime expression]')
    any flip([any fileID], [any transpose='horizontal'])
    any getCustomImage(any Image, [any Height='AUTO'], [any Width='AUTO'], [any size=''], [any siteID=''])
    query getImageFilesQuery(string siteID, string fields='fileID, fileEXT')
         Retrieves all image file data for a single site.
    any getPostedClientFileName(string fieldName)
    any isPostedFile([any fileField])
    struct Process([any file], [any siteID])
    any purgeDeleted([any siteid=''])
    any read(any fileID)
    any readAll(any fileID)
    any readMedium(any fileID)
    any readMeta(any fileID)
    any readSmall(any fileID)
    any rebuildImageCache([any siteID], [any size=''])
         Rebuilds either the entire image cache or a specific image size for a single site.
    any renderFile([string fileID], string method='inline', string size='')
    any renderMedium([string fileID], string method='inline')
    any renderMimeType(string mimeType='', any file='')
         deprecated in favor of streamFile.
    any renderS3(string fileid, [string method='inline'], [string size=''], [string bucket='[runtime expression]'], [boolean debug='false'])
    any renderSmall([string fileID], string method='inline')
    any requestHasRestrictedFiles([any scope='[runtime expression]'], [any allowedExtensions='[runtime expression]'])
    any restoreVersion([any fileID])
    any rotate([any fileID], [any degrees='90'])
    any streamFile([any filePath], [any filename], [any mimetype], string method='inline', any lastModified='[runtime expression]', boolean deleteFile='false')
    any touchSourceImage([any fileID])
    any upload([any fileField])
     
    Methods inherited from class mura.cfobject
    commitTracePoint, convertTimezone, deleteMethod, get, getAsJSON, getAsStruct, getBean, getConfigBean, getCurrentUser, getEventManager, getFeed, getHTTPAttrs, getHTTPService, getJavaTimezone, getPlugin, getPluginManager, getQueryAttrs, getQueryService, getServiceFactory, getSession, getValue, hasCustomDatasource, initTracePoint, inject, injectMethod, invokeMethod, mixin, parseDateArg, removeValue, set, setValue, valueExists
     
    Methods inherited from class lucee.Component
    None

    Constructor Detail

    init

    public init(any fileDAO, any configBean, any settingsManager)

    Parameters:
    fileDAO
    configBean
    settingsManager

    Method Detail

    cleanFileCache

    public any cleanFileCache([any siteID])

    Parameters:
    siteID

    create

    public any create(any fileObj, any contentid, any siteid, any filename, string contentType, string contentSubType, numeric fileSize, string moduleID, string fileExt, any fileObjSmall, any fileObjMedium, any fileID='[runtime expression]', any fileObjSource='', string credits='', string caption='', string alttext='', string remoteID='', string remoteURL='', string remotePubDate='', [any remoteSource=''], string remoteSourceURL='', string exif='')

    Parameters:
    fileObj
    contentid
    siteid
    filename
    contentType
    contentSubType
    fileSize
    moduleID
    fileExt
    fileObjSmall
    fileObjMedium
    fileID
    fileObjSource
    credits
    caption
    alttext
    remoteID
    remoteURL
    remotePubDate
    remoteSource
    remoteSourceURL
    exif

    createHREFForImage

    public any createHREFForImage([any siteID], [any fileID=''], [any fileExt=''], any size='undefined', any direct='[runtime expression]', boolean complete='false', [any height=''], [any width=''], [any secure='false'], [any useProtocol='true'])

    Parameters:
    siteID
    fileID
    fileExt
    size
    direct
    complete
    height
    width
    secure
    useProtocol

    cropAndScale

    public any cropAndScale([any fileID], [any size], [any x], [any y], [any height], [any width], [any siteid])

    Parameters:
    fileID
    size
    x
    y
    height
    width
    siteid

    deleteAll

    public any deleteAll(string contentID)

    Parameters:
    contentID

    deleteCustomImageCache

    public any deleteCustomImageCache([any siteID], [numeric threshold='1'])

    Deletes custom cached images from the image cache based on age.

    Parameters:
    siteID
    threshold - How old in days the image must be before it is removed.

    deleteIfNotUsed

    public any deleteIfNotUsed(any fileID, any contentHistID)

    Parameters:
    fileID
    contentHistID

    deleteVersion

    public any deleteVersion(any fileID)

    Parameters:
    fileID

    emulateUpload

    public any emulateUpload(string filePath, string destinationDir='[runtime expression]')

    Parameters:
    filePath
    destinationDir

    flip

    public any flip([any fileID], [any transpose='horizontal'])

    Parameters:
    fileID
    transpose

    getCustomImage

    public any getCustomImage(any Image, [any Height='AUTO'], [any Width='AUTO'], [any size=''], [any siteID=''])

    Parameters:
    Image
    Height
    Width
    size
    siteID

    getImageFilesQuery

    public query getImageFilesQuery(string siteID, string fields='fileID, fileEXT')

    Retrieves all image file data for a single site.

    Parameters:
    siteID
    fields

    getPostedClientFileName

    public any getPostedClientFileName(string fieldName)

    Parameters:
    fieldName - Name of the Form field

    isPostedFile

    public any isPostedFile([any fileField])

    Parameters:
    fileField

    Process

    public struct Process([any file], [any siteID])

    Parameters:
    file
    siteID

    purgeDeleted

    public any purgeDeleted([any siteid=''])

    Parameters:
    siteid

    read

    public any read(any fileID)

    Parameters:
    fileID

    readAll

    public any readAll(any fileID)

    Parameters:
    fileID

    readMedium

    public any readMedium(any fileID)

    Parameters:
    fileID

    readMeta

    public any readMeta(any fileID)

    Parameters:
    fileID

    readSmall

    public any readSmall(any fileID)

    Parameters:
    fileID

    rebuildImageCache

    public any rebuildImageCache([any siteID], [any size=''])

    Rebuilds either the entire image cache or a specific image size for a single site.

    Parameters:
    siteID
    size

    renderFile

    public any renderFile([string fileID], string method='inline', string size='')

    Parameters:
    fileID
    method
    size

    renderMedium

    public any renderMedium([string fileID], string method='inline')

    Parameters:
    fileID
    method

    renderMimeType

    public any renderMimeType(string mimeType='', any file='')

    deprecated in favor of streamFile

    Parameters:
    mimeType
    file

    renderS3

    public any renderS3(string fileid, [string method='inline'], [string size=''], [string bucket='[runtime expression]'], [boolean debug='false'])

    Parameters:
    fileid
    method
    size
    bucket
    debug

    renderSmall

    public any renderSmall([string fileID], string method='inline')

    Parameters:
    fileID
    method

    requestHasRestrictedFiles

    public any requestHasRestrictedFiles([any scope='[runtime expression]'], [any allowedExtensions='[runtime expression]'])

    Parameters:
    scope
    allowedExtensions

    restoreVersion

    public any restoreVersion([any fileID])

    Parameters:
    fileID

    rotate

    public any rotate([any fileID], [any degrees='90'])

    Parameters:
    fileID
    degrees

    streamFile

    public any streamFile([any filePath], [any filename], [any mimetype], string method='inline', any lastModified='[runtime expression]', boolean deleteFile='false')

    Parameters:
    filePath
    filename
    mimetype
    method
    lastModified
    deleteFile

    touchSourceImage

    public any touchSourceImage([any fileID])

    Parameters:
    fileID

    upload

    public any upload([any fileField])

    Parameters:
    fileField