testbox.system.util

Class Util

lucee.Component
    extended by testbox.system.util.Util

Copyright Since 2005 TestBox Framework by Luis Majano and Ortus Solutions, Corp www.ortussolutions.com --- Mail Utility library for TestBox

Class Attributes:
  • synchronized : false
  •  
  • accessors : false
  •  
  • persistent : false
  •  
    Method Summary
    struct arrayToStruct(array input)
         Convert an array to struct argument notation.
    any fileLastModified(any filename)
         Get the last modified date of a file.
    string getAbsolutePath(any path)
         Turn any system path, either relative or absolute, into a fully qualified one.
    array getAnnotatedMethods(string annotation, struct metadata)
         Find all methods on a given metadata and it's parents with a given annotation.
    any getMixerUtil()
         Get the mixer utility object instance.
    boolean inThread()
         Check if you are in cfthread or not for any CFML Engine.
    string ripExtension(any filename)
         Rip an extension of a filename.
    string slugify(string str, [numeric maxLength='0'], [string allow=''])
         Create a URL safe slug from a string.
     
    Methods inherited from class lucee.Component
    None

    Method Detail

    arrayToStruct

    public struct arrayToStruct(array input)

    Convert an array to struct argument notation

    Parameters:
    input - The array to convert

    fileLastModified

    public any fileLastModified(any filename)

    Get the last modified date of a file

    Parameters:
    filename - The target
    Returns:
    date

    getAbsolutePath

    public string getAbsolutePath(any path)

    Turn any system path, either relative or absolute, into a fully qualified one

    Parameters:
    path - The target

    getAnnotatedMethods

    public array getAnnotatedMethods(string annotation, struct metadata)

    Find all methods on a given metadata and it's parents with a given annotation

    Parameters:
    annotation - The annotation name to look for on methods
    metadata - The metadata to search (recursively) for the provided annotation

    getMixerUtil

    public any getMixerUtil()

    Get the mixer utility object instance. It lazy loads into variables scope for faster execution next time.

    Returns:
    MixerUtil

    inThread

    public boolean inThread()

    Check if you are in cfthread or not for any CFML Engine


    ripExtension

    public string ripExtension(any filename)

    Rip an extension of a filename

    Parameters:
    filename - The target

    slugify

    public string slugify(string str, [numeric maxLength='0'], [string allow=''])

    Create a URL safe slug from a string

    Parameters:
    str - The target
    maxLength - The maximum number of characters for the slug
    allow - A regex safe list of additional characters to allow